	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function il3945_hdl_tx
_il3945_hdl_tx:                         ## @il3945_hdl_tx
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r15
	movq	%rsi, %rdi
	callq	_rxb_addr
	movq	%rax, %r12
	movl	8(%rax), %edi
	callq	_le16_to_cpu
	movl	%eax, %ebx
	movl	%eax, %edi
	callq	_SEQ_TO_QUEUE
	movl	%ebx, %edi
	movl	%eax, %ebx
	callq	_SEQ_TO_IDX
	movl	%eax, %r14d
	movq	%r15, -56(%rbp)                 ## 8-byte Spill
	movq	8(%r15), %r15
	movslq	%ebx, %rax
	leaq	(%rax,%rax,4), %r13
	movq	(%r12), %r12
	movl	8(%r12), %edi
	callq	_le32_to_cpu
	movl	%r14d, %edx
	movl	(%r15,%r13,8), %ecx
	cmpl	%ecx, %r14d
	jge	LBB0_3
## %bb.1:
	movl	%eax, %r14d
	movl	%ebx, -48(%rbp)                 ## 4-byte Spill
	leaq	(%r15,%r13,8), %rbx
	movq	%rbx, %rdi
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movl	%edx, %esi
	callq	_il_queue_used
	testq	%rax, %rax
	je	LBB0_2
## %bb.4:
	movq	_TX_STATUS_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	andl	%r14d, %eax
	movq	_TX_STATUS_FAIL_PASSIVE_NO_RX@GOTPCREL(%rip), %rcx
	xorl	%edi, %edi
	cmpl	(%rcx), %eax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_7
## %bb.5:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	_NL80211_IFTYPE_STATION@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_7
## %bb.6:
	movq	_IL_STOP_REASON_PASSIVE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_il_stop_queues_by_reason
	leaq	L_.str.1(%rip), %rdi
	callq	_D_INFO
LBB0_7:
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 32(%r15,%r13,8)
	movq	8(%r15,%r13,8), %rax
	movq	24(%r15,%r13,8), %rcx
	movl	(%rcx,%rax,4), %edi
	callq	_IEEE80211_SKB_CB
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_ieee80211_tx_info_clear_status
	movl	4(%r12), %edi
	callq	_il3945_hwrate_to_plcp_idx
	movq	_NL80211_BAND_5GHZ@GOTPCREL(%rip), %r8
	movq	(%rbx), %rdi
	movq	16(%rbx), %rdx
	xorl	%ecx, %ecx
	movl	$0, %esi
	cmpq	(%r8), %rdi
	jne	LBB0_9
## %bb.8:
	movq	_IL_FIRST_OFDM_RATE@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
LBB0_9:
	subl	%esi, %eax
	movl	(%r12), %esi
	movl	%eax, (%rdx)
	incl	%esi
	movl	%esi, 4(%rdx)
	movq	_TX_STATUS_MSK@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%r14d, %r13d
	andl	%r14d, %eax
	movq	_TX_STATUS_SUCCESS@GOTPCREL(%rip), %rdx
	cmpl	(%rdx), %eax
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	jne	LBB0_11
## %bb.10:
	movq	_IEEE80211_TX_STAT_ACK@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
