	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cm36651_write_prox_thresh
_cm36651_write_prox_thresh:             ## @cm36651_write_prox_thresh
	.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
	.cfi_offset %rbx, -32
	.cfi_offset %r14, -24
	movl	%r9d, %ebx
	callq	_iio_priv
	leal	-256(%rbx), %ecx
	cmpl	$-254, %ecx
	ja	LBB0_2
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_4
LBB0_2:
	movq	16(%rax), %r14
	movq	(%rax), %rcx
	movq	_CM36651_PS_THD@GOTPCREL(%rip), %rdx
	movq	(%rdx), %rsi
	movl	%ebx, (%rcx,%rsi,4)
	movl	8(%rax), %edi
	movl	%ebx, %edx
	callq	_i2c_smbus_write_byte_data
	movl	%eax, %ebx
	xorl	%eax, %eax
	testl	%ebx, %ebx
	jns	LBB0_4
## %bb.3:
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	callq	_dev_err
	movl	%ebx, %eax
LBB0_4:
	popq	%rbx
	popq	%r14
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_CM36651_PS_THD,8,3             ## @CM36651_PS_THD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"PS threshold write failed: %d\n"

	.no_dead_strip	_cm36651_write_prox_thresh
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cm36651_write_prox_thresh
_cm36651_write_prox_thresh:             ; @cm36651_write_prox_thresh
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x5
	bl	_iio_priv
	sub	w8, w19, #256
	cmn	w8, #254
	b.hi	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w19, w8
	b	LBB0_5
LBB0_2:
	ldr	x20, [x0, #16]
	ldr	x8, [x0]
Lloh3:
	adrp	x9, _CM36651_PS_THD@GOTPAGE
Lloh4:
	ldr	x9, [x9, _CM36651_PS_THD@GOTPAGEOFF]
Lloh5:
	ldr	x1, [x9]
	str	w19, [x8, x1, lsl #2]
	ldr	w0, [x0, #8]
	mov	x2, x19
	bl	_i2c_smbus_write_byte_data
	tbnz	w0, #31, LBB0_4
; %bb.3:
	mov	w19, #0
	b	LBB0_5
LBB0_4:
	mov	x19, x0
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x20
	mov	x2, x19
	bl	_dev_err
LBB0_5:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpAdd	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_CM36651_PS_THD,8,3             ; @CM36651_PS_THD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"PS threshold write failed: %d\n"

	.no_dead_strip	_cm36651_write_prox_thresh
.subsections_via_symbols
