	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function em28xx_probe_sensor_omnivision
_em28xx_probe_sensor_omnivision:        ## @em28xx_probe_sensor_omnivision
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	(%rdi), %r15
	shlq	$2, %r15
	addq	24(%rdi), %r15
	movq	_EM28XX_NOSENSOR@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	%rax, 8(%rdi)
	movq	_omnivision_sensor_addrs@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movq	_I2C_CLIENT_END@GOTPCREL(%rip), %r14
	cmpq	(%r14), %rax
	jne	LBB0_1
LBB0_6:
	movq	_ENODEV@GOTPCREL(%rip), %rax
	xorl	%r14d, %r14d
	subl	(%rax), %r14d
LBB0_34:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movl	$8, %r12d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %ebx
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	16(%rax), %rdi
	movl	(%r15), %edx
	addl	%edx, %edx
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %ecx
	callq	_dev_err
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_omnivision_sensor_addrs@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax,%r12), %rax
	addq	$8, %r12
	cmpq	(%r14), %rax
	je	LBB0_6
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	%eax, (%r15)
	movq	%r15, %rdi
	movl	$28, %esi
	callq	_i2c_smbus_read_byte_data
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_3
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movl	$29, %esi
	callq	_i2c_smbus_read_byte_data
	testl	%eax, %eax
	js	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_2 Depth=1
	shll	$8, %ebx
	addl	%ebx, %eax
	cmpl	$32674, %eax                    ## imm = 0x7FA2
	jne	LBB0_5
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movl	$10, %esi
	callq	_i2c_smbus_read_byte_data
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_11
## %bb.12:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	%r15, %rdi
	movl	$11, %esi
	callq	_i2c_smbus_read_byte_data
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_4
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_ENXIO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	addl	%ebx, %eax
	jne	LBB0_4
	jmp	LBB0_5
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	movl	%r13d, %ebx
	jmp	LBB0_4
LBB0_13:
	shll	$8, %r13d
	addl	%r13d, %ebx
	cmpl	$30495, %ebx                    ## imm = 0x771F
	jg	LBB0_21
## %bb.14:
	cmpl	$30303, %ebx                    ## imm = 0x765F
	jg	LBB0_18
## %bb.15:
	cmpl	$9794, %ebx                     ## imm = 0x2642
	je	LBB0_35
## %bb.16:
	cmpl	$30280, %ebx                    ## imm = 0x7648
	jne	LBB0_33
## %bb.17:
	leaq	L_.str.2(%rip), %rdx
	jmp	LBB0_36
LBB0_21:
	leal	-38472(%rbx), %eax
	cmpl	$15, %eax
	ja	LBB0_22
## %bb.25:
	movl	$3, %ecx
	btl	%eax, %ecx
	jb	LBB0_31
## %bb.26:
	movl	$1280, %ecx                     ## imm = 0x500
	btl	%eax, %ecx
	jb	LBB0_32
## %bb.27:
	movl	$49152, %ecx                    ## imm = 0xC000
	btl	%eax, %ecx
	jae	LBB0_22
## %bb.28:
	leaq	L_.str.9(%rip), %rdx
	jmp	LBB0_36
LBB0_18:
	cmpl	$30304, %ebx                    ## imm = 0x7660
	je	LBB0_29
## %bb.19:
	cmpl	$30323, %ebx                    ## imm = 0x7673
	jne	LBB0_33
## %bb.20:
	leaq	L_.str.4(%rip), %rdx
	jmp	LBB0_36
LBB0_22:
	cmpl	$30496, %ebx                    ## imm = 0x7720
	je	LBB0_30
## %bb.23:
	cmpl	$30497, %ebx                    ## imm = 0x7721
	jne	LBB0_33
## %bb.24:
	leaq	L_.str.6(%rip), %rdx
	jmp	LBB0_36
LBB0_35:
	movq	_EM28XX_OV2640@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, 8(%rcx)
	leaq	L_.str.1(%rip), %rdx
	jmp	LBB0_36
LBB0_31:
	leaq	L_.str.7(%rip), %rdx
	jmp	LBB0_36
