	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s5k5baf_check_fw_revision
_s5k5baf_check_fw_revision:             ## @s5k5baf_check_fw_revision
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	movq	_REG_FW_APIVER@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_s5k5baf_read
	movl	%eax, %r14d
	movq	_REG_FW_REVISION@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_s5k5baf_read
	movl	%eax, %r15d
	movq	_REG_FW_SENSOR_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_s5k5baf_read
	movl	%eax, %r12d
	movq	%rbx, %rdi
	callq	_s5k5baf_clear_error
	testl	%eax, %eax
	js	LBB0_3
## %bb.1:
	movslq	%r12d, %r8
	movzbl	%r15b, %ecx
	movslq	%r14d, %r14
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movq	%r14, %rdx
	callq	_v4l2_info
	movq	_S5K5BAF_FW_APIVER@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	cmpq	%r14, (%rcx)
	je	LBB0_3
## %bb.2:
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdi
	callq	_v4l2_err
	movq	_ENODEV@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_3:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_REG_FW_APIVER,4,2              ## @REG_FW_APIVER
	.comm	_REG_FW_REVISION,4,2            ## @REG_FW_REVISION
	.comm	_REG_FW_SENSOR_ID,4,2           ## @REG_FW_SENSOR_ID
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"FW API=%#x, revision=%#x sensor_id=%#x\n"

	.comm	_S5K5BAF_FW_APIVER,8,3          ## @S5K5BAF_FW_APIVER
L_.str.1:                               ## @.str.1
	.asciz	"FW API version not supported\n"

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

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s5k5baf_check_fw_revision
_s5k5baf_check_fw_revision:             ; @s5k5baf_check_fw_revision
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _REG_FW_APIVER@GOTPAGE
Lloh1:
	ldr	x8, [x8, _REG_FW_APIVER@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_s5k5baf_read
	mov	x20, x0
Lloh3:
	adrp	x8, _REG_FW_REVISION@GOTPAGE
Lloh4:
	ldr	x8, [x8, _REG_FW_REVISION@GOTPAGEOFF]
Lloh5:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_s5k5baf_read
	mov	x21, x0
Lloh6:
	adrp	x8, _REG_FW_SENSOR_ID@GOTPAGE
Lloh7:
	ldr	x8, [x8, _REG_FW_SENSOR_ID@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_s5k5baf_read
	mov	x22, x0
	mov	x0, x19
	bl	_s5k5baf_clear_error
	tbnz	w0, #31, LBB0_4
; %bb.1:
	sxtw	x4, w22
	and	w3, w21, #0xff
	sxtw	x20, w20
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	bl	_v4l2_info
Lloh11:
	adrp	x8, _S5K5BAF_FW_APIVER@GOTPAGE
Lloh12:
	ldr	x8, [x8, _S5K5BAF_FW_APIVER@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	cmp	x8, x20
	b.ne	LBB0_3
; %bb.2:
	mov	w0, #0
	b	LBB0_4
LBB0_3:
Lloh14:
	adrp	x1, l_.str.1@PAGE
Lloh15:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x19
	bl	_v4l2_err
Lloh16:
	adrp	x8, _ENODEV@GOTPAGE
Lloh17:
	ldr	x8, [x8, _ENODEV@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_4:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_REG_FW_APIVER,4,2              ; @REG_FW_APIVER
	.comm	_REG_FW_REVISION,4,2            ; @REG_FW_REVISION
	.comm	_REG_FW_SENSOR_ID,4,2           ; @REG_FW_SENSOR_ID
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"FW API=%#x, revision=%#x sensor_id=%#x\n"

	.comm	_S5K5BAF_FW_APIVER,8,3          ; @S5K5BAF_FW_APIVER
l_.str.1:                               ; @.str.1
	.asciz	"FW API version not supported\n"

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