	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ov7660_probe                   ## -- Begin function ov7660_probe
	.p2align	4, 0x90
_ov7660_probe:                          ## @ov7660_probe
	.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	$24, %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	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movl	$0, -64(%rbp)
	movl	$0, -60(%rbp)
	movq	_force_sensor@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	testq	%rax, %rax
	je	LBB0_4
## %bb.1:
	movq	_OV7660_SENSOR@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_14
## %bb.2:
	movq	_ov7660@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdi
	xorl	%eax, %eax
	callq	_pr_info
LBB0_3:
	movq	_ov7660_modes@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	%rcx, (%r14)
	movq	(%rax), %rdi
	callq	_ARRAY_SIZE
	movl	%eax, 8(%r14)
	xorl	%r13d, %r13d
	jmp	LBB0_16
LBB0_4:
	movq	_preinit_ov7660@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	callq	_ARRAY_SIZE
	testl	%eax, %eax
	jle	LBB0_12
## %bb.5:
	movl	$1, %ebx
	movq	_BRIDGE@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rax
	movq	-8(%rax,%rbx,8), %rax
	movq	(%rax), %rcx
	cmpq	(%r15), %rcx
	jne	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=1
	movq	8(%rax), %rsi
	movq	16(%rax), %rdx
	movq	%r14, %rdi
	callq	_m5602_write_bridge
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=1
	movl	16(%rax), %ecx
	movl	%ecx, -56(%rbp)
	movq	8(%rax), %rsi
	movq	%r14, %rdi
	leaq	-56(%rbp), %rdx
	movl	$1, %ecx
	callq	_m5602_write_sensor
LBB0_9:                                 ##   in Loop: Header=BB0_6 Depth=1
	movl	%eax, %r13d
	movq	(%r12), %rdi
	callq	_ARRAY_SIZE
	cltq
	cmpq	%rax, %rbx
	jge	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	incq	%rbx
	testl	%r13d, %r13d
	je	LBB0_6
LBB0_11:
	testl	%r13d, %r13d
	js	LBB0_16
LBB0_12:
	movq	_OV7660_PID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-64(%rbp), %rdx
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_m5602_read_sensor
	testq	%rax, %rax
	jne	LBB0_14
## %bb.13:
	movq	_OV7660_VER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-60(%rbp), %rdx
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_m5602_read_sensor
	testq	%rax, %rax
	je	LBB0_18
LBB0_14:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%r13d, %r13d
LBB0_15:
	subl	(%rax), %r13d
LBB0_16:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_22
## %bb.17:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movl	-64(%rbp), %esi
	movl	-60(%rbp), %edx
	leaq	L_.str.1(%rip), %rdi
	xorl	%r13d, %r13d
	xorl	%eax, %eax
	callq	_pr_info
	cmpl	$118, -64(%rbp)
	jne	LBB0_21
## %bb.19:
	cmpl	$96, -60(%rbp)
	jne	LBB0_21
## %bb.20:
	leaq	L_.str.2(%rip), %rdi
	xorl	%eax, %eax
	callq	_pr_info
	jmp	LBB0_3
LBB0_21:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	jmp	LBB0_15
LBB0_22:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_force_sensor,8,3               ## @force_sensor
	.comm	_OV7660_SENSOR,8,3              ## @OV7660_SENSOR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Forcing an %s sensor\n"

	.comm	_ov7660,4,2                     ## @ov7660
	.comm	_ENODEV,4,2                     ## @ENODEV
	.comm	_preinit_ov7660,8,3             ## @preinit_ov7660
	.comm	_BRIDGE,8,3                     ## @BRIDGE
	.comm	_OV7660_PID,4,2                 ## @OV7660_PID
	.comm	_OV7660_VER,4,2                 ## @OV7660_VER
L_.str.1:                               ## @.str.1
	.asciz	"Sensor reported 0x%x%x\n"

L_.str.2:                               ## @.str.2
	.asciz	"Detected a ov7660 sensor\n"

	.comm	_ov7660_modes,8,3               ## @ov7660_modes
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_ov7660_probe                   ; -- Begin function ov7660_probe
	.p2align	2
