	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rt2x00queue_write_tx_frame     ## -- Begin function rt2x00queue_write_tx_frame
	.p2align	4, 0x90
_rt2x00queue_write_tx_frame:            ## @rt2x00queue_write_tx_frame
	.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
	movl	%ecx, %r15d
	movq	%rdx, %rcx
	movq	%rsi, %r14
	movq	%rdi, %r12
	movl	8(%rdi), %edi
	leaq	-48(%rbp), %rdx
	callq	_rt2x00queue_create_tx_descriptor
	movq	%r14, %rdi
	callq	_IEEE80211_SKB_CB
	movq	(%rax), %rax
	movups	(%rax), %xmm0
	movaps	%xmm0, -64(%rbp)                ## 16-byte Spill
	movq	%r14, %rdi
	callq	_get_skb_frame_desc
	movq	%rax, %rbx
	movq	%rax, %rdi
	xorl	%esi, %esi
	movl	$24, %edx
	callq	_memset
	movaps	-64(%rbp), %xmm0                ## 16-byte Reload
	movups	%xmm0, 8(%rbx)
	testl	%r15d, %r15d
	je	LBB0_2
## %bb.1:
	movq	_SKBDESC_NOT_MAC80211@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	orl	%eax, (%rbx)
LBB0_2:
	movq	_ENTRY_TXD_ENCRYPT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	-44(%rbp), %rbx
	movq	%rbx, %rsi
	callq	_test_bit
	testq	%rax, %rax
	je	LBB0_7
## %bb.3:
	movq	_ENTRY_TXD_ENCRYPT_IV@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%rbx, %rsi
	callq	_test_bit
	testq	%rax, %rax
	jne	LBB0_7
## %bb.4:
	movl	8(%r12), %edi
	movq	_REQUIRE_COPY_IV@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_rt2x00_has_cap_flag
	leaq	-48(%rbp), %rsi
	movq	%r14, %rdi
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	callq	_rt2x00crypto_tx_copy_iv
	jmp	LBB0_7
LBB0_6:
	callq	_rt2x00crypto_tx_remove_iv
LBB0_7:
	movl	8(%r12), %edi
	movq	_REQUIRE_L2PAD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_rt2x00_has_cap_flag
	testq	%rax, %rax
	je	LBB0_9
## %bb.8:
	movl	-48(%rbp), %esi
	movq	%r14, %rdi
	callq	_rt2x00queue_insert_l2pad
	jmp	LBB0_11
LBB0_9:
	movl	8(%r12), %edi
	movq	_REQUIRE_DMA@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_rt2x00_has_cap_flag
	testq	%rax, %rax
	je	LBB0_11
## %bb.10:
	movq	%r14, %rdi
	callq	_rt2x00queue_align_frame
LBB0_11:
	movq	%r12, %rdi
	callq	_spin_lock
	movq	%r12, %rdi
	callq	_rt2x00queue_full
	movl	%eax, %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_14
## %bb.12:
	movl	4(%r12), %edx
	movl	8(%r12), %edi
	leaq	L_.str(%rip), %rsi
	callq	_rt2x00_dbg
	movq	_ENOBUFS@GOTPCREL(%rip), %rax
	jmp	LBB0_13
LBB0_14:
	movq	_Q_INDEX@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	%r12, %rdi
	callq	_rt2x00queue_get_entry
	movq	%rax, %r15
	movq	_ENTRY_OWNER_DEVICE_DATA@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edi
	movq	%rax, %rsi
	callq	_test_and_set_bit
	movl	%eax, %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_16
## %bb.15:
	movl	4(%r12), %edx
	movl	8(%r12), %edi
	movq	_DRV_PROJECT@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	leaq	L_.str.1(%rip), %rsi
	callq	_rt2x00_err
	movq	_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_13
LBB0_16:
	movq	%r14, 8(%r15)
	leaq	-48(%rbp), %rsi
	movq	%r15, %rdi
	callq	_rt2x00queue_write_tx_data
	movl	%eax, %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_18
## %bb.17:
	movl	(%rbx), %edi
	movq	%r15, %rsi
	callq	_clear_bit
	movq	$0, 8(%r15)
	movq	_EIO@GOTPCREL(%rip), %rax
LBB0_13:
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_19:
	movq	%r12, %rdi
	callq	_rt2x00queue_threshold
	testq	%rax, %rax
	je	LBB0_21
## %bb.20:
	movq	%r12, %rdi
	callq	_rt2x00queue_pause_queue
