	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rt2x00mac_tx                   ## -- Begin function rt2x00mac_tx
	.p2align	4, 0x90
_rt2x00mac_tx:                          ## @rt2x00mac_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	%rdx, %r12
	movq	%rsi, -48(%rbp)                 ## 8-byte Spill
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %rbx
	movq	%rdx, %rdi
	callq	_IEEE80211_SKB_CB
	movq	%rax, %r13
	movq	%r12, %rdi
	callq	_skb_get_queue_mapping
	movl	%eax, %r14d
	movq	_DEVICE_STATE_PRESENT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	8(%rbx), %rsi
	callq	_test_bit
	testl	%eax, %eax
	je	LBB0_6
## %bb.1:
	movq	_IEEE80211_TX_CTL_SEND_AFTER_DTIM@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%r13)
	je	LBB0_4
## %bb.2:
	movq	_REQUIRE_ATIM_QUEUE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_rt2x00_has_cap_flag
	testq	%rax, %rax
	je	LBB0_4
## %bb.3:
	movq	_QID_ATIM@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
LBB0_4:
	movq	%rbx, %rdi
	movl	%r14d, %esi
	callq	_rt2x00queue_get_tx_queue
	movq	%rax, %r15
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_7
## %bb.5:
	movq	_DRV_PROJECT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	movl	%r14d, %edx
	callq	_rt2x00_err
	jmp	LBB0_6
LBB0_7:
	movq	(%rbx), %rax
	movq	(%rax), %rax
	cmpl	$0, (%rax)
	je	LBB0_8
LBB0_14:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edx
	movq	%r15, %rdi
	movq	%r12, %rsi
	xorl	%ecx, %ecx
	callq	_rt2x00queue_write_tx_frame
	movl	%eax, %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_15
LBB0_6:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movq	%r12, %rsi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ieee80211_free_txskb           ## TAILCALL
LBB0_8:
	movq	8(%r13), %rax
	movq	_IEEE80211_TX_RC_USE_RTS_CTS@GOTPCREL(%rip), %rcx
	movq	_IEEE80211_TX_RC_USE_CTS_PROTECT@GOTPCREL(%rip), %rdx
	movl	(%rdx), %edx
	orl	(%rcx), %edx
	testl	%edx, (%rax)
	je	LBB0_14
## %bb.9:
	movq	%r15, %rdi
	callq	_rt2x00queue_available
	cmpl	$1, %eax
	jg	LBB0_13
## %bb.10:
	movq	%r15, %rdi
	callq	_spin_lock
	movq	%r15, %rdi
	callq	_rt2x00queue_threshold
	testq	%rax, %rax
	je	LBB0_12
## %bb.11:
	movq	%r15, %rdi
	callq	_rt2x00queue_pause_queue
LBB0_12:
	movq	%r15, %rdi
	callq	_spin_unlock
	jmp	LBB0_6
LBB0_15:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_13:
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movq	%r12, %rdx
	callq	_rt2x00mac_tx_rts_cts
	testq	%rax, %rax
	jne	LBB0_6
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_DEVICE_STATE_PRESENT,4,2       ## @DEVICE_STATE_PRESENT
	.comm	_IEEE80211_TX_CTL_SEND_AFTER_DTIM,4,2 ## @IEEE80211_TX_CTL_SEND_AFTER_DTIM
	.comm	_REQUIRE_ATIM_QUEUE,4,2         ## @REQUIRE_ATIM_QUEUE
	.comm	_QID_ATIM,4,2                   ## @QID_ATIM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Attempt to send packet over invalid queue %d\nPlease file bug report to %s\n"

	.comm	_DRV_PROJECT,4,2                ## @DRV_PROJECT
	.comm	_IEEE80211_TX_RC_USE_RTS_CTS,4,2 ## @IEEE80211_TX_RC_USE_RTS_CTS
	.comm	_IEEE80211_TX_RC_USE_CTS_PROTECT,4,2 ## @IEEE80211_TX_RC_USE_CTS_PROTECT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rt2x00mac_tx                   ; -- Begin function rt2x00mac_tx
	.p2align	2
_rt2x00mac_tx:                          ; @rt2x00mac_tx
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x2
	mov	x21, x1
	mov	x20, x0
	ldr	x22, [x0]
	mov	x0, x2
	bl	_IEEE80211_SKB_CB
	mov	x24, x0
	mov	x0, x19
	bl	_skb_get_queue_mapping
	mov	x25, x0
Lloh0:
	adrp	x8, _DEVICE_STATE_PRESENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _DEVICE_STATE_PRESENT@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	add	x1, x22, #8
	bl	_test_bit
	cbz	w0, LBB0_7