_ov7660_probe:                          ; @ov7660_probe
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #40]
	str	xzr, [sp, #24]
Lloh3:
	adrp	x8, _force_sensor@GOTPAGE
Lloh4:
	ldr	x8, [x8, _force_sensor@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	cbz	x8, LBB0_4
; %bb.1:
Lloh6:
	adrp	x9, _OV7660_SENSOR@GOTPAGE
Lloh7:
	ldr	x9, [x9, _OV7660_SENSOR@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_13
; %bb.2:
Lloh9:
	adrp	x8, _ov7660@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ov7660@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	str	x8, [sp]
Lloh12:
	adrp	x0, l_.str@PAGE
Lloh13:
	add	x0, x0, l_.str@PAGEOFF
LBB0_3:
	bl	_pr_info
Lloh14:
	adrp	x8, _ov7660_modes@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ov7660_modes@GOTPAGEOFF]
	ldr	x9, [x8]
	str	x9, [x19]
	ldr	x0, [x8]
	bl	_ARRAY_SIZE
	mov	w20, #0
	str	w0, [x19, #8]
	b	LBB0_14
LBB0_4:
Lloh16:
	adrp	x21, _preinit_ov7660@GOTPAGE
Lloh17:
	ldr	x21, [x21, _preinit_ov7660@GOTPAGEOFF]
	ldr	x0, [x21]
	bl	_ARRAY_SIZE
	cmp	w0, #1
	b.lt	LBB0_11
; %bb.5:
	mov	x22, #0
Lloh18:
	adrp	x23, _BRIDGE@GOTPAGE
Lloh19:
	ldr	x23, [x23, _BRIDGE@GOTPAGEOFF]
	b	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=1
	ldp	x1, x9, [x8, #8]
	str	w9, [sp, #32]
	add	x2, sp, #32
	mov	x0, x19
	mov	w3, #1
	bl	_m5602_write_sensor
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=1
	mov	x20, x0
	add	x22, x22, #1
	ldr	x0, [x21]
	bl	_ARRAY_SIZE
	cmp	x22, w0, sxtw
	ccmp	w20, #0, #0, lt
	b.ne	LBB0_10
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	ldr	x8, [x8, x22, lsl #3]
	ldr	x9, [x8]
	ldr	x10, [x23]
	cmp	x9, x10
	b.ne	LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
	ldp	x1, x2, [x8, #8]
	mov	x0, x19
	bl	_m5602_write_bridge
	b	LBB0_7
LBB0_10:
	tbnz	w20, #31, LBB0_14
LBB0_11:
Lloh20:
	adrp	x8, _OV7660_PID@GOTPAGE
Lloh21:
	ldr	x8, [x8, _OV7660_PID@GOTPAGEOFF]
Lloh22:
	ldr	w1, [x8]
	add	x2, sp, #28
	mov	x0, x19
	mov	w3, #1
	bl	_m5602_read_sensor
	cbnz	x0, LBB0_13
; %bb.12:
Lloh23:
	adrp	x8, _OV7660_VER@GOTPAGE
Lloh24:
	ldr	x8, [x8, _OV7660_VER@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	add	x2, sp, #24
	mov	x0, x19
	mov	w3, #1
	bl	_m5602_read_sensor
	cbz	x0, LBB0_16
LBB0_13:
Lloh26:
	adrp	x8, _ENODEV@GOTPAGE
Lloh27:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_14:
	ldr	x8, [sp, #40]
Lloh29:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh30:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh31:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_19
; %bb.15:
	mov	x0, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_16:
	ldp	w9, w8, [sp, #24]
	stp	x8, x9, [sp]
Lloh32:
	adrp	x0, l_.str.1@PAGE
Lloh33:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_pr_info
	ldr	w8, [sp, #28]
	cmp	w8, #118
	b.ne	LBB0_13
; %bb.17:
	ldr	w8, [sp, #24]
	cmp	w8, #96
	b.ne	LBB0_13
; %bb.18:
Lloh34:
	adrp	x0, l_.str.2@PAGE
Lloh35:
	add	x0, x0, l_.str.2@PAGEOFF
	b	LBB0_3
LBB0_19:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpAdd	Lloh32, Lloh33
	.loh AdrpAdd	Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.comm	_force_sensor,8,3               ; @force_sensor
	.comm	_OV7660_SENSOR,8,3              ; @OV7660_SENSOR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Forcing an %s sensor\n"

	.comm	_ov7660,4,2                     ; @ov7660
	.comm	_ENODEV,4,2                     ; @ENODEV
	.comm	_preinit_ov7660,8,3             ; @preinit_ov7660
	.comm	_BRIDGE,8,3                     ; @BRIDGE
	.comm	_OV7660_PID,4,2                 ; @OV7660_PID
	.comm	_OV7660_VER,4,2                 ; @OV7660_VER
l_.str.1:                               ; @.str.1
	.asciz	"Sensor reported 0x%x%x\n"

l_.str.2:                               ; @.str.2
	.asciz	"Detected a ov7660 sensor\n"

	.comm	_ov7660_modes,8,3               ; @ov7660_modes
.subsections_via_symbols
