	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function write_regvals
_write_regvals:                         ## @write_regvals
	.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	(%rsi), %rcx
	movq	_OV511_DONE_BUS@GOTPCREL(%rip), %r12
	xorl	%eax, %eax
	cmpq	(%r12), %rcx
	je	LBB0_9
## %bb.1:
	movq	%rsi, %rbx
	movq	%rdi, %r15
	addq	$8, %rbx
	movq	_OV511_REG_BUS@GOTPCREL(%rip), %r13
	movq	_OV511_I2C_BUS@GOTPCREL(%rip), %r14
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	(%r13), %rcx
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	(%rbx), %edx
	movl	4(%rbx), %esi
	movq	%r15, %rdi
	callq	_reg_w
	testl	%eax, %eax
	jns	LBB0_7
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	cmpq	(%r14), %rcx
	jne	LBB0_10
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	(%rbx), %edx
	movl	4(%rbx), %esi
	movq	%r15, %rdi
	callq	_i2c_w
	testl	%eax, %eax
	js	LBB0_9
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rbx), %rcx
	addq	$16, %rbx
	cmpq	(%r12), %rcx
	jne	LBB0_2
## %bb.8:
	xorl	%eax, %eax
	jmp	LBB0_9
LBB0_10:
	leaq	L_.str(%rip), %rdi
	callq	_err
	movl	$-1, %eax
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_OV511_DONE_BUS,8,3             ## @OV511_DONE_BUS
	.comm	_OV511_REG_BUS,8,3              ## @OV511_REG_BUS
	.comm	_OV511_I2C_BUS,8,3              ## @OV511_I2C_BUS
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Bad regval array"

	.no_dead_strip	_write_regvals
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function write_regvals
_write_regvals:                         ; @write_regvals
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	x8, [x1]
Lloh0:
	adrp	x20, _OV511_DONE_BUS@GOTPAGE
Lloh1:
	ldr	x20, [x20, _OV511_DONE_BUS@GOTPAGEOFF]
	ldr	x9, [x20]
	cmp	x8, x9
	b.ne	LBB0_3
LBB0_1:
	mov	w0, #0
LBB0_2:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_3:
	mov	x19, x0
	add	x21, x1, #8
Lloh2:
	adrp	x22, _OV511_REG_BUS@GOTPAGE
Lloh3:
	ldr	x22, [x22, _OV511_REG_BUS@GOTPAGEOFF]
Lloh4:
	adrp	x23, _OV511_I2C_BUS@GOTPAGE
Lloh5:
	ldr	x23, [x23, _OV511_I2C_BUS@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldp	w2, w1, [x21]
	mov	x0, x19
	bl	_reg_w
	tbnz	w0, #31, LBB0_2
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [x21, #8]
	ldr	x9, [x20]
	add	x21, x21, #16
	cmp	x8, x9
	b.eq	LBB0_1
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x22]
	cmp	x8, x9
	b.eq	LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x9, [x23]
	cmp	x8, x9
	b.ne	LBB0_9
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	ldp	w2, w1, [x21]
	mov	x0, x19
	bl	_i2c_w
	tbz	w0, #31, LBB0_5
	b	LBB0_2
LBB0_9:
Lloh6:
	adrp	x0, l_.str@PAGE
Lloh7:
	add	x0, x0, l_.str@PAGEOFF
	bl	_err
	mov	w0, #-1
	b	LBB0_2
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_OV511_DONE_BUS,8,3             ; @OV511_DONE_BUS
	.comm	_OV511_REG_BUS,8,3              ; @OV511_REG_BUS
	.comm	_OV511_I2C_BUS,8,3              ; @OV511_I2C_BUS
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Bad regval array"

	.no_dead_strip	_write_regvals
.subsections_via_symbols
