	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt9m111_start                  ## -- Begin function mt9m111_start
	.p2align	4, 0x90
_mt9m111_start:                         ## @mt9m111_start
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	8(%rdi), %rax
	movq	16(%rdi), %rcx
	movl	(%rcx,%rax,8), %r15d
	movl	4(%rcx,%rax,8), %eax
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	movq	_start_mt9m111@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	jle	LBB0_8
## %bb.1:
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	movl	$1, %r13d
	movq	_BRIDGE@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rax
	movq	-8(%rax,%r13,8), %rax
	movq	(%rax), %rcx
	cmpq	(%r15), %rcx
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rax), %rsi
	movl	16(%rax), %edx
	movq	%r14, %rdi
	callq	_m5602_write_bridge
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movdqu	16(%rax), %xmm0
	pshufd	$232, %xmm0, %xmm0              ## xmm0 = xmm0[0,2,2,3]
	movq	%xmm0, -48(%rbp)
	movq	8(%rax), %rsi
	movq	%r14, %rdi
	leaq	-48(%rbp), %rdx
	movl	$2, %ecx
	callq	_m5602_write_sensor
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %ebx
	movq	(%r12), %rdi
	callq	_ARRAY_SIZE
	cltq
	cmpq	%rax, %r13
	jge	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	incq	%r13
	testl	%ebx, %ebx
	je	LBB0_2
LBB0_7:
	testl	%ebx, %ebx
	movq	-56(%rbp), %r15                 ## 8-byte Reload
	js	LBB0_29
