	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s5k4aa_set_noise
_s5k4aa_set_noise:                      ## @s5k4aa_set_noise
	.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
	movl	%esi, %ebx
	movq	%rdi, %r14
	movq	(%rdi), %rax
	movq	_S5K4AA_PAGE_MAP_2@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movl	%ecx, -20(%rbp)
	movq	_NOISE_SUPP_IDX@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	%esi, (%rax,%rcx,4)
	movq	_D_V4L2@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	%ebx, %edx
	callq	_PDEBUG
	movq	_S5K4AA_PAGE_MAP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-20(%rbp), %rdx
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_m5602_write_sensor
	testl	%eax, %eax
	js	LBB0_2
## %bb.1:
	andl	$1, %ebx
	movl	%ebx, -20(%rbp)
	movq	_S5K4AA_NOISE_SUPP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-20(%rbp), %rdx
	movq	%r14, %rdi
	movl	$1, %ecx
	callq	_m5602_write_sensor
LBB0_2:
	addq	$16, %rsp
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_S5K4AA_PAGE_MAP_2,4,2          ## @S5K4AA_PAGE_MAP_2
	.comm	_NOISE_SUPP_IDX,8,3             ## @NOISE_SUPP_IDX
	.comm	_D_V4L2,4,2                     ## @D_V4L2
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Set noise to %d"

	.comm	_S5K4AA_PAGE_MAP,4,2            ## @S5K4AA_PAGE_MAP
	.comm	_S5K4AA_NOISE_SUPP,4,2          ## @S5K4AA_NOISE_SUPP
	.no_dead_strip	_s5k4aa_set_noise
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s5k4aa_set_noise
_s5k4aa_set_noise:                      ; @s5k4aa_set_noise
	.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	x20, x1
	mov	x19, x0
	ldr	x8, [x0]
Lloh0:
	adrp	x9, _S5K4AA_PAGE_MAP_2@GOTPAGE
Lloh1:
	ldr	x9, [x9, _S5K4AA_PAGE_MAP_2@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	str	w9, [sp, #12]
Lloh3:
	adrp	x9, _NOISE_SUPP_IDX@GOTPAGE
Lloh4:
	ldr	x9, [x9, _NOISE_SUPP_IDX@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	str	w1, [x8, x9, lsl #2]
Lloh6:
	adrp	x8, _D_V4L2@GOTPAGE
Lloh7:
	ldr	x8, [x8, _D_V4L2@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
Lloh9:
	adrp	x1, l_.str@PAGE
Lloh10:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, x20
	bl	_PDEBUG
Lloh11:
	adrp	x8, _S5K4AA_PAGE_MAP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _S5K4AA_PAGE_MAP@GOTPAGEOFF]
Lloh13:
	ldr	w1, [x8]
	add	x2, sp, #12
	mov	x0, x19
	mov	w3, #1
	bl	_m5602_write_sensor
	tbnz	w0, #31, LBB0_2
; %bb.1:
	and	w8, w20, #0x1
	str	w8, [sp, #12]
Lloh14:
	adrp	x8, _S5K4AA_NOISE_SUPP@GOTPAGE
Lloh15:
	ldr	x8, [x8, _S5K4AA_NOISE_SUPP@GOTPAGEOFF]
Lloh16:
	ldr	w1, [x8]
	add	x2, sp, #12
	mov	x0, x19
	mov	w3, #1
	bl	_m5602_write_sensor
LBB0_2:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_S5K4AA_PAGE_MAP_2,4,2          ; @S5K4AA_PAGE_MAP_2
	.comm	_NOISE_SUPP_IDX,8,3             ; @NOISE_SUPP_IDX
	.comm	_D_V4L2,4,2                     ; @D_V4L2
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Set noise to %d"

	.comm	_S5K4AA_PAGE_MAP,4,2            ; @S5K4AA_PAGE_MAP
	.comm	_S5K4AA_NOISE_SUPP,4,2          ; @S5K4AA_NOISE_SUPP
	.no_dead_strip	_s5k4aa_set_noise
.subsections_via_symbols
