	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wl1271_plt_stop                ## -- Begin function wl1271_plt_stop
	.p2align	4, 0x90
_wl1271_plt_stop:                       ## @wl1271_plt_stop
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %rbx
	leaq	L_.str(%rip), %rdi
	callq	_wl1271_notice
	movq	%rbx, %rdi
	callq	_wlcore_disable_interrupts
	leaq	4(%rbx), %r14
	movq	%r14, %rdi
	callq	_mutex_lock
	movl	(%rbx), %r15d
	movq	%r14, %rdi
	callq	_mutex_unlock
	movq	%rbx, %rdi
	testl	%r15d, %r15d
	je	LBB0_1
## %bb.2:
	callq	_wl1271_flush_deferred_work
	leaq	48(%rbx), %rdi
	callq	_cancel_work_sync
	leaq	44(%rbx), %rdi
	callq	_cancel_work_sync
	leaq	40(%rbx), %rdi
	callq	_cancel_delayed_work_sync
	movq	%r14, %rdi
	callq	_mutex_lock
	movq	%rbx, %rdi
	callq	_wl1271_power_off
	movq	$0, 32(%rbx)
	movq	_WL1271_PSM_ILLEGAL@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rbx)
	movq	_WLCORE_STATE_OFF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 20(%rbx)
	movl	$0, (%rbx)
	movq	_PLT_OFF@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 16(%rbx)
	movq	$0, 8(%rbx)
	movq	%r14, %rdi
	callq	_mutex_unlock
	xorl	%eax, %eax
	jmp	LBB0_3
LBB0_1:
	callq	_wlcore_enable_interrupts
	movl	20(%rbx), %esi
	leaq	L_.str.1(%rip), %rdi
	callq	_wl1271_error
	movq	_EBUSY@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"power down"

L_.str.1:                               ## @.str.1
	.asciz	"cannot power down because not in PLT state: %d"

	.comm	_EBUSY,4,2                      ## @EBUSY
	.comm	_WL1271_PSM_ILLEGAL,4,2         ## @WL1271_PSM_ILLEGAL
	.comm	_WLCORE_STATE_OFF,4,2           ## @WLCORE_STATE_OFF
	.comm	_PLT_OFF,4,2                    ## @PLT_OFF
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_wl1271_plt_stop                ; -- Begin function wl1271_plt_stop
	.p2align	2
_wl1271_plt_stop:                       ; @wl1271_plt_stop
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x19, x0
Lloh0:
	adrp	x0, l_.str@PAGE
Lloh1:
	add	x0, x0, l_.str@PAGEOFF
	bl	_wl1271_notice
	mov	x0, x19
	bl	_wlcore_disable_interrupts
	add	x20, x19, #4
	mov	x0, x20
	bl	_mutex_lock
	ldr	w21, [x19]
	mov	x0, x20
	bl	_mutex_unlock
	mov	x0, x19
	cbz	w21, LBB0_2
; %bb.1:
	bl	_wl1271_flush_deferred_work
	add	x0, x19, #48
	bl	_cancel_work_sync
	add	x0, x19, #44
	bl	_cancel_work_sync
	add	x0, x19, #40
	bl	_cancel_delayed_work_sync
	mov	x0, x20
	bl	_mutex_lock
	mov	x0, x19
	bl	_wl1271_power_off
	str	xzr, [x19, #32]
Lloh2:
	adrp	x8, _WL1271_PSM_ILLEGAL@GOTPAGE
Lloh3:
	ldr	x8, [x8, _WL1271_PSM_ILLEGAL@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	str	w8, [x19, #24]
Lloh5:
	adrp	x8, _WLCORE_STATE_OFF@GOTPAGE
Lloh6:
	ldr	x8, [x8, _WLCORE_STATE_OFF@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	str	wzr, [x19]
Lloh8:
	adrp	x9, _PLT_OFF@GOTPAGE
Lloh9:
	ldr	x9, [x9, _PLT_OFF@GOTPAGEOFF]
Lloh10:
	ldr	w9, [x9]
	stp	w9, w8, [x19, #16]
	str	xzr, [x19, #8]
	mov	x0, x20
	bl	_mutex_unlock
	mov	w0, #0
	b	LBB0_3
LBB0_2:
	bl	_wlcore_enable_interrupts
	ldr	w1, [x19, #20]
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_wl1271_error
Lloh13:
	adrp	x8, _EBUSY@GOTPAGE
Lloh14:
	ldr	x8, [x8, _EBUSY@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_3:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"power down"

l_.str.1:                               ; @.str.1
	.asciz	"cannot power down because not in PLT state: %d"

	.comm	_EBUSY,4,2                      ; @EBUSY
	.comm	_WL1271_PSM_ILLEGAL,4,2         ; @WL1271_PSM_ILLEGAL
	.comm	_WLCORE_STATE_OFF,4,2           ; @WLCORE_STATE_OFF
	.comm	_PLT_OFF,4,2                    ; @PLT_OFF
.subsections_via_symbols
