	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ks0127_read
_ks0127_read:                           ## @ks0127_read
	.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	%rbx
	subq	$72, %rsp
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -32(%rbp)
	movb	%sil, -82(%rbp)
	callq	_v4l2_get_subdevdata
	movb	$0, -81(%rbp)
	movl	$1, -80(%rbp)
	leaq	-82(%rbp), %rcx
	movq	%rcx, -72(%rbp)
	movl	$0, -64(%rbp)
	movl	4(%rax), %ecx
	movl	%ecx, -60(%rbp)
	movl	$1, -56(%rbp)
	movq	_I2C_M_RD@GOTPCREL(%rip), %rdx
	movq	_I2C_M_NO_RD_ACK@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
	orl	(%rdx), %esi
	leaq	-81(%rbp), %rdx
	movq	%rdx, -48(%rbp)
	movl	%esi, -40(%rbp)
	movl	%ecx, -36(%rbp)
	movl	(%rax), %ebx
	leaq	-80(%rbp), %r15
	movq	%r15, %rdi
	callq	_ARRAY_SIZE
	movl	%ebx, %edi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_i2c_transfer
	movl	%eax, %ebx
	movq	%r15, %rdi
	callq	_ARRAY_SIZE
	cmpl	%eax, %ebx
	je	LBB0_2
## %bb.1:
	movq	_debug@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rcx
	movl	$1, %edi
	movq	%r14, %rdx
	callq	_v4l2_dbg
LBB0_2:
	movsbl	-81(%rbp), %eax
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-32(%rbp), %rcx
	jne	LBB0_4
## %bb.3:
	addq	$72, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_I2C_M_RD,4,2                   ## @I2C_M_RD
	.comm	_I2C_M_NO_RD_ACK,4,2            ## @I2C_M_NO_RD_ACK
	.comm	_debug,4,2                      ## @debug
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"read error\n"

	.no_dead_strip	_ks0127_read
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ks0127_read
_ks0127_read:                           ; @ks0127_read
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-24]
	strb	w1, [sp, #7]
	bl	_v4l2_get_subdevdata
	strb	wzr, [sp, #6]
	mov	w8, #1
	str	w8, [sp, #8]
	add	x9, sp, #7
	str	x9, [sp, #16]
	str	wzr, [sp, #24]
	ldr	w9, [x0, #4]
	stp	w9, w8, [sp, #28]
	add	x8, sp, #6
	str	x8, [sp, #40]
Lloh3:
	adrp	x8, _I2C_M_RD@GOTPAGE
Lloh4:
	ldr	x8, [x8, _I2C_M_RD@GOTPAGEOFF]
Lloh5:
	adrp	x10, _I2C_M_NO_RD_ACK@GOTPAGE
Lloh6:
	ldr	x10, [x10, _I2C_M_NO_RD_ACK@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
Lloh8:
	ldr	w10, [x10]
	orr	w8, w10, w8
	stp	w8, w9, [sp, #48]
	ldr	w20, [x0]
	add	x0, sp, #8
	bl	_ARRAY_SIZE
	mov	x2, x0
	add	x1, sp, #8
	mov	x0, x20
	bl	_i2c_transfer
	mov	x20, x0
	add	x0, sp, #8
	bl	_ARRAY_SIZE
	cmp	w20, w0
	b.eq	LBB0_2
; %bb.1:
Lloh9:
	adrp	x8, _debug@GOTPAGE
Lloh10:
	ldr	x8, [x8, _debug@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x3, l_.str@PAGE
Lloh13:
	add	x3, x3, l_.str@PAGEOFF
	mov	w0, #1
	mov	x2, x19
	bl	_v4l2_dbg
LBB0_2:
	ldrsb	w0, [sp, #6]
	ldur	x8, [x29, #-24]
Lloh14:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh15:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_4
; %bb.3:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_4:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh7
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_I2C_M_RD,4,2                   ; @I2C_M_RD
	.comm	_I2C_M_NO_RD_ACK,4,2            ; @I2C_M_NO_RD_ACK
	.comm	_debug,4,2                      ; @debug
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"read error\n"

	.no_dead_strip	_ks0127_read
.subsections_via_symbols
