	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function adm8211_tx_raw
_adm8211_tx_raw:                        ## @adm8211_tx_raw
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	movl	%edx, %r12d
	movq	%rsi, %rbx
	movq	%rdi, %r15
	movq	(%rdi), %r14
	movl	32(%r14), %edi
	movl	(%rsi), %edx
	movl	4(%rsi), %esi
	movq	_PCI_DMA_TODEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	callq	_pci_map_single
	movl	%eax, %r13d
	movl	32(%r14), %edi
	movl	%eax, %esi
	callq	_pci_dma_mapping_error
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%r15d, %r15d
	subl	(%rax), %r15d
	jmp	LBB0_9
LBB0_2:
	movq	%r15, -48(%rbp)                 ## 8-byte Spill
	movl	%r13d, -52(%rbp)                ## 4-byte Spill
	movl	%r12d, -56(%rbp)                ## 4-byte Spill
	leaq	12(%r14), %rdi
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	callq	_spin_lock_irqsave
	movl	(%r14), %eax
	movl	%eax, %edx
	subl	4(%r14), %edx
	movl	8(%r14), %ecx
	movl	%ecx, %esi
	shrl	$31, %esi
	addl	%ecx, %esi
	sarl	%esi
	xorl	%r12d, %r12d
	movq	_TDES1_CONTROL_FS@GOTPCREL(%rip), %r8
	movq	_TDES1_CONTROL_LS@GOTPCREL(%rip), %rdi
	cmpl	%esi, %edx
	jne	LBB0_4
## %bb.3:
	movq	_TDES1_CONTROL_IC@GOTPCREL(%rip), %rsi
	movl	(%rsi), %r12d
LBB0_4:
	orl	(%rdi), %r12d
	orl	(%r8), %r12d
	leal	-2(%rcx), %esi
	cmpl	%esi, %edx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	jne	LBB0_6
## %bb.5:
	xorl	%esi, %esi
	callq	_ieee80211_stop_queue
	movl	(%r14), %eax
	movl	8(%r14), %ecx
LBB0_6:
	xorl	%r15d, %r15d
	xorl	%edx, %edx
	divl	%ecx
                                        ## kill: def $edx killed $edx def $rdx
	movq	%rdx, -48(%rbp)                 ## 8-byte Spill
	movq	24(%r14), %rax
	leaq	(,%rdx,8), %rcx
	leaq	(%rcx,%rcx,2), %r13
	movq	%rbx, 16(%rax,%r13)
	movl	-52(%rbp), %edi                 ## 4-byte Reload
	movl	%edi, (%rax,%r13)
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, 8(%rax,%r13)
	callq	_cpu_to_le32
	movq	16(%r14), %rcx
	movq	%rax, 16(%rcx,%r13)
	movl	8(%r14), %ecx
	decl	%ecx
	movl	$0, %eax
	cmpl	%ecx, -48(%rbp)                 ## 4-byte Folded Reload
	jne	LBB0_8
## %bb.7:
	movq	_TDES1_CONTROL_TER@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_8:
	orl	(%rbx), %r12d
	orl	%eax, %r12d
	movl	%r12d, %edi
	callq	_cpu_to_le32
	movq	16(%r14), %rcx
	movq	%rax, 8(%rcx,%r13)
	movq	_TDES0_CONTROL_OWN@GOTPCREL(%rip), %rax
	movl	-56(%rbp), %edi                 ## 4-byte Reload
	shll	$20, %edi
	orl	(%rax), %edi
	orl	$8, %edi
	callq	_cpu_to_le32
	movq	16(%r14), %rcx
	movq	%rax, (%rcx,%r13)
	incl	(%r14)
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_spin_unlock_irqrestore
	movq	_TDR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	callq	_ADM8211_CSR_WRITE
