	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ath6kl_uapsd_trigger_frame_rx
_ath6kl_uapsd_trigger_frame_rx:         ## @ath6kl_uapsd_trigger_frame_rx
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movl	(%rsi), %r12d
	movq	_ATH6KL_APSD_NUM_OF_AC@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	sarl	%cl, %r12d
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	movq	_ATH6KL_APSD_FRAME_MASK@GOTPCREL(%rip), %rax
	andl	(%rax), %r12d
	jne	LBB0_2
## %bb.1:
	movq	_ATH6KL_APSD_ALL_FRAME@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
LBB0_2:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	leaq	12(%rbx), %r14
	movq	%r14, %rdi
	callq	_spin_lock_bh
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	leaq	16(%rbx), %rdi
	movq	%rdi, -88(%rbp)                 ## 8-byte Spill
	callq	_skb_queue_empty
	movl	%eax, %r15d
	movq	%r14, -96(%rbp)                 ## 8-byte Spill
	movq	%r14, %rdi
	callq	_spin_unlock_bh
	testl	%r15d, %r15d
	sete	%r13b
	jne	LBB0_3
## %bb.4:
	testl	%r12d, %r12d
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	je	LBB0_10
## %bb.5:
	movl	%r15d, -76(%rbp)                ## 4-byte Spill
	decl	%r12d
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	-96(%rbp), %r13                 ## 8-byte Reload
	movq	%r13, %rdi
	callq	_spin_lock_bh
	movq	-88(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_skb_dequeue
	movq	%rax, %r15
	movq	%rbx, %rdi
	callq	_skb_queue_empty
	movl	%eax, %r14d
	movq	%r13, %rdi
	callq	_spin_unlock_bh
	movl	8(%r12), %eax
	movq	_STA_PS_APSD_TRIGGER@GOTPCREL(%rip), %rbx
	orl	(%rbx), %eax
	movl	%eax, 8(%r12)
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	addl	$-1, %edx
	setb	%cl
	testl	%r14d, %r14d
	sete	%r13b
	jne	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	testb	%cl, %cl
	je	LBB0_9
## %bb.6:                               ##   in Loop: Header=BB0_7 Depth=1
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	4(%rax), %esi
	movq	%r15, %rdi
	callq	_ath6kl_data_tx
	movl	(%rbx), %eax
	movq	_STA_PS_APSD_EOSP@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	notl	%eax
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	andl	%eax, 8(%r12)
	jmp	LBB0_7
LBB0_9:
	movq	_STA_PS_APSD_EOSP@GOTPCREL(%rip), %r12
	orl	(%r12), %eax
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movl	%eax, 8(%r14)
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	4(%rax), %esi
	movq	%r15, %rdi
	callq	_ath6kl_data_tx
	movl	(%rbx), %eax
	orl	(%r12), %eax
	notl	%eax
	andl	%eax, 8(%r14)
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	movl	-76(%rbp), %r15d                ## 4-byte Reload
LBB0_10:
	testb	%r13b, %r13b
	je	LBB0_11
LBB0_14:
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	testb	%r13b, %r13b
	jne	LBB0_14
LBB0_11:
	testl	%r15d, %r15d
	je	LBB0_13
## %bb.12:
	movq	_WMI_AP_APSD_NO_DELIVERY_FRAMES@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
LBB0_13:
	movl	(%rcx), %edi
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %esi
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	4(%rax), %edx
	xorl	%ecx, %ecx
	movl	%r15d, %r8d
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ath6kl_wmi_set_apsd_bfrd_traf  ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_ATH6KL_APSD_NUM_OF_AC,4,2      ## @ATH6KL_APSD_NUM_OF_AC
	.comm	_ATH6KL_APSD_FRAME_MASK,4,2     ## @ATH6KL_APSD_FRAME_MASK
	.comm	_ATH6KL_APSD_ALL_FRAME,4,2      ## @ATH6KL_APSD_ALL_FRAME
	.comm	_STA_PS_APSD_TRIGGER,4,2        ## @STA_PS_APSD_TRIGGER
	.comm	_STA_PS_APSD_EOSP,4,2           ## @STA_PS_APSD_EOSP
	.comm	_WMI_AP_APSD_NO_DELIVERY_FRAMES,4,2 ## @WMI_AP_APSD_NO_DELIVERY_FRAMES
	.no_dead_strip	_ath6kl_uapsd_trigger_frame_rx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ath6kl_uapsd_trigger_frame_rx
_ath6kl_uapsd_trigger_frame_rx:         ; @ath6kl_uapsd_trigger_frame_rx
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x1
	mov	x20, x0
	mov	x22, x1
	ldr	w8, [x22], #16
Lloh0:
	adrp	x9, _ATH6KL_APSD_NUM_OF_AC@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ATH6KL_APSD_NUM_OF_AC@GOTPAGEOFF]
	ldr	x25, [x0, #8]
Lloh2:
	ldr	w9, [x9]
	asr	w8, w8, w9
Lloh3:
	adrp	x9, _ATH6KL_APSD_FRAME_MASK@GOTPAGE
Lloh4:
	ldr	x9, [x9, _ATH6KL_APSD_FRAME_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
Lloh6:
	adrp	x10, _ATH6KL_APSD_ALL_FRAME@GOTPAGE
Lloh7:
	ldr	x10, [x10, _ATH6KL_APSD_ALL_FRAME@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	ands	w8, w8, w9
	csel	w24, w10, w8, eq
	add	x23, x1, #12
	mov	x0, x23
	bl	_spin_lock_bh
	mov	x0, x22
	bl	_skb_queue_empty
	mov	x26, x0
	mov	x0, x23
	bl	_spin_unlock_bh
	cmp	w26, #0
	cset	w21, eq
	cbnz	w26, LBB0_7
; %bb.1:
	cbz	w24, LBB0_7
; %bb.2:
	str	w26, [sp, #4]                   ; 4-byte Folded Spill
	str	x25, [sp, #8]                   ; 8-byte Folded Spill
	sub	w26, w24, #1
Lloh9:
	adrp	x28, _STA_PS_APSD_TRIGGER@GOTPAGE
Lloh10:
	ldr	x28, [x28, _STA_PS_APSD_TRIGGER@GOTPAGEOFF]
Lloh11:
	adrp	x27, _STA_PS_APSD_EOSP@GOTPAGE
Lloh12:
	ldr	x27, [x27, _STA_PS_APSD_EOSP@GOTPAGEOFF]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x23
	bl	_spin_lock_bh
	mov	x0, x22
	bl	_skb_dequeue
	mov	x24, x0
	mov	x0, x22
	bl	_skb_queue_empty
	mov	x25, x0
	mov	x0, x23
	bl	_spin_unlock_bh
	ldr	w8, [x28]
	ldr	w9, [x19, #8]
	orr	w8, w9, w8
	str	w8, [x19, #8]
	cmp	w25, #0
	cset	w21, eq
	subs	w26, w26, #1
	cset	w9, hs
	cbnz	w25, LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	tbz	w9, #0, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w1, [x20, #4]
	mov	x0, x24
	bl	_ath6kl_data_tx
	ldr	w8, [x28]
	ldr	w9, [x19, #8]
	ldr	w10, [x27]
	orr	w8, w8, w10
	bic	w8, w9, w8
	str	w8, [x19, #8]
	b	LBB0_3
LBB0_6:
	ldr	w9, [x27]
	orr	w8, w9, w8
	str	w8, [x19, #8]
	ldr	w1, [x20, #4]
	mov	x0, x24
	bl	_ath6kl_data_tx
	ldr	w8, [x28]
	ldr	w9, [x19, #8]
	ldr	w10, [x27]
	orr	w8, w8, w10
	bic	w8, w9, w8
	str	w8, [x19, #8]
	ldr	x25, [sp, #8]                   ; 8-byte Folded Reload
	ldr	w26, [sp, #4]                   ; 4-byte Folded Reload
LBB0_7:
	tbz	w21, #0, LBB0_9
; %bb.8:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_9:
Lloh13:
	adrp	x8, _WMI_AP_APSD_NO_DELIVERY_FRAMES@GOTPAGE
Lloh14:
	ldr	x8, [x8, _WMI_AP_APSD_NO_DELIVERY_FRAMES@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	cmp	w26, #0
	csel	w4, wzr, w8, eq
	ldr	w0, [x25]
	ldr	w1, [x20]
	ldr	w2, [x19, #4]
	mov	w3, #0
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_ath6kl_wmi_set_apsd_bfrd_traf
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.cfi_endproc
                                        ; -- End function
	.comm	_ATH6KL_APSD_NUM_OF_AC,4,2      ; @ATH6KL_APSD_NUM_OF_AC
	.comm	_ATH6KL_APSD_FRAME_MASK,4,2     ; @ATH6KL_APSD_FRAME_MASK
	.comm	_ATH6KL_APSD_ALL_FRAME,4,2      ; @ATH6KL_APSD_ALL_FRAME
	.comm	_STA_PS_APSD_TRIGGER,4,2        ; @STA_PS_APSD_TRIGGER
	.comm	_STA_PS_APSD_EOSP,4,2           ; @STA_PS_APSD_EOSP
	.comm	_WMI_AP_APSD_NO_DELIVERY_FRAMES,4,2 ; @WMI_AP_APSD_NO_DELIVERY_FRAMES
	.no_dead_strip	_ath6kl_uapsd_trigger_frame_rx
.subsections_via_symbols
