	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function wl1271_sysfs_store_bt_coex_state
_wl1271_sysfs_store_bt_coex_state:      ## @wl1271_sysfs_store_bt_coex_state
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r14
	movq	%rdx, %rbx
	callq	_dev_get_drvdata
	movq	%rax, %r12
	leaq	-40(%rbp), %rdx
	movq	%rbx, %rdi
	movl	$10, %esi
	callq	_kstrtoul
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	%r12, %r15
	addq	$16, %r15
	movq	%r15, %rdi
	callq	_mutex_lock
	xorl	%eax, %eax
	cmpq	$0, -40(%rbp)
	setne	%al
	movq	%rax, -40(%rbp)
	cmpq	%rax, (%r12)
	je	LBB0_7
## %bb.3:
	movq	%rax, (%r12)
	movq	8(%r12), %rax
	movq	_WLCORE_STATE_ON@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpq	(%rcx), %rax
	setne	%dil
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_7
## %bb.4:
	movl	20(%r12), %edi
	callq	_pm_runtime_get_sync
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:
	movq	(%r12), %rsi
	movq	%r12, %rdi
	callq	_wl1271_acx_sg_enable
	movl	20(%r12), %edi
	callq	_pm_runtime_mark_last_busy
	movl	20(%r12), %edi
	callq	_pm_runtime_put_autosuspend
	jmp	LBB0_7
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_wl1271_warning
	jmp	LBB0_8
LBB0_5:
	movl	20(%r12), %edi
	callq	_pm_runtime_put_noidle
LBB0_7:
	movq	%r15, %rdi
	callq	_mutex_unlock
LBB0_8:
	movq	%r14, %rax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"incorrect value written to bt_coex_mode"

	.comm	_WLCORE_STATE_ON,8,3            ## @WLCORE_STATE_ON
	.no_dead_strip	_wl1271_sysfs_store_bt_coex_state
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function wl1271_sysfs_store_bt_coex_state
_wl1271_sysfs_store_bt_coex_state:      ; @wl1271_sysfs_store_bt_coex_state
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x19, x3
	mov	x21, x2
	bl	_dev_get_drvdata
	mov	x20, x0
	add	x2, sp, #8
	mov	x0, x21
	mov	w1, #10
	bl	_kstrtoul
	tbnz	w0, #31, LBB0_5
; %bb.1:
	add	x21, x20, #16
	mov	x0, x21
	bl	_mutex_lock
	ldr	x8, [sp, #8]
	cmp	x8, #0
	cset	w8, ne
	str	x8, [sp, #8]
	ldr	x9, [x20]
	cmp	x9, x8
	b.eq	LBB0_7
; %bb.2:
	str	x8, [x20]
	ldr	x8, [x20, #8]
Lloh0:
	adrp	x9, _WLCORE_STATE_ON@GOTPAGE
Lloh1:
	ldr	x9, [x9, _WLCORE_STATE_ON@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w0, ne
	bl	_unlikely
	cbnz	x0, LBB0_7
; %bb.3:
	ldr	w0, [x20, #20]
	bl	_pm_runtime_get_sync
	tbnz	w0, #31, LBB0_6
; %bb.4:
	ldr	x1, [x20]
	mov	x0, x20
	bl	_wl1271_acx_sg_enable
	ldr	w0, [x20, #20]
	bl	_pm_runtime_mark_last_busy
	ldr	w0, [x20, #20]
	bl	_pm_runtime_put_autosuspend
	b	LBB0_7
LBB0_5:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	bl	_wl1271_warning
	b	LBB0_8
LBB0_6:
	ldr	w0, [x20, #20]
	bl	_pm_runtime_put_noidle
LBB0_7:
	mov	x0, x21
	bl	_mutex_unlock
LBB0_8:
	mov	x0, x19
	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
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"incorrect value written to bt_coex_mode"

	.comm	_WLCORE_STATE_ON,8,3            ; @WLCORE_STATE_ON
	.no_dead_strip	_wl1271_sysfs_store_bt_coex_state
.subsections_via_symbols