LBB0_11:
	orl	%ecx, 8(%rbx)
	movl	%r13d, %edi
	callq	_il3945_get_tx_fail_reason
	movl	(%r12), %r9d
	movl	4(%r12), %r8d
	leaq	L_.str.2(%rip), %rdi
	movl	-48(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %esi
	movl	%eax, %edx
	movl	%r13d, %ecx
	callq	_D_TX
	leaq	L_.str.3(%rip), %rdi
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	movl	%ebx, %esi
	callq	_D_TX_REPLY
	movq	%r14, %rdi
	movl	%r15d, %esi
	movl	%ebx, %edx
	callq	_il3945_tx_queue_reclaim
	movq	_TX_ABORT_REQUIRED_MSK@GOTPCREL(%rip), %rax
	testl	%r13d, (%rax)
	je	LBB0_12
## %bb.13:
	leaq	L_.str.4(%rip), %rdi
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_IL_ERR                         ## TAILCALL
LBB0_2:
	movl	(%rbx), %ecx
	movl	-48(%rbp), %ebx                 ## 4-byte Reload
	movl	-44(%rbp), %edx                 ## 4-byte Reload
LBB0_3:
	movl	16(%r15,%r13,8), %r8d
	movq	8(%r15,%r13,8), %r9
	leaq	L_.str(%rip), %rdi
	movl	%ebx, %esi
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_IL_ERR                         ## TAILCALL
LBB0_12:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Read idx for DMA queue txq_id (%d) idx %d is out of range [0-%d] %d %d\n"

	.comm	_TX_STATUS_MSK,4,2              ## @TX_STATUS_MSK
	.comm	_TX_STATUS_FAIL_PASSIVE_NO_RX,4,2 ## @TX_STATUS_FAIL_PASSIVE_NO_RX
	.comm	_NL80211_IFTYPE_STATION,8,3     ## @NL80211_IFTYPE_STATION
	.comm	_IL_STOP_REASON_PASSIVE,4,2     ## @IL_STOP_REASON_PASSIVE
L_.str.1:                               ## @.str.1
	.asciz	"Stopped queues - RX waiting on passive channel\n"

	.comm	_jiffies,4,2                    ## @jiffies
	.comm	_NL80211_BAND_5GHZ,8,3          ## @NL80211_BAND_5GHZ
	.comm	_IL_FIRST_OFDM_RATE,8,3         ## @IL_FIRST_OFDM_RATE
	.comm	_TX_STATUS_SUCCESS,4,2          ## @TX_STATUS_SUCCESS
	.comm	_IEEE80211_TX_STAT_ACK,4,2      ## @IEEE80211_TX_STAT_ACK
L_.str.2:                               ## @.str.2
	.asciz	"Tx queue %d Status %s (0x%08x) plcp rate %d retries %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"Tx queue reclaim %d\n"

	.comm	_TX_ABORT_REQUIRED_MSK,4,2      ## @TX_ABORT_REQUIRED_MSK
L_.str.4:                               ## @.str.4
	.asciz	"TODO:  Implement Tx ABORT REQUIRED!!!\n"

	.no_dead_strip	_il3945_hdl_tx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function il3945_hdl_tx
_il3945_hdl_tx:                         ; @il3945_hdl_tx
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	mov	x20, x0
	mov	x0, x1
	bl	_rxb_addr
	mov	x22, x0
	ldr	w0, [x0, #8]
	bl	_le16_to_cpu
	mov	x19, x0
	bl	_SEQ_TO_QUEUE
	mov	x23, x0
	mov	x0, x19
	bl	_SEQ_TO_IDX
	mov	x19, x0
	ldr	x25, [x20, #8]
	sxtw	x21, w23
	mov	w8, #40
	smaddl	x23, w23, w8, x25
	ldr	x24, [x22]
	ldr	w0, [x24, #8]
	bl	_le32_to_cpu
	ldr	w8, [x23]
	cmp	w19, w8
	b.ge	LBB0_8
; %bb.1:
	mov	x22, x0
	mov	x0, x23
	mov	x1, x19
	bl	_il_queue_used
	cbz	x0, LBB0_7
; %bb.2:
Lloh0:
	adrp	x26, _TX_STATUS_MSK@GOTPAGE
Lloh1:
	ldr	x26, [x26, _TX_STATUS_MSK@GOTPAGEOFF]
	ldr	w8, [x26]
	and	w8, w8, w22
Lloh2:
	adrp	x9, _TX_STATUS_FAIL_PASSIVE_NO_RX@GOTPAGE
Lloh3:
	ldr	x9, [x9, _TX_STATUS_FAIL_PASSIVE_NO_RX@GOTPAGEOFF]
Lloh4:
	ldr	w9, [x9]
	cmp	w8, w9
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_5
; %bb.3:
	ldr	x8, [x20]
Lloh5:
	adrp	x9, _NL80211_IFTYPE_STATION@GOTPAGE
Lloh6:
	ldr	x9, [x9, _NL80211_IFTYPE_STATION@GOTPAGEOFF]
Lloh7:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.4:
Lloh8:
	adrp	x8, _IL_STOP_REASON_PASSIVE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _IL_STOP_REASON_PASSIVE@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x8]
	mov	x0, x20
	bl	_il_stop_queues_by_reason
Lloh11:
	adrp	x0, l_.str.1@PAGE
Lloh12:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_D_INFO
LBB0_5:
Lloh13:
	adrp	x8, _jiffies@GOTPAGE
Lloh14:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	mov	w9, #40
	madd	x9, x21, x9, x25
	str	w8, [x9, #32]
	ldr	x8, [x9, #24]
	ldr	x9, [x9, #8]
	ldr	w0, [x8, x9, lsl #2]
	bl	_IEEE80211_SKB_CB
	mov	x23, x0
	bl	_ieee80211_tx_info_clear_status
	ldr	w0, [x24, #4]
	bl	_il3945_hwrate_to_plcp_idx
	ldr	x8, [x23]
Lloh16:
	adrp	x9, _NL80211_BAND_5GHZ@GOTPAGE
Lloh17:
	ldr	x9, [x9, _NL80211_BAND_5GHZ@GOTPAGEOFF]
Lloh18:
	ldr	x9, [x9]
Lloh19:
	adrp	x10, _IL_FIRST_OFDM_RATE@GOTPAGE
Lloh20:
	ldr	x10, [x10, _IL_FIRST_OFDM_RATE@GOTPAGEOFF]
Lloh21:
	ldr	w10, [x10]
	cmp	x8, x9
	csel	w8, w10, wzr, eq
	sub	w8, w0, w8
	ldr	w9, [x24]
	ldr	x10, [x23, #16]
	add	w9, w9, #1
	stp	w8, w9, [x10]
	ldr	w8, [x26]
	and	w8, w8, w22
Lloh22:
	adrp	x9, _TX_STATUS_SUCCESS@GOTPAGE
Lloh23:
	ldr	x9, [x9, _TX_STATUS_SUCCESS@GOTPAGEOFF]
Lloh24:
	ldr	w9, [x9]
Lloh25:
	adrp	x10, _IEEE80211_TX_STAT_ACK@GOTPAGE
Lloh26:
	ldr	x10, [x10, _IEEE80211_TX_STAT_ACK@GOTPAGEOFF]
Lloh27:
	ldr	w10, [x10]
	cmp	w8, w9
	csel	w8, w10, wzr, eq
	ldr	w9, [x23, #8]
	orr	w8, w9, w8
	str	w8, [x23, #8]
	mov	x0, x22
	bl	_il3945_get_tx_fail_reason
	mov	x2, x0
	ldp	w5, w4, [x24]
Lloh28:
	adrp	x0, l_.str.2@PAGE
Lloh29:
	add	x0, x0, l_.str.2@PAGEOFF
	mov	x1, x21
	mov	x3, x22
	bl	_D_TX
Lloh30:
	adrp	x0, l_.str.3@PAGE
Lloh31:
	add	x0, x0, l_.str.3@PAGEOFF
	mov	x1, x19
	bl	_D_TX_REPLY
	mov	x0, x20
	mov	x1, x21
	mov	x2, x19
	bl	_il3945_tx_queue_reclaim
Lloh32:
	adrp	x8, _TX_ABORT_REQUIRED_MSK@GOTPAGE
Lloh33:
	ldr	x8, [x8, _TX_ABORT_REQUIRED_MSK@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	tst	w8, w22
	b.eq	LBB0_9
; %bb.6:
Lloh35:
	adrp	x0, l_.str.4@PAGE
Lloh36:
	add	x0, x0, l_.str.4@PAGEOFF
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	b	_IL_ERR
LBB0_7:
	ldr	w8, [x23]
LBB0_8:
	mov	w9, #40
	madd	x9, x21, x9, x25
	ldr	x10, [x9, #8]
	ldr	w9, [x9, #16]
	stp	x9, x10, [sp, #24]
	stp	x19, x8, [sp, #8]
	str	x21, [sp]
Lloh37:
	adrp	x0, l_.str@PAGE
Lloh38:
	add	x0, x0, l_.str@PAGEOFF
	bl	_IL_ERR
LBB0_9:
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh30, Lloh31
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpAdd	Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Read idx for DMA queue txq_id (%d) idx %d is out of range [0-%d] %d %d\n"

	.comm	_TX_STATUS_MSK,4,2              ; @TX_STATUS_MSK
	.comm	_TX_STATUS_FAIL_PASSIVE_NO_RX,4,2 ; @TX_STATUS_FAIL_PASSIVE_NO_RX
	.comm	_NL80211_IFTYPE_STATION,8,3     ; @NL80211_IFTYPE_STATION
	.comm	_IL_STOP_REASON_PASSIVE,4,2     ; @IL_STOP_REASON_PASSIVE
l_.str.1:                               ; @.str.1
	.asciz	"Stopped queues - RX waiting on passive channel\n"

	.comm	_jiffies,4,2                    ; @jiffies
	.comm	_NL80211_BAND_5GHZ,8,3          ; @NL80211_BAND_5GHZ
	.comm	_IL_FIRST_OFDM_RATE,8,3         ; @IL_FIRST_OFDM_RATE
	.comm	_TX_STATUS_SUCCESS,4,2          ; @TX_STATUS_SUCCESS
	.comm	_IEEE80211_TX_STAT_ACK,4,2      ; @IEEE80211_TX_STAT_ACK
l_.str.2:                               ; @.str.2
	.asciz	"Tx queue %d Status %s (0x%08x) plcp rate %d retries %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"Tx queue reclaim %d\n"

	.comm	_TX_ABORT_REQUIRED_MSK,4,2      ; @TX_ABORT_REQUIRED_MSK
l_.str.4:                               ; @.str.4
	.asciz	"TODO:  Implement Tx ABORT REQUIRED!!!\n"

	.no_dead_strip	_il3945_hdl_tx
.subsections_via_symbols