LBB0_32:
	leaq	L_.str.8(%rip), %rdx
	jmp	LBB0_36
LBB0_29:
	leaq	L_.str.3(%rip), %rdx
	jmp	LBB0_36
LBB0_33:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	16(%rax), %rdi
	leaq	L_.str.10(%rip), %rsi
	xorl	%r14d, %r14d
	movl	%ebx, %edx
	xorl	%eax, %eax
	callq	_dev_info
	jmp	LBB0_34
LBB0_30:
	leaq	L_.str.5(%rip), %rdx
LBB0_36:
	movq	_EM28XX_NOSENSOR@GOTPCREL(%rip), %rsi
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	movq	8(%rcx), %rax
	movq	16(%rcx), %rdi
	cmpq	(%rsi), %rax
	jne	LBB0_39
## %bb.37:
	leaq	L_.str.11(%rip), %rsi
	jmp	LBB0_38
LBB0_39:
	leaq	L_.str.12(%rip), %rsi
LBB0_38:
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	callq	_dev_info
	jmp	LBB0_34
	.cfi_endproc
                                        ## -- End function
	.comm	_EM28XX_NOSENSOR,8,3            ## @EM28XX_NOSENSOR
	.comm	_omnivision_sensor_addrs,8,3    ## @omnivision_sensor_addrs
	.comm	_I2C_CLIENT_END,8,3             ## @I2C_CLIENT_END
	.comm	_ENXIO,4,2                      ## @ENXIO
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"couldn't read from i2c device 0x%02x: error %i\n"

L_.str.1:                               ## @.str.1
	.asciz	"OV2640"

	.comm	_EM28XX_OV2640,8,3              ## @EM28XX_OV2640
L_.str.2:                               ## @.str.2
	.asciz	"OV7648"

L_.str.3:                               ## @.str.3
	.asciz	"OV7660"

L_.str.4:                               ## @.str.4
	.asciz	"OV7670"

L_.str.5:                               ## @.str.5
	.asciz	"OV7720"

L_.str.6:                               ## @.str.6
	.asciz	"OV7725"

L_.str.7:                               ## @.str.7
	.asciz	"OV9640"

L_.str.8:                               ## @.str.8
	.asciz	"OV9650"

L_.str.9:                               ## @.str.9
	.asciz	"OV9655"

L_.str.10:                              ## @.str.10
	.asciz	"unknown OmniVision sensor detected: 0x%04x\n"

L_.str.11:                              ## @.str.11
	.asciz	"unsupported sensor detected: %s\n"

