	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function __mt9t112_reg_write
___mt9t112_reg_write:                   ## @__mt9t112_reg_write
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r14
	pushq	%rbx
	subq	$80, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%edx, %ebx
	movq	%rdi, %r14
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	movl	%esi, %edi
	callq	_swab16
	movl	%eax, -56(%rbp)
	movl	%ebx, %edi
	callq	_swab16
	movl	%eax, -52(%rbp)
	leaq	-48(%rbp), %rbx
	leaq	-56(%rbp), %rsi
	movq	%rbx, %rdi
	movl	$2, %edx
	callq	_memcpy
	leaq	-40(%rbp), %rdi
	leaq	-52(%rbp), %rsi
	movl	$2, %edx
	callq	_memcpy
	movl	4(%r14), %eax
	movl	%eax, -64(%rbp)
	movq	$0, -72(%rbp)
	movl	$4, -88(%rbp)
	movq	%rbx, -80(%rbp)
	movl	(%r14), %edi
	leaq	-88(%rbp), %rsi
	movl	$1, %edx
	callq	_i2c_transfer
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	cmpq	-24(%rbp), %rcx
	jne	LBB0_2
## %bb.1:
	movl	%eax, %ecx
	sarl	$31, %ecx
	andl	%eax, %ecx
	movl	%ecx, %eax
	addq	$80, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_2:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	___mt9t112_reg_write
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function __mt9t112_reg_write
___mt9t112_reg_write:                   ; @__mt9t112_reg_write
	.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, x2
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-24]
	mov	x0, x1
	bl	_swab16
	str	w0, [sp, #36]
	mov	x0, x19
	bl	_swab16
	str	w0, [sp, #32]
	add	x19, sp, #40
	add	x0, sp, #40
	add	x1, sp, #36
	mov	w2, #2
	bl	_memcpy
	add	x0, x19, #8
	add	x1, sp, #32
	mov	w2, #2
	bl	_memcpy
	ldp	w0, w8, [x20]
	str	w8, [sp, #24]
	mov	w8, #4
	str	w8, [sp]
	stp	x19, xzr, [sp, #8]
	mov	x1, sp
	mov	w2, #1
	bl	_i2c_transfer
	cmp	w0, #0
	csel	w0, w0, wzr, lt
	ldur	x8, [x29, #-24]
Lloh3:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh4:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_2
; %bb.1:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_2:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	___mt9t112_reg_write
.subsections_via_symbols