; %bb.1:
	ldr	w8, [x24]
Lloh3:
	adrp	x9, _IEEE80211_TX_CTL_SEND_AFTER_DTIM@GOTPAGE
Lloh4:
	ldr	x9, [x9, _IEEE80211_TX_CTL_SEND_AFTER_DTIM@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_3
; %bb.2:
Lloh6:
	adrp	x8, _REQUIRE_ATIM_QUEUE@GOTPAGE
Lloh7:
	ldr	x8, [x8, _REQUIRE_ATIM_QUEUE@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x22
	bl	_rt2x00_has_cap_flag
Lloh9:
	adrp	x8, _QID_ATIM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _QID_ATIM@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	cmp	x0, #0
	csel	w25, w25, w8, eq
LBB0_3:
	mov	x0, x22
	mov	x1, x25
	bl	_rt2x00queue_get_tx_queue
	mov	x23, x0
	cmp	x0, #0
	cset	w0, eq
	bl	_unlikely
	cbz	x0, LBB0_5
; %bb.4:
Lloh12:
	adrp	x8, _DRV_PROJECT@GOTPAGE
Lloh13:
	ldr	x8, [x8, _DRV_PROJECT@GOTPAGEOFF]
Lloh14:
	ldr	w3, [x8]
Lloh15:
	adrp	x1, l_.str@PAGE
Lloh16:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x22
	mov	x2, x25
	bl	_rt2x00_err
	b	LBB0_7
LBB0_5:
	ldr	x8, [x22]
	ldr	x8, [x8]
	ldr	w8, [x8]
	cbz	w8, LBB0_8
LBB0_6:
	ldr	w2, [x21]
	mov	x0, x23
	mov	x1, x19
	mov	w3, #0
	bl	_rt2x00queue_write_tx_frame
	bl	_unlikely
	cbz	x0, LBB0_13
LBB0_7:
	mov	x0, x20
	mov	x1, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_ieee80211_free_txskb
LBB0_8:
	ldr	x8, [x24, #8]
	ldr	w8, [x8]
Lloh17:
	adrp	x9, _IEEE80211_TX_RC_USE_RTS_CTS@GOTPAGE
Lloh18:
	ldr	x9, [x9, _IEEE80211_TX_RC_USE_RTS_CTS@GOTPAGEOFF]
Lloh19:
	ldr	w9, [x9]
Lloh20:
	adrp	x10, _IEEE80211_TX_RC_USE_CTS_PROTECT@GOTPAGE
Lloh21:
	ldr	x10, [x10, _IEEE80211_TX_RC_USE_CTS_PROTECT@GOTPAGEOFF]
Lloh22:
	ldr	w10, [x10]
	orr	w9, w10, w9
	tst	w9, w8
	b.eq	LBB0_6
; %bb.9:
	mov	x0, x23
	bl	_rt2x00queue_available
	cmp	w0, #1
	b.gt	LBB0_14
; %bb.10:
	mov	x0, x23
	bl	_spin_lock
	mov	x0, x23
	bl	_rt2x00queue_threshold
	cbz	x0, LBB0_12
; %bb.11:
	mov	x0, x23
	bl	_rt2x00queue_pause_queue
LBB0_12:
	mov	x0, x23
	bl	_spin_unlock
	b	LBB0_7
LBB0_13:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_14:
	mov	x0, x22
	mov	x1, x23
	mov	x2, x19
	bl	_rt2x00mac_tx_rts_cts
	cbnz	x0, LBB0_7
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_DEVICE_STATE_PRESENT,4,2       ; @DEVICE_STATE_PRESENT
	.comm	_IEEE80211_TX_CTL_SEND_AFTER_DTIM,4,2 ; @IEEE80211_TX_CTL_SEND_AFTER_DTIM
	.comm	_REQUIRE_ATIM_QUEUE,4,2         ; @REQUIRE_ATIM_QUEUE
	.comm	_QID_ATIM,4,2                   ; @QID_ATIM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Attempt to send packet over invalid queue %d\nPlease file bug report to %s\n"

	.comm	_DRV_PROJECT,4,2                ; @DRV_PROJECT
	.comm	_IEEE80211_TX_RC_USE_RTS_CTS,4,2 ; @IEEE80211_TX_RC_USE_RTS_CTS
	.comm	_IEEE80211_TX_RC_USE_CTS_PROTECT,4,2 ; @IEEE80211_TX_RC_USE_CTS_PROTECT
.subsections_via_symbols
