	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function store_beep
_store_beep:                            ## @store_beep
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r14
	movq	%rdi, %rbx
	movq	%rsi, %rdi
	callq	_to_sensor_dev_attr
	movq	%rax, %r13
	movq	%rbx, %rdi
	callq	_to_i2c_client
	movq	%rax, %r15
	movq	%rax, %rdi
	callq	_i2c_get_clientdata
	movq	%rax, %r12
	movl	(%r13), %r13d
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	movl	$10, %esi
	callq	_kstrtoul
	testl	%eax, %eax
	jne	LBB0_2
## %bb.1:
	leal	7(%r13), %ebx
	testl	%r13d, %r13d
	cmovnsl	%r13d, %ebx
	movl	%ebx, %r14d
	sarl	$3, %r14d
	xorl	%eax, %eax
	cmpq	$0, -48(%rbp)
	setne	%al
	movq	%rax, -48(%rbp)
	movq	%r12, %rdi
	addq	$4, %rdi
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	callq	_mutex_lock
	andb	$-8, %bl
	movl	$255, %eax
	movl	%ebx, %ecx
	shll	%cl, %eax
	notl	%eax
	andl	%eax, (%r12)
	movq	_W83791D_REG_BEEP_CTRL@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	%r14d, %r14
	movl	(%rax,%r14,4), %esi
	movq	%r15, %rdi
	callq	_w83791d_read
	movl	%ebx, %ecx
	shll	%cl, %eax
	orl	(%r12), %eax
	btrl	%r13d, %eax
	movq	-48(%rbp), %rdx
	movl	%r13d, %ecx
	shlq	%cl, %rdx
	orl	%eax, %edx
	movl	%edx, (%r12)
	movq	_W83791D_REG_BEEP_CTRL@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movl	(%rax,%r14,4), %esi
	movl	%ebx, %ecx
	sarl	%cl, %edx
	movzbl	%dl, %edx
	movq	%r15, %rdi
	callq	_w83791d_write
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_mutex_unlock
	movq	-64(%rbp), %rax                 ## 8-byte Reload
                                        ## kill: def $eax killed $eax killed $rax
LBB0_2:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_W83791D_REG_BEEP_CTRL,8,3      ## @W83791D_REG_BEEP_CTRL
	.no_dead_strip	_store_beep
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function store_beep
_store_beep:                            ; @store_beep
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x19, x3
	mov	x22, x2
	mov	x20, x0
	mov	x0, x1
	bl	_to_sensor_dev_attr
	mov	x23, x0
	mov	x0, x20
	bl	_to_i2c_client
	mov	x20, x0
	bl	_i2c_get_clientdata
	mov	x21, x0
	ldr	w23, [x23]
	add	x2, sp, #8
	mov	x0, x22
	mov	w1, #10
	bl	_kstrtoul
	cbnz	w0, LBB0_2
; %bb.1:
	add	w8, w23, #7
	cmp	w23, #0
	csel	w24, w8, w23, lt
	asr	w25, w24, #3
	ldr	x8, [sp, #8]
	cmp	x8, #0
	cset	w8, ne
	str	x8, [sp, #8]
	add	x22, x21, #4
	mov	x0, x22
	bl	_mutex_lock
	and	w24, w24, #0xfffffff8
	mov	w8, #255
	lsl	w8, w8, w24
	ldr	w9, [x21]
	bic	w8, w9, w8
	str	w8, [x21]
Lloh0:
	adrp	x26, _W83791D_REG_BEEP_CTRL@GOTPAGE
Lloh1:
	ldr	x26, [x26, _W83791D_REG_BEEP_CTRL@GOTPAGEOFF]
	ldr	x8, [x26]
	sbfiz	x25, x25, #2, #32
	ldr	w1, [x8, x25]
	mov	x0, x20
	bl	_w83791d_read
	lsl	w8, w0, w24
	ldr	w9, [x21]
	orr	w8, w9, w8
	mov	w9, #1
	lsl	w9, w9, w23
	bic	w8, w8, w9
	ldr	x9, [sp, #8]
	lsl	x9, x9, x23
	orr	w8, w8, w9
	str	w8, [x21]
	ldr	x9, [x26]
	ldr	w1, [x9, x25]
	asr	w8, w8, w24
	and	w2, w8, #0xff
	mov	x0, x20
	bl	_w83791d_write
	mov	x0, x22
	bl	_mutex_unlock
	mov	x0, x19
LBB0_2:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_W83791D_REG_BEEP_CTRL,8,3      ; @W83791D_REG_BEEP_CTRL
	.no_dead_strip	_store_beep
.subsections_via_symbols
