	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cxd2841er_read_agc_gain_s
_cxd2841er_read_agc_gain_s:             ## @cxd2841er_read_agc_gain_s
	.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	$16, %rsp
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movq	%rdi, %rbx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -24(%rbp)
	movq	_I2C_SLVT@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	xorl	%edx, %edx
	movl	$160, %ecx
	callq	_cxd2841er_write_reg
	movl	(%r14), %esi
	leaq	-32(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$31, %edx
	movl	$2, %r8d
	callq	_cxd2841er_read_regs
	movl	-32(%rbp), %eax
	movzbl	-28(%rbp), %ecx
	movq	___stack_chk_guard@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rdx
	cmpq	-24(%rbp), %rdx
	jne	LBB0_2
## %bb.1:
	andl	$31, %eax
	shll	$8, %eax
	orl	%ecx, %eax
	shll	$3, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
LBB0_2:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_I2C_SLVT,4,2                   ## @I2C_SLVT
	.no_dead_strip	_cxd2841er_read_agc_gain_s
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cxd2841er_read_agc_gain_s
_cxd2841er_read_agc_gain_s:             ; @cxd2841er_read_agc_gain_s
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #8]
Lloh3:
	adrp	x20, _I2C_SLVT@GOTPAGE
Lloh4:
	ldr	x20, [x20, _I2C_SLVT@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	w2, #0
	mov	w3, #160
	bl	_cxd2841er_write_reg
	ldr	w1, [x20]
	mov	x3, sp
	mov	x0, x19
	mov	w2, #31
	mov	w4, #2
	bl	_cxd2841er_read_regs
	ldr	w8, [sp]
	ldrb	w9, [sp, #4]
	ldr	x10, [sp, #8]
Lloh5:
	adrp	x11, ___stack_chk_guard@GOTPAGE
Lloh6:
	ldr	x11, [x11, ___stack_chk_guard@GOTPAGEOFF]
Lloh7:
	ldr	x11, [x11]
	cmp	x11, x10
	b.ne	LBB0_2
; %bb.1:
	bfi	w9, w8, #8, #5
	lsl	w0, w9, #3
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_2:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_I2C_SLVT,4,2                   ; @I2C_SLVT
	.no_dead_strip	_cxd2841er_read_agc_gain_s
.subsections_via_symbols
