	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function sh_eth_tx_free
_sh_eth_tx_free:                        ## @sh_eth_tx_free
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, -48(%rbp)                 ## 4-byte Spill
	movq	%rdi, -64(%rbp)                 ## 8-byte Spill
	callq	_netdev_priv
	movq	%rax, %r14
	movslq	8(%rax), %rax
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	cmpq	%rax, (%r14)
	jle	LBB0_12
## %bb.1:
	movl	$0, -44(%rbp)                   ## 4-byte Folded Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_9:                                 ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$0, -52(%rbp)                   ## 4-byte Folded Reload
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	je	LBB0_10
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	movslq	8(%r14), %rax
	incq	%rax
	movl	%eax, 8(%r14)
	cmpq	%rax, (%r14)
	jle	LBB0_12
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
                                        ## kill: def $eax killed $eax killed $rax
	cltd
	idivl	12(%r14)
	movq	32(%r14), %rax
	movl	%edx, -56(%rbp)                 ## 4-byte Spill
	movslq	%edx, %r12
	leaq	(%r12,%r12,2), %rcx
	movq	%rax, %r15
	movq	%rcx, -80(%rbp)                 ## 8-byte Spill
	movl	(%rax,%rcx,4), %ebx
	movq	_TD_TACT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_le32
	andl	%ebx, %eax
	cmpl	$0, -48(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	testl	%eax, %eax
	jne	LBB0_12
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	-80(%rbp), %rbx                 ## 8-byte Reload
	movq	%r15, -72(%rbp)                 ## 8-byte Spill
	leaq	(%r15,%rbx,4), %r13
	xorl	%eax, %eax
	callq	_dma_rmb
	movq	_tx_done@GOTPCREL(%rip), %rax
	movl	(%rax), %r15d
	movq	%r13, -96(%rbp)                 ## 8-byte Spill
	movl	(%r13), %edi
	callq	_le32_to_cpu
	movq	%r14, %rdi
	movl	%r15d, %esi
	movq	-64(%rbp), %rdx                 ## 8-byte Reload
	leaq	L_.str(%rip), %rcx
	movl	%r12d, %r8d
	movl	%eax, %r9d
	callq	_netif_info
	movq	16(%r14), %rax
	cmpq	$0, (%rax,%r12,8)
	je	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	24(%r14), %rax
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movq	-72(%rbp), %r13                 ## 8-byte Reload
	movl	4(%r13,%rbx,4), %edi
	callq	_le32_to_cpu
	movl	%eax, %r15d
	movl	8(%r13,%rbx,4), %edi
	callq	_le32_to_cpu
	sarl	$16, %eax
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_dma_unmap_single
	movq	16(%r14), %rax
	movq	(%rax,%r12,8), %rdi
	callq	_dev_kfree_skb_irq
	movq	16(%r14), %rax
	movq	$0, (%rax,%r12,8)
	incl	-44(%rbp)                       ## 4-byte Folded Spill
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	incl	4(%rbx)
	movl	8(%r13,%rcx,4), %edi
	callq	_le32_to_cpu
	sarl	$16, %eax
	addl	%eax, (%rbx)
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	-72(%rbp), %r13                 ## 8-byte Reload
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movq	_TD_TFP@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_le32
	movq	-96(%rbp), %rbx                 ## 8-byte Reload
	movl	%eax, (%rbx)
	movl	12(%r14), %eax
	decl	%eax
	cmpl	%eax, -56(%rbp)                 ## 4-byte Folded Reload
	jl	LBB0_9
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_TD_TDLE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_cpu_to_le32
	orl	%eax, (%rbx)
	jmp	LBB0_9
LBB0_12:
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_TD_TACT,4,2                    ## @TD_TACT
	.comm	_tx_done,4,2                    ## @tx_done
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"tx entry %d status 0x%08x\n"

	.comm	_DMA_TO_DEVICE,4,2              ## @DMA_TO_DEVICE
	.comm	_TD_TFP,4,2                     ## @TD_TFP
	.comm	_TD_TDLE,4,2                    ## @TD_TDLE
	.no_dead_strip	_sh_eth_tx_free
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function sh_eth_tx_free
_sh_eth_tx_free:                        ; @sh_eth_tx_free
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x25, x1
	mov	x20, x0
	bl	_netdev_priv
	ldr	x9, [x0]
	ldrsw	x8, [x0, #8]
	cmp	x9, x8
	b.le	LBB0_11
; %bb.1:
	mov	x22, x0
	mov	w26, #0
	mov	w21, #12
                                        ; kill: def $w8 killed $w8 killed $x8 def $x8
	str	w25, [sp, #12]                  ; 4-byte Folded Spill
	b	LBB0_4
LBB0_2:                                 ;   in Loop: Header=BB0_4 Depth=1
	mov	x20, x21
	mov	w21, #12
	cbz	w19, LBB0_10
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldrsw	x8, [x22, #8]
	add	x8, x8, #1
	str	w8, [x22, #8]
	ldr	x9, [x22]
	cmp	x9, x8
	b.le	LBB0_12
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w9, [x22, #12]
	sdiv	w10, w8, w9
	msub	w24, w10, w9, w8
	ldr	x23, [x22, #32]
	smaddl	x27, w24, w21, x23
	ldr	w19, [x27]
Lloh0:
	adrp	x8, _TD_TACT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _TD_TACT@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_cpu_to_le32
	and	w19, w0, w19
	cbz	w25, LBB0_6
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	cbnz	w19, LBB0_12
LBB0_6:                                 ;   in Loop: Header=BB0_4 Depth=1
	sxtw	x24, w24
	bl	_dma_rmb
Lloh3:
	adrp	x8, _tx_done@GOTPAGE
Lloh4:
	ldr	x8, [x8, _tx_done@GOTPAGEOFF]
Lloh5:
	ldr	w25, [x8]
	ldr	w0, [x27]
	bl	_le32_to_cpu
	mov	x5, x0
	mov	x0, x22
	mov	x1, x25
	mov	x21, x20
	mov	x2, x20
Lloh6:
	adrp	x3, l_.str@PAGE
Lloh7:
	add	x3, x3, l_.str@PAGEOFF
	mov	x4, x24
	bl	_netif_info
	ldr	x8, [x22, #16]
	ldr	x8, [x8, x24, lsl #3]
	cbz	x8, LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	x25, [x22, #24]
	mov	w8, #12
	madd	x28, x24, x8, x23
	ldr	w0, [x28, #4]
	bl	_le32_to_cpu
	mov	x20, x26
	mov	x26, x0
	ldr	w0, [x28, #8]
	bl	_le32_to_cpu
	asr	w2, w0, #16
Lloh8:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh9:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh10:
	ldr	w3, [x8]
	mov	x0, x25
	mov	x1, x26
	mov	x26, x20
	bl	_dma_unmap_single
	ldr	x8, [x22, #16]
	lsl	x25, x24, #3
	ldr	x0, [x8, x25]
	bl	_dev_kfree_skb_irq
	ldr	x8, [x22, #16]
	str	xzr, [x8, x25]
	add	w26, w20, #1
LBB0_8:                                 ;   in Loop: Header=BB0_4 Depth=1
Lloh11:
	adrp	x8, _TD_TFP@GOTPAGE
Lloh12:
	ldr	x8, [x8, _TD_TFP@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_cpu_to_le32
	str	w0, [x27]
	ldr	w8, [x22, #12]
	sub	w8, w8, #1
	cmp	w24, w8
	ldr	w25, [sp, #12]                  ; 4-byte Folded Reload
	b.lt	LBB0_2
; %bb.9:                                ;   in Loop: Header=BB0_4 Depth=1
Lloh14:
	adrp	x8, _TD_TDLE@GOTPAGE
Lloh15:
	ldr	x8, [x8, _TD_TDLE@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	bl	_cpu_to_le32
	ldr	w8, [x27]
	orr	w8, w8, w0
	str	w8, [x27]
	b	LBB0_2
LBB0_10:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x20, #4]
	add	w8, w8, #1
	str	w8, [x20, #4]
	madd	x8, x24, x21, x23
	ldr	w0, [x8, #8]
	bl	_le32_to_cpu
	ldr	w8, [x20]
	add	w8, w8, w0, asr #16
	str	w8, [x20]
	b	LBB0_3
LBB0_11:
	mov	w26, #0
LBB0_12:
	mov	x0, x26
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_TD_TACT,4,2                    ; @TD_TACT
	.comm	_tx_done,4,2                    ; @tx_done
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"tx entry %d status 0x%08x\n"

	.comm	_DMA_TO_DEVICE,4,2              ; @DMA_TO_DEVICE
	.comm	_TD_TFP,4,2                     ; @TD_TFP
	.comm	_TD_TDLE,4,2                    ; @TD_TDLE
	.no_dead_strip	_sh_eth_tx_free
.subsections_via_symbols
