	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_iwlagn_txfifo_flush            ## -- Begin function iwlagn_txfifo_flush
	.p2align	4, 0x90
_iwlagn_txfifo_flush:                   ## @iwlagn_txfifo_flush
	.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
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	_IWL_DROP_ALL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	callq	_cpu_to_le16
	movl	%eax, -44(%rbp)
	movl	(%rbx), %edi
	callq	_cpu_to_le16
	movq	_IWL_SCD_VO_MSK@GOTPCREL(%rip), %rcx
	movq	_IWL_SCD_VI_MSK@GOTPCREL(%rip), %rdx
	movl	(%rdx), %ebx
	orl	(%rcx), %ebx
	movq	_IWL_SCD_BE_MSK@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movq	_IWL_SCD_BK_MSK@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movq	_IWL_SCD_MGMT_MSK@GOTPCREL(%rip), %rcx
	orl	(%rcx), %ebx
	movl	%eax, -36(%rbp)
	movq	(%r15), %r12
	movq	_IWL_RXON_CTX_BSS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_BIT
	cmpq	%rax, %r12
	je	LBB0_2
## %bb.1:
	movq	_IWL_PAN_SCD_VO_MSK@GOTPCREL(%rip), %rax
	movq	_IWL_PAN_SCD_VI_MSK@GOTPCREL(%rip), %rcx
	movq	_IWL_PAN_SCD_BE_MSK@GOTPCREL(%rip), %rdx
	movq	_IWL_PAN_SCD_BK_MSK@GOTPCREL(%rip), %rsi
	movq	_IWL_PAN_SCD_MGMT_MSK@GOTPCREL(%rip), %rdi
	movq	_IWL_PAN_SCD_MULTICAST_MSK@GOTPCREL(%rip), %r8
	orl	(%rax), %ebx
	orl	(%rcx), %ebx
	orl	(%rdx), %ebx
	orl	(%rsi), %ebx
	orl	(%rdi), %ebx
	orl	(%r8), %ebx
LBB0_2:
	movq	16(%r15), %rax
	cmpq	$0, (%rax)
	movl	$0, %r12d
	je	LBB0_4
## %bb.3:
	movq	_IWL_AGG_TX_QUEUE_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
LBB0_4:
	orl	%ebx, %r12d
	testl	%r14d, %r14d
	cmovnel	%r14d, %r12d
	leaq	L_.str(%rip), %rsi
	movq	%r15, %rdi
	movl	%r12d, %edx
	callq	_IWL_DEBUG_INFO
	movl	%r12d, %edi
	callq	_cpu_to_le32
	movl	%eax, -48(%rbp)
	movl	%r12d, %edi
	callq	_cpu_to_le16
	movl	%eax, -40(%rbp)
	movq	8(%r15), %rax
	movl	(%rax), %edi
	callq	_IWL_UCODE_API
	cmpl	$3, %eax
	movq	_REPLY_TXFIFO_FLUSH@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rax
	leaq	-40(%rbp), %r8
	cmovgeq	%rax, %r8
	movq	%r15, %rdi
	xorl	%edx, %edx
	movl	$8, %ecx
	callq	_iwl_dvm_send_cmd_pdu
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IWL_DROP_ALL,4,2               ## @IWL_DROP_ALL
	.comm	_IWL_SCD_VO_MSK,4,2             ## @IWL_SCD_VO_MSK
	.comm	_IWL_SCD_VI_MSK,4,2             ## @IWL_SCD_VI_MSK
	.comm	_IWL_SCD_BE_MSK,4,2             ## @IWL_SCD_BE_MSK
	.comm	_IWL_SCD_BK_MSK,4,2             ## @IWL_SCD_BK_MSK
	.comm	_IWL_SCD_MGMT_MSK,4,2           ## @IWL_SCD_MGMT_MSK
	.comm	_IWL_RXON_CTX_BSS,4,2           ## @IWL_RXON_CTX_BSS
	.comm	_IWL_PAN_SCD_VO_MSK,4,2         ## @IWL_PAN_SCD_VO_MSK
	.comm	_IWL_PAN_SCD_VI_MSK,4,2         ## @IWL_PAN_SCD_VI_MSK
	.comm	_IWL_PAN_SCD_BE_MSK,4,2         ## @IWL_PAN_SCD_BE_MSK
	.comm	_IWL_PAN_SCD_BK_MSK,4,2         ## @IWL_PAN_SCD_BK_MSK
	.comm	_IWL_PAN_SCD_MGMT_MSK,4,2       ## @IWL_PAN_SCD_MGMT_MSK
	.comm	_IWL_PAN_SCD_MULTICAST_MSK,4,2  ## @IWL_PAN_SCD_MULTICAST_MSK
	.comm	_IWL_AGG_TX_QUEUE_MSK,4,2       ## @IWL_AGG_TX_QUEUE_MSK
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"queue control: 0x%x\n"

	.comm	_REPLY_TXFIFO_FLUSH,4,2         ## @REPLY_TXFIFO_FLUSH
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_iwlagn_txfifo_flush            ; -- Begin function iwlagn_txfifo_flush
	.p2align	2
_iwlagn_txfifo_flush:                   ; @iwlagn_txfifo_flush
	.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	x20, x1
	mov	x19, x0