L_.str.12:                              ## @.str.12
	.asciz	"sensor %s detected\n"

	.comm	_ENODEV,4,2                     ## @ENODEV
	.no_dead_strip	_em28xx_probe_sensor_omnivision
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function em28xx_probe_sensor_omnivision
_em28xx_probe_sensor_omnivision:        ; @em28xx_probe_sensor_omnivision
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	ldr	x9, [x0, #24]
	ldr	x10, [x0]
Lloh0:
	adrp	x8, _EM28XX_NOSENSOR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EM28XX_NOSENSOR@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [x0, #8]
Lloh3:
	adrp	x25, _omnivision_sensor_addrs@GOTPAGE
Lloh4:
	ldr	x25, [x25, _omnivision_sensor_addrs@GOTPAGEOFF]
	ldr	x8, [x25]
	ldr	x8, [x8]
Lloh5:
	adrp	x26, _I2C_CLIENT_END@GOTPAGE
Lloh6:
	ldr	x26, [x26, _I2C_CLIENT_END@GOTPAGEOFF]
	ldr	x11, [x26]
	cmp	x8, x11
	b.ne	LBB0_3
LBB0_1:
Lloh7:
	adrp	x8, _ENODEV@GOTPAGE
Lloh8:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh9:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_2:
	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
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_3:
	mov	x19, x0
	add	x20, x9, x10, lsl #2
	mov	w27, #8
Lloh10:
	adrp	x28, _ENXIO@GOTPAGE
Lloh11:
	ldr	x28, [x28, _ENXIO@GOTPAGEOFF]
	mov	w24, #32674
Lloh12:
	adrp	x21, l_.str@PAGE
Lloh13:
	add	x21, x21, l_.str@PAGEOFF
	b	LBB0_7
LBB0_4:                                 ;   in Loop: Header=BB0_7 Depth=1
	mov	x22, x0
LBB0_5:                                 ;   in Loop: Header=BB0_7 Depth=1
	ldr	x0, [x19, #16]
	ldr	w8, [x20]
	lsl	w2, w8, #1
	mov	x1, x21
	mov	x3, x22
	bl	_dev_err
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [x25]
	ldr	x8, [x8, x27]
	ldr	x9, [x26]
	add	x27, x27, #8
	cmp	x8, x9
	b.eq	LBB0_1
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	str	w8, [x20]
	mov	x0, x20
	mov	w1, #28
	bl	_i2c_smbus_read_byte_data
	mov	x22, x0
	tbnz	w0, #31, LBB0_12
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x20
	mov	w1, #29
	bl	_i2c_smbus_read_byte_data
	tbnz	w0, #31, LBB0_4
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	add	w8, w0, w22, lsl #8
	cmp	w8, w24
	b.ne	LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x20
	mov	w1, #10
	bl	_i2c_smbus_read_byte_data
	mov	x23, x0
	tbnz	w0, #31, LBB0_13
; %bb.11:                               ;   in Loop: Header=BB0_7 Depth=1
	mov	x0, x20
	mov	w1, #11
	bl	_i2c_smbus_read_byte_data
	mov	x22, x0
	tbnz	w0, #31, LBB0_5
	b	LBB0_14
LBB0_12:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w8, [x28]
	cmn	w22, w8
	b.ne	LBB0_5
	b	LBB0_6
LBB0_13:                                ;   in Loop: Header=BB0_7 Depth=1
	mov	x22, x23
	b	LBB0_5
LBB0_14:
	add	w8, w22, w23, lsl #8
	mov	w9, #30495
	cmp	w8, w9
	b.gt	LBB0_19
; %bb.15:
	mov	w9, #30303
	cmp	w8, w9
	b.gt	LBB0_24
; %bb.16:
	mov	w9, #9794
	cmp	w8, w9
	b.eq	LBB0_30
; %bb.17:
	mov	w9, #30280
	cmp	w8, w9
	b.ne	LBB0_34
; %bb.18:
Lloh14:
	adrp	x8, l_.str.2@PAGE
Lloh15:
	add	x8, x8, l_.str.2@PAGEOFF
	b	LBB0_36
LBB0_19:
	mov	w9, #-38472
	add	w9, w8, w9
	cmp	w9, #15
	b.hi	LBB0_27
; %bb.20:
	mov	w10, #1
	lsl	w10, w10, w9
	tst	w10, #0x3
	b.ne	LBB0_31
; %bb.21:
	mov	w11, #1280
	tst	w10, w11
	b.ne	LBB0_32
; %bb.22:
	mov	w10, #1
	lsl	w9, w10, w9
	tst	w9, #0xc000
	b.eq	LBB0_27
; %bb.23:
Lloh16:
	adrp	x8, l_.str.9@PAGE
Lloh17:
	add	x8, x8, l_.str.9@PAGEOFF
	b	LBB0_36
LBB0_24:
	mov	w9, #30304
	cmp	w8, w9
	b.eq	LBB0_33
; %bb.25:
	mov	w9, #30323
	cmp	w8, w9
	b.ne	LBB0_34
; %bb.26:
Lloh18:
	adrp	x8, l_.str.4@PAGE
Lloh19:
	add	x8, x8, l_.str.4@PAGEOFF
	b	LBB0_36
LBB0_27:
	mov	w9, #30496
	cmp	w8, w9
	b.eq	LBB0_35
; %bb.28:
	mov	w9, #30497
	cmp	w8, w9
	b.ne	LBB0_34
; %bb.29:
Lloh20:
	adrp	x8, l_.str.6@PAGE
Lloh21:
	add	x8, x8, l_.str.6@PAGEOFF
	b	LBB0_36
LBB0_30:
Lloh22:
	adrp	x8, _EM28XX_OV2640@GOTPAGE
Lloh23:
	ldr	x8, [x8, _EM28XX_OV2640@GOTPAGEOFF]
Lloh24:
	ldr	x8, [x8]
	str	x8, [x19, #8]
Lloh25:
	adrp	x8, l_.str.1@PAGE
Lloh26:
	add	x8, x8, l_.str.1@PAGEOFF
	b	LBB0_36
LBB0_31:
Lloh27:
	adrp	x8, l_.str.7@PAGE
Lloh28:
	add	x8, x8, l_.str.7@PAGEOFF
	b	LBB0_36
LBB0_32:
Lloh29:
	adrp	x8, l_.str.8@PAGE
Lloh30:
	add	x8, x8, l_.str.8@PAGEOFF
	b	LBB0_36
LBB0_33:
Lloh31:
	adrp	x8, l_.str.3@PAGE
Lloh32:
	add	x8, x8, l_.str.3@PAGEOFF
	b	LBB0_36
LBB0_34:
	ldr	x0, [x19, #16]
	str	x8, [sp]
Lloh33:
	adrp	x1, l_.str.10@PAGE
Lloh34:
	add	x1, x1, l_.str.10@PAGEOFF
	b	LBB0_39
LBB0_35:
Lloh35:
	adrp	x8, l_.str.5@PAGE
Lloh36:
	add	x8, x8, l_.str.5@PAGEOFF
LBB0_36:
Lloh37:
	adrp	x9, _EM28XX_NOSENSOR@GOTPAGE
Lloh38:
	ldr	x9, [x9, _EM28XX_NOSENSOR@GOTPAGEOFF]
Lloh39:
	ldr	x9, [x9]
	ldp	x10, x0, [x19, #8]
	cmp	x10, x9
	b.ne	LBB0_38
; %bb.37:
	str	x8, [sp]
Lloh40:
	adrp	x1, l_.str.11@PAGE
Lloh41:
	add	x1, x1, l_.str.11@PAGEOFF
	b	LBB0_39
LBB0_38:
	str	x8, [sp]
Lloh42:
	adrp	x1, l_.str.12@PAGE
Lloh43:
	add	x1, x1, l_.str.12@PAGEOFF
LBB0_39:
	bl	_dev_info
	mov	w0, #0
	b	LBB0_2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpAdd	Lloh42, Lloh43
	.cfi_endproc
                                        ; -- End function
	.comm	_EM28XX_NOSENSOR,8,3            ; @EM28XX_NOSENSOR
	.comm	_omnivision_sensor_addrs,8,3    ; @omnivision_sensor_addrs
	.comm	_I2C_CLIENT_END,8,3             ; @I2C_CLIENT_END
	.comm	_ENXIO,4,2                      ; @ENXIO
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"couldn't read from i2c device 0x%02x: error %i\n"

l_.str.1:                               ; @.str.1
	.asciz	"OV2640"

	.comm	_EM28XX_OV2640,8,3              ; @EM28XX_OV2640
l_.str.2:                               ; @.str.2
	.asciz	"OV7648"

l_.str.3:                               ; @.str.3
	.asciz	"OV7660"

l_.str.4:                               ; @.str.4
	.asciz	"OV7670"

l_.str.5:                               ; @.str.5
	.asciz	"OV7720"

l_.str.6:                               ; @.str.6
	.asciz	"OV7725"

l_.str.7:                               ; @.str.7
	.asciz	"OV9640"

l_.str.8:                               ; @.str.8
	.asciz	"OV9650"

l_.str.9:                               ; @.str.9
	.asciz	"OV9655"

l_.str.10:                              ; @.str.10
	.asciz	"unknown OmniVision sensor detected: 0x%04x\n"

l_.str.11:                              ; @.str.11
	.asciz	"unsupported sensor detected: %s\n"

l_.str.12:                              ; @.str.12
	.asciz	"sensor %s detected\n"

	.comm	_ENODEV,4,2                     ; @ENODEV
	.no_dead_strip	_em28xx_probe_sensor_omnivision
.subsections_via_symbols