LBB0_21:
	movq	%r12, %rdi
	callq	_spin_unlock
	movl	%ebx, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movq	%r15, %rdi
	callq	_rt2x00queue_bar_check
	movq	_ENTRY_DATA_PENDING@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r15, %rsi
	callq	_set_bit
	movl	(%r13), %esi
	movq	%r15, %rdi
	callq	_rt2x00queue_index_inc
	leaq	-48(%rbp), %rbx
	movq	%r15, %rdi
	movq	%rbx, %rsi
	callq	_rt2x00queue_write_tx_descriptor
	movq	%r12, %rdi
	movq	%rbx, %rsi
	callq	_rt2x00queue_kick_tx_queue
	xorl	%ebx, %ebx
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_SKBDESC_NOT_MAC80211,4,2       ## @SKBDESC_NOT_MAC80211
	.comm	_ENTRY_TXD_ENCRYPT,4,2          ## @ENTRY_TXD_ENCRYPT
	.comm	_ENTRY_TXD_ENCRYPT_IV,4,2       ## @ENTRY_TXD_ENCRYPT_IV
	.comm	_REQUIRE_COPY_IV,4,2            ## @REQUIRE_COPY_IV
	.comm	_REQUIRE_L2PAD,4,2              ## @REQUIRE_L2PAD
	.comm	_REQUIRE_DMA,4,2                ## @REQUIRE_DMA
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Dropping frame due to full tx queue %d\n"

	.comm	_ENOBUFS,4,2                    ## @ENOBUFS
	.comm	_Q_INDEX,4,2                    ## @Q_INDEX
	.comm	_ENTRY_OWNER_DEVICE_DATA,4,2    ## @ENTRY_OWNER_DEVICE_DATA
L_.str.1:                               ## @.str.1
	.asciz	"Arrived at non-free entry in the non-full queue %d\nPlease file bug report to %s\n"

	.comm	_DRV_PROJECT,4,2                ## @DRV_PROJECT
	.comm	_EINVAL,4,2                     ## @EINVAL
	.comm	_EIO,4,2                        ## @EIO
	.comm	_ENTRY_DATA_PENDING,4,2         ## @ENTRY_DATA_PENDING
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_rt2x00queue_write_tx_frame     ; -- Begin function rt2x00queue_write_tx_frame
	.p2align	2
