	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mwl8k_stop
_mwl8k_stop:                            ## @mwl8k_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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	(%rdi), %r15
	cmpl	$0, 48(%r15)
	jne	LBB0_2
## %bb.1:
	movq	%r14, %rdi
	callq	_mwl8k_cmd_radio_disable
LBB0_2:
	movq	%r14, %rdi
	callq	_ieee80211_stop_queues
	movq	_MWL8K_HIU_A2H_INTERRUPT_MASK@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	addq	40(%r15), %rsi
	xorl	%edi, %edi
	callq	_iowrite32
	cmpl	$-1, (%r15)
	je	LBB0_4
## %bb.3:
	movq	32(%r15), %rax
	movl	(%rax), %edi
	movq	%r14, %rsi
	callq	_free_irq
	movl	$-1, (%r15)
LBB0_4:
	leaq	28(%r15), %rdi
	callq	_cancel_work_sync
	leaq	24(%r15), %rdi
	callq	_cancel_work_sync
	movq	16(%r15), %rdi
	testq	%rdi, %rdi
	je	LBB0_6
## %bb.5:
	callq	_dev_kfree_skb
LBB0_6:
	leaq	8(%r15), %rdi
	callq	_tasklet_disable
	leaq	4(%r15), %rdi
	callq	_tasklet_disable
	movq	%r15, %rdi
	callq	_mwl8k_tx_queues
	testl	%eax, %eax
	jle	LBB0_9
## %bb.7:
	xorl	%ebx, %ebx
	movq	_INT_MAX@GOTPCREL(%rip), %r12
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %edx
	movq	%r14, %rdi
	movl	%ebx, %esi
	movl	$1, %ecx
	callq	_mwl8k_txq_reclaim
	incl	%ebx
	movq	%r15, %rdi
	callq	_mwl8k_tx_queues
	cmpl	%eax, %ebx
	jl	LBB0_8
LBB0_9:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_MWL8K_HIU_A2H_INTERRUPT_MASK,8,3 ## @MWL8K_HIU_A2H_INTERRUPT_MASK
	.comm	_INT_MAX,4,2                    ## @INT_MAX
	.no_dead_strip	_mwl8k_stop
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mwl8k_stop
_mwl8k_stop:                            ; @mwl8k_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
	ldr	x20, [x0]
	ldr	w8, [x20, #48]
	cbnz	w8, LBB0_2
; %bb.1:
	mov	x0, x19
	bl	_mwl8k_cmd_radio_disable
LBB0_2:
	mov	x0, x19
	bl	_ieee80211_stop_queues
	ldr	x8, [x20, #40]
Lloh0:
	adrp	x9, _MWL8K_HIU_A2H_INTERRUPT_MASK@GOTPAGE
Lloh1:
	ldr	x9, [x9, _MWL8K_HIU_A2H_INTERRUPT_MASK@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	add	x1, x9, x8
	mov	w0, #0
	bl	_iowrite32
	ldr	w8, [x20]
	cmn	w8, #1
	b.eq	LBB0_4
; %bb.3:
	ldr	x8, [x20, #32]
	ldr	w0, [x8]
	mov	x1, x19
	bl	_free_irq
	mov	w8, #-1
	str	w8, [x20]
LBB0_4:
	add	x0, x20, #28
	bl	_cancel_work_sync
	add	x0, x20, #24
	bl	_cancel_work_sync
	ldr	x0, [x20, #16]
	cbz	x0, LBB0_6
; %bb.5:
	bl	_dev_kfree_skb
LBB0_6:
	add	x0, x20, #8
	bl	_tasklet_disable
	add	x0, x20, #4
	bl	_tasklet_disable
	mov	x0, x20
	bl	_mwl8k_tx_queues
	cmp	w0, #1
	b.lt	LBB0_9
; %bb.7:
	mov	w21, #0
Lloh3:
	adrp	x22, _INT_MAX@GOTPAGE
Lloh4:
	ldr	x22, [x22, _INT_MAX@GOTPAGEOFF]
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w2, [x22]
	mov	x0, x19
	mov	x1, x21
	mov	w3, #1
	bl	_mwl8k_txq_reclaim
	add	w21, w21, #1
	mov	x0, x20
	bl	_mwl8k_tx_queues
	cmp	w21, w0
	b.lt	LBB0_8
LBB0_9:
	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 AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_MWL8K_HIU_A2H_INTERRUPT_MASK,8,3 ; @MWL8K_HIU_A2H_INTERRUPT_MASK
	.comm	_INT_MAX,4,2                    ; @INT_MAX
	.no_dead_strip	_mwl8k_stop
.subsections_via_symbols