LBB0_9:
	movl	%r15d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PCI_DMA_TODEVICE,4,2           ## @PCI_DMA_TODEVICE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_TDES1_CONTROL_IC,4,2           ## @TDES1_CONTROL_IC
	.comm	_TDES1_CONTROL_LS,4,2           ## @TDES1_CONTROL_LS
	.comm	_TDES1_CONTROL_FS,4,2           ## @TDES1_CONTROL_FS
	.comm	_TDES1_CONTROL_TER,4,2          ## @TDES1_CONTROL_TER
	.comm	_TDES0_CONTROL_OWN,4,2          ## @TDES0_CONTROL_OWN
	.comm	_TDR,4,2                        ## @TDR
	.no_dead_strip	_adm8211_tx_raw
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function adm8211_tx_raw
_adm8211_tx_raw:                        ; @adm8211_tx_raw
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x22, x3
	mov	x19, x2
	mov	x20, x1
	mov	x24, x0
	ldr	x25, [x0]
	ldr	w0, [x25, #32]
	ldr	w1, [x1, #4]
	ldr	w2, [x20]
Lloh0:
	adrp	x8, _PCI_DMA_TODEVICE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PCI_DMA_TODEVICE@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	bl	_pci_map_single
	mov	x23, x0
	ldr	w0, [x25, #32]
	mov	x1, x23
	bl	_pci_dma_mapping_error
	cbz	x0, LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_5
LBB0_2:
	add	x21, x25, #12
	mov	x0, x21
	bl	_spin_lock_irqsave
	ldp	w8, w10, [x25]
	ldr	w9, [x25, #8]
	cmp	w9, #0
	cinc	w11, w9, lt
Lloh6:
	adrp	x12, _TDES1_CONTROL_FS@GOTPAGE
Lloh7:
	ldr	x12, [x12, _TDES1_CONTROL_FS@GOTPAGEOFF]
Lloh8:
	adrp	x13, _TDES1_CONTROL_IC@GOTPAGE
Lloh9:
	ldr	x13, [x13, _TDES1_CONTROL_IC@GOTPAGEOFF]
Lloh10:
	ldr	w12, [x12]
	sub	w14, w9, #2
	sub	w10, w8, w10
	cmp	w10, w11, asr #1
Lloh11:
	adrp	x11, _TDES1_CONTROL_LS@GOTPAGE
Lloh12:
	ldr	x11, [x11, _TDES1_CONTROL_LS@GOTPAGEOFF]
Lloh13:
	ldr	w13, [x13]
Lloh14:
	ldr	w11, [x11]
	csel	w13, w13, wzr, eq
	orr	w11, w11, w13
	orr	w26, w12, w11
	cmp	w10, w14
	b.ne	LBB0_4
; %bb.3:
	mov	x0, x24
	mov	w1, #0
	bl	_ieee80211_stop_queue
	ldr	w8, [x25]
	ldr	w9, [x25, #8]
LBB0_4:
	udiv	w10, w8, w9
	msub	w24, w10, w9, w8
	ldr	x8, [x25, #24]
	mov	w27, #24
	umaddl	x8, w24, w27, x8
	str	w23, [x8]
	umull	x28, w24, w27
	stp	x22, x20, [x8, #8]
	mov	x0, x23
	bl	_cpu_to_le32
	ldr	x8, [x25, #16]
	umaddl	x8, w24, w27, x8
	str	x0, [x8, #16]
	ldr	w8, [x25, #8]
	sub	w8, w8, #1
Lloh15:
	adrp	x9, _TDES1_CONTROL_TER@GOTPAGE
Lloh16:
	ldr	x9, [x9, _TDES1_CONTROL_TER@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	cmp	w24, w8
	csel	w8, w9, wzr, eq
	ldr	w9, [x20]
	orr	w9, w9, w26
	orr	w0, w9, w8
	bl	_cpu_to_le32
	ldr	x8, [x25, #16]
	umaddl	x8, w24, w27, x8
	str	x0, [x8, #8]
Lloh18:
	adrp	x8, _TDES0_CONTROL_OWN@GOTPAGE
Lloh19:
	ldr	x8, [x8, _TDES0_CONTROL_OWN@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	orr	w8, w8, w19, lsl #20
	orr	w0, w8, #0x8
	bl	_cpu_to_le32
	ldr	x8, [x25, #16]
	str	x0, [x8, x28]
	ldr	w8, [x25]
	add	w8, w8, #1
	str	w8, [x25]
	mov	x0, x21
	bl	_spin_unlock_irqrestore
Lloh21:
	adrp	x8, _TDR@GOTPAGE
Lloh22:
	ldr	x8, [x8, _TDR@GOTPAGEOFF]
Lloh23:
	ldr	w0, [x8]
	mov	w1, #0
	bl	_ADM8211_CSR_WRITE
	mov	w0, #0
LBB0_5:
	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
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh14
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh13
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh10
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_PCI_DMA_TODEVICE,4,2           ; @PCI_DMA_TODEVICE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_TDES1_CONTROL_IC,4,2           ; @TDES1_CONTROL_IC
	.comm	_TDES1_CONTROL_LS,4,2           ; @TDES1_CONTROL_LS
	.comm	_TDES1_CONTROL_FS,4,2           ; @TDES1_CONTROL_FS
	.comm	_TDES1_CONTROL_TER,4,2          ; @TDES1_CONTROL_TER
	.comm	_TDES0_CONTROL_OWN,4,2          ; @TDES0_CONTROL_OWN
	.comm	_TDR,4,2                        ; @TDR
	.no_dead_strip	_adm8211_tx_raw
.subsections_via_symbols