_rt2x00queue_write_tx_frame:            ; @rt2x00queue_write_tx_frame
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x22, x3
	mov	x3, x2
	mov	x20, x1
	mov	x19, x0
	ldr	w0, [x0, #8]
	add	x23, sp, #8
	add	x2, sp, #8
	bl	_rt2x00queue_create_tx_descriptor
	mov	x0, x20
	bl	_IEEE80211_SKB_CB
	ldr	x8, [x0]
	ldp	x25, x24, [x8]
	mov	x0, x20
	bl	_get_skb_frame_desc
	mov	x21, x0
	mov	w1, #0
	mov	w2, #24
	bl	_memset
	stp	x25, x24, [x21, #8]
	cbz	w22, LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _SKBDESC_NOT_MAC80211@GOTPAGE
Lloh1:
	ldr	x8, [x8, _SKBDESC_NOT_MAC80211@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	w9, [x21]
	orr	w8, w9, w8
	str	w8, [x21]
LBB0_2:
Lloh3:
	adrp	x8, _ENTRY_TXD_ENCRYPT@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENTRY_TXD_ENCRYPT@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	orr	x21, x23, #0x4
	mov	x1, x21
	bl	_test_bit
	cbz	x0, LBB0_7
; %bb.3:
Lloh6:
	adrp	x8, _ENTRY_TXD_ENCRYPT_IV@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENTRY_TXD_ENCRYPT_IV@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	mov	x1, x21
	bl	_test_bit
	cbnz	x0, LBB0_7
; %bb.4:
	ldr	w0, [x19, #8]
Lloh9:
	adrp	x8, _REQUIRE_COPY_IV@GOTPAGE
Lloh10:
	ldr	x8, [x8, _REQUIRE_COPY_IV@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
	bl	_rt2x00_has_cap_flag
	add	x1, sp, #8
	cbz	x0, LBB0_6
; %bb.5:
	mov	x0, x20
	bl	_rt2x00crypto_tx_copy_iv
	b	LBB0_7
LBB0_6:
	mov	x0, x20
	bl	_rt2x00crypto_tx_remove_iv
LBB0_7:
	ldr	w0, [x19, #8]
Lloh12:
	adrp	x8, _REQUIRE_L2PAD@GOTPAGE
Lloh13:
	ldr	x8, [x8, _REQUIRE_L2PAD@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
	bl	_rt2x00_has_cap_flag
	cbz	x0, LBB0_9
; %bb.8:
	ldr	w1, [sp, #8]
	mov	x0, x20
	bl	_rt2x00queue_insert_l2pad
	b	LBB0_11
LBB0_9:
	ldr	w0, [x19, #8]
Lloh15:
	adrp	x8, _REQUIRE_DMA@GOTPAGE
Lloh16:
	ldr	x8, [x8, _REQUIRE_DMA@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	bl	_rt2x00_has_cap_flag
	cbz	x0, LBB0_11
; %bb.10:
	mov	x0, x20
	bl	_rt2x00queue_align_frame
LBB0_11:
	mov	x0, x19
	bl	_spin_lock
	mov	x0, x19
	bl	_rt2x00queue_full
	bl	_unlikely
	cbz	x0, LBB0_13
; %bb.12:
	ldp	w2, w0, [x19, #4]
Lloh18:
	adrp	x1, l_.str@PAGE
Lloh19:
	add	x1, x1, l_.str@PAGEOFF
	bl	_rt2x00_dbg
Lloh20:
	adrp	x8, _ENOBUFS@GOTPAGE
Lloh21:
	ldr	x8, [x8, _ENOBUFS@GOTPAGEOFF]
	b	LBB0_17
LBB0_13:
Lloh22:
	adrp	x22, _Q_INDEX@GOTPAGE
Lloh23:
	ldr	x22, [x22, _Q_INDEX@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x19
	bl	_rt2x00queue_get_entry
	mov	x21, x0
Lloh24:
	adrp	x23, _ENTRY_OWNER_DEVICE_DATA@GOTPAGE
Lloh25:
	ldr	x23, [x23, _ENTRY_OWNER_DEVICE_DATA@GOTPAGEOFF]
	ldr	w0, [x23]
	mov	x1, x21
	bl	_test_and_set_bit
	bl	_unlikely
	cbz	x0, LBB0_15
; %bb.14:
	ldp	w2, w0, [x19, #4]
Lloh26:
	adrp	x8, _DRV_PROJECT@GOTPAGE
Lloh27:
	ldr	x8, [x8, _DRV_PROJECT@GOTPAGEOFF]
Lloh28:
	ldr	w3, [x8]
Lloh29:
	adrp	x1, l_.str.1@PAGE
Lloh30:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_rt2x00_err
Lloh31:
	adrp	x8, _EINVAL@GOTPAGE
Lloh32:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_17
LBB0_15:
	str	x20, [x21, #8]
	add	x1, sp, #8
	mov	x0, x21
	bl	_rt2x00queue_write_tx_data
	bl	_unlikely
	cbz	x0, LBB0_21
; %bb.16:
	ldr	w0, [x23]
	mov	x1, x21
	bl	_clear_bit
	str	xzr, [x21, #8]
Lloh33:
	adrp	x8, _EIO@GOTPAGE
Lloh34:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
LBB0_17:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_18:
	mov	x0, x19
	bl	_rt2x00queue_threshold
	cbz	x0, LBB0_20
; %bb.19:
	mov	x0, x19
	bl	_rt2x00queue_pause_queue
LBB0_20:
	mov	x0, x19
	bl	_spin_unlock
	mov	x0, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
LBB0_21:
	mov	x0, x21
	bl	_rt2x00queue_bar_check
Lloh35:
	adrp	x8, _ENTRY_DATA_PENDING@GOTPAGE
Lloh36:
	ldr	x8, [x8, _ENTRY_DATA_PENDING@GOTPAGEOFF]
Lloh37:
	ldr	w0, [x8]
	mov	x1, x21
	bl	_set_bit
	ldr	w1, [x22]
	mov	x0, x21
	bl	_rt2x00queue_index_inc
	add	x1, sp, #8
	mov	x0, x21
	bl	_rt2x00queue_write_tx_descriptor
	add	x1, sp, #8
	mov	x0, x19
	bl	_rt2x00queue_kick_tx_queue
	mov	w20, #0
	b	LBB0_18
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.cfi_endproc
                                        ; -- End function
	.comm	_SKBDESC_NOT_MAC80211,4,2       ; @SKBDESC_NOT_MAC80211
	.comm	_ENTRY_TXD_ENCRYPT,4,2          ; @ENTRY_TXD_ENCRYPT
	.comm	_ENTRY_TXD_ENCRYPT_IV,4,2       ; @ENTRY_TXD_ENCRYPT_IV
	.comm	_REQUIRE_COPY_IV,4,2            ; @REQUIRE_COPY_IV
	.comm	_REQUIRE_L2PAD,4,2              ; @REQUIRE_L2PAD
	.comm	_REQUIRE_DMA,4,2                ; @REQUIRE_DMA
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Dropping frame due to full tx queue %d\n"

	.comm	_ENOBUFS,4,2                    ; @ENOBUFS
	.comm	_Q_INDEX,4,2                    ; @Q_INDEX
	.comm	_ENTRY_OWNER_DEVICE_DATA,4,2    ; @ENTRY_OWNER_DEVICE_DATA
l_.str.1:                               ; @.str.1
	.asciz	"Arrived at non-free entry in the non-full queue %d\nPlease file bug report to %s\n"

	.comm	_DRV_PROJECT,4,2                ; @DRV_PROJECT
	.comm	_EINVAL,4,2                     ; @EINVAL
	.comm	_EIO,4,2                        ; @EIO
	.comm	_ENTRY_DATA_PENDING,4,2         ; @ENTRY_DATA_PENDING
.subsections_via_symbols