Lloh0:
	adrp	x21, _IWL_DROP_ALL@GOTPAGE
Lloh1:
	ldr	x21, [x21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	x9, [x9, _IWL_PAN_SCD_VI_MSK@GOTPAGEOFF]
Lloh25:
	ldr	w9, [x9]
Lloh26:
	adrp	x10, _IWL_PAN_SCD_BE_MSK@GOTPAGE
Lloh27:
	ldr	x10, [x10, _IWL_PAN_SCD_BE_MSK@GOTPAGEOFF]
Lloh28:
	ldr	w10, [x10]
Lloh29:
	adrp	x11, _IWL_PAN_SCD_BK_MSK@GOTPAGE
Lloh30:
	ldr	x11, [x11, _IWL_PAN_SCD_BK_MSK@GOTPAGEOFF]
Lloh31:
	ldr	w11, [x11]
Lloh32:
	adrp	x12, _IWL_PAN_SCD_MGMT_MSK@GOTPAGE
Lloh33:
	ldr	x12, [x12, _IWL_PAN_SCD_MGMT_MSK@GOTPAGEOFF]
Lloh34:
	ldr	w12, [x12]
Lloh35:
	adrp	x13, _IWL_PAN_SCD_MULTICAST_MSK@GOTPAGE
Lloh36:
	ldr	x13, [x13, _IWL_PAN_SCD_MULTICAST_MSK@GOTPAGEOFF]
Lloh37:
	ldr	w13, [x13]
	orr	w8, w8, w21
	orr	w8, w8, w9
	orr	w8, w8, w10
	orr	w8, w8, w11
	orr	w8, w8, w12
	orr	w21, w8, w13
LBB0_2:
	ldr	x8, [x19, #16]
	ldr	x8, [x8]
Lloh38:
	adrp	x9, _IWL_AGG_TX_QUEUE_MSK@GOTPAGE
Lloh39:
	ldr	x9, [x9, _IWL_AGG_TX_QUEUE_MSK@GOTPAGEOFF]
Lloh40:
	ldr	w9, [x9]
	cmp	x8, #0
	csel	w8, wzr, w9, eq
	orr	w8, w8, w21
	cmp	w20, #0
	csel	w20, w8, w20, eq
Lloh41:
	adrp	x1, l_.str@PAGE
Lloh42:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	bl	_IWL_DEBUG_INFO
	mov	x0, x20
	bl	_cpu_to_le32
	str	w0, [sp, #8]
	mov	x0, x20
	bl	_cpu_to_le16
	str	w0, [sp]
	ldr	x8, [x19, #8]
	ldr	w0, [x8]
	bl	_IWL_UCODE_API
Lloh43:
	adrp	x8, _REPLY_TXFIFO_FLUSH@GOTPAGE
Lloh44:
	ldr	x8, [x8, _REPLY_TXFIFO_FLUSH@GOTPAGEOFF]
Lloh45:
	ldr	w1, [x8]
	cmp	w0, #2
	mov	x8, sp
	add	x9, sp, #8
	csel	x4, x9, x8, gt
	mov	x0, x19
	mov	w2, #0
	mov	w3, #8
	bl	_iwl_dvm_send_cmd_pdu
	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	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh43, Lloh44, Lloh45
	.loh AdrpAdd	Lloh41, Lloh42
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.cfi_endproc
                                        ; -- End function
	.comm	_IWL_DROP_ALL,4,2               ; @IWL_DROP_ALL
	.comm	_IWL_SCD_VO_MSK,4,2             ; @IWL_SCD_VO_MSK
	.comm	_IWL_SCD_VI_MSK,4,2             ; @IWL_SCD_VI_MSK
	.comm	_IWL_SCD_BE_MSK,4,2             ; @IWL_SCD_BE_MSK
	.comm	_IWL_SCD_BK_MSK,4,2             ; @IWL_SCD_BK_MSK
	.comm	_IWL_SCD_MGMT_MSK,4,2           ; @IWL_SCD_MGMT_MSK
	.comm	_IWL_RXON_CTX_BSS,4,2           ; @IWL_RXON_CTX_BSS
	.comm	_IWL_PAN_SCD_VO_MSK,4,2         ; @IWL_PAN_SCD_VO_MSK
	.comm	_IWL_PAN_SCD_VI_MSK,4,2         ; @IWL_PAN_SCD_VI_MSK
	.comm	_IWL_PAN_SCD_BE_MSK,4,2         ; @IWL_PAN_SCD_BE_MSK
	.comm	_IWL_PAN_SCD_BK_MSK,4,2         ; @IWL_PAN_SCD_BK_MSK
	.comm	_IWL_PAN_SCD_MGMT_MSK,4,2       ; @IWL_PAN_SCD_MGMT_MSK
	.comm	_IWL_PAN_SCD_MULTICAST_MSK,4,2  ; @IWL_PAN_SCD_MULTICAST_MSK
	.comm	_IWL_AGG_TX_QUEUE_MSK,4,2       ; @IWL_AGG_TX_QUEUE_MSK
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"queue control: 0x%x\n"

	.comm	_REPLY_TXFIFO_FLUSH,4,2         ; @REPLY_TXFIFO_FLUSH
.subsections_via_symbols