LBB0_8:
	movq	_M5602_XB_VSYNC_PARA@GOTPCREL(%rip), %r12
	movq	(%r12), %rsi
	movl	-64(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, %r13d
	movzbl	%ah, %edx
	movq	%r14, %rdi
	callq	_m5602_write_bridge
	testl	%eax, %eax
	js	LBB0_28
## %bb.9:
	leal	-1(%r15), %eax
	movl	%eax, -60(%rbp)                 ## 4-byte Spill
	movq	(%r12), %rsi
	movzbl	%r13b, %edx
	movq	%r14, %rdi
	callq	_m5602_write_bridge
	testl	%eax, %eax
	js	LBB0_28
## %bb.10:
	movq	%r15, %r13
	jne	LBB0_14
## %bb.11:
	movq	(%r12), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_m5602_write_bridge
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_13
## %bb.12:
	movq	(%r12), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_m5602_write_bridge
	movl	%eax, %ebx
LBB0_13:
	testl	%ebx, %ebx
	js	LBB0_29
LBB0_14:
	movq	_M5602_XB_SIG_INI@GOTPCREL(%rip), %r15
	movq	(%r15), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_m5602_write_bridge
	testl	%eax, %eax
	js	LBB0_28
## %bb.15:
	movq	(%r15), %rsi
	movq	%r14, %rdi
	movl	$2, %edx
	callq	_m5602_write_bridge
	testl	%eax, %eax
	js	LBB0_28
## %bb.16:
	jne	LBB0_20
## %bb.17:
	movq	_M5602_XB_HSYNC_PARA@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_m5602_write_bridge
	movl	%eax, %ebx
	testl	%eax, %eax
	jne	LBB0_19
## %bb.18:
	movq	_M5602_XB_HSYNC_PARA@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_m5602_write_bridge
	movl	%eax, %ebx
LBB0_19:
	testl	%ebx, %ebx
	js	LBB0_29
LBB0_20:
	movq	%r13, -56(%rbp)                 ## 8-byte Spill
	movq	_M5602_XB_HSYNC_PARA@GOTPCREL(%rip), %r12
	movq	(%r12), %rsi
	movl	-60(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, %r13d
	movzbl	%ah, %edx
	movq	%r14, %rdi
	callq	_m5602_write_bridge
	testl	%eax, %eax
	js	LBB0_28
## %bb.21:
	movq	(%r12), %rsi
	movzbl	%r13b, %edx
	movq	%r14, %rdi
	callq	_m5602_write_bridge
	testl	%eax, %eax
	js	LBB0_28
## %bb.22:
	movq	(%r15), %rsi
	movq	%r14, %rdi
	xorl	%edx, %edx
	callq	_m5602_write_bridge
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_29
## %bb.23:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	cmpl	$321, %eax                      ## imm = 0x141
	je	LBB0_26
## %bb.24:
	cmpl	$641, %eax                      ## imm = 0x281
	jne	LBB0_29
## %bb.25:
	movq	_D_V4L2@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_PDEBUG
	movq	_MT9M111_RMB_OVER_SIZED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movq	_MT9M111_RMB_COLUMN_SKIP_2X@GOTPCREL(%rip), %rcx
	movq	_MT9M111_RMB_ROW_SKIP_2X@GOTPCREL(%rip), %rax
	jmp	LBB0_27
LBB0_26:
	movq	_D_V4L2@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_PDEBUG
	movq	_MT9M111_RMB_OVER_SIZED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, -48(%rbp)
	movq	_MT9M111_RMB_COLUMN_SKIP_4X@GOTPCREL(%rip), %rcx
	movq	_MT9M111_RMB_ROW_SKIP_4X@GOTPCREL(%rip), %rax
LBB0_27:
	movl	(%rcx), %ecx
	orl	(%rax), %ecx
	movq	_VFLIP_IDX@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	-72(%rbp), %rdx                 ## 8-byte Reload
	orl	(%rdx,%rax,4), %ecx
	movq	_HFLIP_IDX@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rdx,%rax,4), %eax
	addl	%eax, %eax
	orl	%ecx, %eax
	movl	%eax, -44(%rbp)
	movq	_MT9M111_SC_R_MODE_CONTEXT_B@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	movl	$2, %ecx
	callq	_m5602_write_sensor
LBB0_28:
	movl	%eax, %ebx
LBB0_29:
	movl	%ebx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_start_mt9m111,8,3              ## @start_mt9m111
	.comm	_BRIDGE,8,3                     ## @BRIDGE
	.comm	_M5602_XB_VSYNC_PARA,8,3        ## @M5602_XB_VSYNC_PARA
	.comm	_M5602_XB_SIG_INI,8,3           ## @M5602_XB_SIG_INI
	.comm	_M5602_XB_HSYNC_PARA,8,3        ## @M5602_XB_HSYNC_PARA
	.comm	_D_V4L2,4,2                     ## @D_V4L2
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Configuring camera for VGA mode"

	.comm	_MT9M111_RMB_OVER_SIZED,4,2     ## @MT9M111_RMB_OVER_SIZED
	.comm	_MT9M111_RMB_ROW_SKIP_2X,4,2    ## @MT9M111_RMB_ROW_SKIP_2X
	.comm	_MT9M111_RMB_COLUMN_SKIP_2X,4,2 ## @MT9M111_RMB_COLUMN_SKIP_2X
	.comm	_VFLIP_IDX,8,3                  ## @VFLIP_IDX
	.comm	_HFLIP_IDX,8,3                  ## @HFLIP_IDX
	.comm	_MT9M111_SC_R_MODE_CONTEXT_B,8,3 ## @MT9M111_SC_R_MODE_CONTEXT_B
L_.str.1:                               ## @.str.1
	.asciz	"Configuring camera for QVGA mode"

	.comm	_MT9M111_RMB_ROW_SKIP_4X,4,2    ## @MT9M111_RMB_ROW_SKIP_4X
	.comm	_MT9M111_RMB_COLUMN_SKIP_4X,4,2 ## @MT9M111_RMB_COLUMN_SKIP_4X
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_mt9m111_start                  ; -- Begin function mt9m111_start
	.p2align	2
_mt9m111_start:                         ; @mt9m111_start
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x0
	ldp	x9, x8, [x0, #8]
	ldr	x21, [x0]
	add	x8, x8, x9, lsl #3
	ldp	w22, w23, [x8]
Lloh0:
	adrp	x24, _start_mt9m111@GOTPAGE
Lloh1:
	ldr	x24, [x24, _start_mt9m111@GOTPAGEOFF]
	ldr	x0, [x24]
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x25, #0
Lloh2:
	adrp	x26, _BRIDGE@GOTPAGE
Lloh3:
	ldr	x26, [x26, _BRIDGE@GOTPAGEOFF]
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	q0, [x8, #16]
	xtn.2s	v0, v0
	str	d0, [sp, #8]
	ldr	x1, [x8, #8]
	add	x2, sp, #8
	mov	x0, x19
	mov	w3, #2
	bl	_m5602_write_sensor
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x20, x0
	add	x25, x25, #1
	ldr	x0, [x24]
	bl	_ARRAY_SIZE
	cmp	x25, w0, sxtw
	ccmp	w20, #0, #0, lt
	b.ne	LBB0_6
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x24]
	ldr	x8, [x8, x25, lsl #3]
	ldr	x9, [x8]
	ldr	x10, [x26]
	cmp	x9, x10
	b.ne	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x1, [x8, #8]
	ldr	w2, [x8, #16]
	mov	x0, x19
	bl	_m5602_write_bridge
	b	LBB0_3
LBB0_6:
	tbnz	w20, #31, LBB0_28
LBB0_7:
Lloh4:
	adrp	x24, _M5602_XB_VSYNC_PARA@GOTPAGE
Lloh5:
	ldr	x24, [x24, _M5602_XB_VSYNC_PARA@GOTPAGEOFF]
	ldr	x1, [x24]
	ubfx	w2, w23, #8, #8
	mov	x0, x19
	bl	_m5602_write_bridge
	tbnz	w0, #31, LBB0_27
; %bb.8:
	ldr	x1, [x24]
	and	w2, w23, #0xff
	mov	x0, x19
	bl	_m5602_write_bridge
	mov	x20, x0
	tbnz	w0, #31, LBB0_28
; %bb.9:
	cbnz	w20, LBB0_13
; %bb.10:
	ldr	x1, [x24]
	mov	x0, x19
	mov	w2, #0
	bl	_m5602_write_bridge
	mov	x20, x0
	cbnz	w0, LBB0_12
; %bb.11:
	ldr	x1, [x24]
	mov	x0, x19
	mov	w2, #0
	bl	_m5602_write_bridge
	mov	x20, x0
LBB0_12:
	tbnz	w20, #31, LBB0_28
LBB0_13:
Lloh6:
	adrp	x23, _M5602_XB_SIG_INI@GOTPAGE
Lloh7:
	ldr	x23, [x23, _M5602_XB_SIG_INI@GOTPAGEOFF]
	ldr	x1, [x23]
	mov	x0, x19
	mov	w2, #0
	bl	_m5602_write_bridge
	tbnz	w0, #31, LBB0_27
; %bb.14:
	ldr	x1, [x23]
	mov	x0, x19
	mov	w2, #2
	bl	_m5602_write_bridge
	mov	x20, x0
	tbnz	w0, #31, LBB0_28
; %bb.15:
Lloh8:
	adrp	x24, _M5602_XB_HSYNC_PARA@GOTPAGE
Lloh9:
	ldr	x24, [x24, _M5602_XB_HSYNC_PARA@GOTPAGEOFF]
	cbnz	w20, LBB0_19
; %bb.16:
	ldr	x1, [x24]
	mov	x0, x19
	mov	w2, #0
	bl	_m5602_write_bridge
	mov	x20, x0
	cbnz	w0, LBB0_18
; %bb.17:
	ldr	x1, [x24]
	mov	x0, x19
	mov	w2, #0
	bl	_m5602_write_bridge
	mov	x20, x0
LBB0_18:
	tbnz	w20, #31, LBB0_28
LBB0_19:
	sub	w25, w22, #1
	ldr	x1, [x24]
	ubfx	w2, w25, #8, #8
	mov	x0, x19
	bl	_m5602_write_bridge
	tbnz	w0, #31, LBB0_27
; %bb.20:
	ldr	x1, [x24]
	and	w2, w25, #0xff
	mov	x0, x19
	bl	_m5602_write_bridge
	tbnz	w0, #31, LBB0_27
; %bb.21:
	ldr	x1, [x23]
	mov	x0, x19
	mov	w2, #0
	bl	_m5602_write_bridge
	mov	x20, x0
	tbnz	w0, #31, LBB0_28
; %bb.22:
	cmp	w22, #321
	b.eq	LBB0_25
; %bb.23:
	cmp	w22, #641
	b.ne	LBB0_28
; %bb.24:
Lloh10:
	adrp	x8, _D_V4L2@GOTPAGE
Lloh11:
	ldr	x8, [x8, _D_V4L2@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	bl	_PDEBUG
Lloh15:
	adrp	x8, _MT9M111_RMB_OVER_SIZED@GOTPAGE
Lloh16:
	ldr	x8, [x8, _MT9M111_RMB_OVER_SIZED@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	str	w8, [sp, #8]
Lloh18:
	adrp	x8, _MT9M111_RMB_COLUMN_SKIP_2X@GOTPAGE
Lloh19:
	ldr	x8, [x8, _MT9M111_RMB_COLUMN_SKIP_2X@GOTPAGEOFF]
Lloh20:
	adrp	x9, _MT9M111_RMB_ROW_SKIP_2X@GOTPAGE
Lloh21:
	ldr	x9, [x9, _MT9M111_RMB_ROW_SKIP_2X@GOTPAGEOFF]
	b	LBB0_26
LBB0_25:
Lloh22:
	adrp	x8, _D_V4L2@GOTPAGE
Lloh23:
	ldr	x8, [x8, _D_V4L2@GOTPAGEOFF]
Lloh24:
	ldr	w0, [x8]
Lloh25:
	adrp	x1, l_.str.1@PAGE
Lloh26:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_PDEBUG
Lloh27:
	adrp	x8, _MT9M111_RMB_OVER_SIZED@GOTPAGE
Lloh28:
	ldr	x8, [x8, _MT9M111_RMB_OVER_SIZED@GOTPAGEOFF]
Lloh29:
	ldr	w8, [x8]
	str	w8, [sp, #8]
Lloh30:
	adrp	x8, _MT9M111_RMB_COLUMN_SKIP_4X@GOTPAGE
Lloh31:
	ldr	x8, [x8, _MT9M111_RMB_COLUMN_SKIP_4X@GOTPAGEOFF]
Lloh32:
	adrp	x9, _MT9M111_RMB_ROW_SKIP_4X@GOTPAGE
Lloh33:
	ldr	x9, [x9, _MT9M111_RMB_ROW_SKIP_4X@GOTPAGEOFF]
LBB0_26:
	ldr	w9, [x9]
	ldr	w8, [x8]
Lloh34:
	adrp	x10, _VFLIP_IDX@GOTPAGE
Lloh35:
	ldr	x10, [x10, _VFLIP_IDX@GOTPAGEOFF]
Lloh36:
	ldr	x10, [x10]
	ldr	w10, [x21, x10, lsl #2]
	orr	w8, w8, w9
Lloh37:
	adrp	x9, _HFLIP_IDX@GOTPAGE
Lloh38:
	ldr	x9, [x9, _HFLIP_IDX@GOTPAGEOFF]
Lloh39:
	ldr	x9, [x9]
	ldr	w9, [x21, x9, lsl #2]
	orr	w8, w8, w10
	orr	w8, w8, w9, lsl #1
	str	w8, [sp, #12]
Lloh40:
	adrp	x8, _MT9M111_SC_R_MODE_CONTEXT_B@GOTPAGE
Lloh41:
	ldr	x8, [x8, _MT9M111_SC_R_MODE_CONTEXT_B@GOTPAGEOFF]
Lloh42:
	ldr	x1, [x8]
	add	x2, sp, #8
	mov	x0, x19
	mov	w3, #2
	bl	_m5602_write_sensor
LBB0_27:
	mov	x20, x0
LBB0_28:
	mov	x0, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh40, Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.cfi_endproc
                                        ; -- End function
	.comm	_start_mt9m111,8,3              ; @start_mt9m111
	.comm	_BRIDGE,8,3                     ; @BRIDGE
	.comm	_M5602_XB_VSYNC_PARA,8,3        ; @M5602_XB_VSYNC_PARA
	.comm	_M5602_XB_SIG_INI,8,3           ; @M5602_XB_SIG_INI
	.comm	_M5602_XB_HSYNC_PARA,8,3        ; @M5602_XB_HSYNC_PARA
	.comm	_D_V4L2,4,2                     ; @D_V4L2
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Configuring camera for VGA mode"

	.comm	_MT9M111_RMB_OVER_SIZED,4,2     ; @MT9M111_RMB_OVER_SIZED
	.comm	_MT9M111_RMB_ROW_SKIP_2X,4,2    ; @MT9M111_RMB_ROW_SKIP_2X
	.comm	_MT9M111_RMB_COLUMN_SKIP_2X,4,2 ; @MT9M111_RMB_COLUMN_SKIP_2X
	.comm	_VFLIP_IDX,8,3                  ; @VFLIP_IDX
	.comm	_HFLIP_IDX,8,3                  ; @HFLIP_IDX
	.comm	_MT9M111_SC_R_MODE_CONTEXT_B,8,3 ; @MT9M111_SC_R_MODE_CONTEXT_B
l_.str.1:                               ; @.str.1
	.asciz	"Configuring camera for QVGA mode"

	.comm	_MT9M111_RMB_ROW_SKIP_4X,4,2    ; @MT9M111_RMB_ROW_SKIP_4X
	.comm	_MT9M111_RMB_COLUMN_SKIP_4X,4,2 ; @MT9M111_RMB_COLUMN_SKIP_4X
.subsections_via_symbols
