	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath9k_tx_last_beacon
_ath9k_tx_last_beacon:                  ## @ath9k_tx_last_beacon
	.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	(%rdi), %rbx
	movq	8(%rbx), %rax
	movq	(%rax), %rcx
	xorl	%eax, %eax
	testq	%rcx, %rcx
	je	LBB0_9
## %bb.1:
	cmpl	$0, 8(%rcx)
	je	LBB0_9
## %bb.2:
	movq	24(%rbx), %r15
	movq	_ATH9K_HW_CAP_EDMA@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	(%r15), %eax
	orl	(%rbx), %eax
	jne	LBB0_8
## %bb.3:
	movq	(%rcx), %r12
	leaq	16(%rbx), %r14
	movq	%r14, %rdi
	callq	_tasklet_disable
	movq	(%r12), %rax
	testq	%rax, %rax
	je	LBB0_7
## %bb.4:
	cmpl	$0, 4(%rax)
	je	LBB0_7
## %bb.5:
	movl	(%rax), %esi
	leaq	-40(%rbp), %rdx
	movq	%r15, %rdi
	callq	_ath9k_hw_txprocdesc
	movq	_EINPROGRESS@GOTPCREL(%rip), %rcx
	addl	(%rcx), %eax
	je	LBB0_7
## %bb.6:
	movl	$1, (%rbx)
	movq	_ATH9K_TXERR_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	xorl	%ecx, %ecx
	andl	-40(%rbp), %eax
	sete	%cl
	movl	%ecx, 4(%rbx)
LBB0_7:
	movq	%r14, %rdi
	callq	_tasklet_enable
LBB0_8:
	movl	4(%rbx), %eax
LBB0_9:
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ATH9K_HW_CAP_EDMA,4,2          ## @ATH9K_HW_CAP_EDMA
	.comm	_EINPROGRESS,4,2                ## @EINPROGRESS
	.comm	_ATH9K_TXERR_MASK,4,2           ## @ATH9K_TXERR_MASK
	.no_dead_strip	_ath9k_tx_last_beacon
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath9k_tx_last_beacon
_ath9k_tx_last_beacon:                  ; @ath9k_tx_last_beacon
	.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
	ldr	x21, [x0]
	ldr	x8, [x21, #8]
	ldr	x8, [x8]
	cbz	x8, LBB0_9
; %bb.1:
	ldr	w9, [x8, #8]
	cbz	w9, LBB0_9
; %bb.2:
	ldr	x20, [x21, #24]
	ldr	w9, [x20]
Lloh0:
	adrp	x10, _ATH9K_HW_CAP_EDMA@GOTPAGE
Lloh1:
	ldr	x10, [x10, _ATH9K_HW_CAP_EDMA@GOTPAGEOFF]
Lloh2:
	ldr	w10, [x10]
	and	w9, w10, w9
	ldr	w10, [x21]
	orr	w9, w10, w9
	cbnz	w9, LBB0_8
; %bb.3:
	ldr	x22, [x8]
	add	x19, x21, #16
	mov	x0, x19
	bl	_tasklet_disable
	ldr	x8, [x22]
	cbz	x8, LBB0_7
; %bb.4:
	ldr	w9, [x8, #4]
	cbz	w9, LBB0_7
; %bb.5:
	ldr	w1, [x8]
	add	x2, sp, #8
	mov	x0, x20
	bl	_ath9k_hw_txprocdesc
Lloh3:
	adrp	x8, _EINPROGRESS@GOTPAGE
Lloh4:
	ldr	x8, [x8, _EINPROGRESS@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	cmn	w0, w8
	b.eq	LBB0_7
; %bb.6:
	mov	w8, #1
	str	w8, [x21]
	ldr	w8, [sp, #8]
Lloh6:
	adrp	x9, _ATH9K_TXERR_MASK@GOTPAGE
Lloh7:
	ldr	x9, [x9, _ATH9K_TXERR_MASK@GOTPAGEOFF]
Lloh8:
	ldr	w9, [x9]
	tst	w9, w8
	cset	w8, eq
	str	w8, [x21, #4]
LBB0_7:
	mov	x0, x19
	bl	_tasklet_enable
LBB0_8:
	ldr	w0, [x21, #4]
	b	LBB0_10
LBB0_9:
	mov	w0, #0
LBB0_10:
	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 AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_ATH9K_HW_CAP_EDMA,4,2          ; @ATH9K_HW_CAP_EDMA
	.comm	_EINPROGRESS,4,2                ; @EINPROGRESS
	.comm	_ATH9K_TXERR_MASK,4,2           ; @ATH9K_TXERR_MASK
	.no_dead_strip	_ath9k_tx_last_beacon
.subsections_via_symbols
