	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function bgmac_dma_tx_add
_bgmac_dma_tx_add:                      ## @bgmac_dma_tx_add
	.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	$88, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %rbx
	movq	(%rdi), %r12
	movl	(%rsi), %eax
	movq	_BGMAC_TX_RING_SLOTS@GOTPCREL(%rip), %r14
	cltd
	idivl	(%r14)
	movl	%edx, %ecx
	movl	(%rbx), %edx
	movq	_BGMAC_DESC_CTL1_LEN@GOTPCREL(%rip), %rax
	cmpl	(%rax), %edx
	jle	LBB0_2
## %bb.1:
	leaq	L_.str(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_netdev_err
	jmp	LBB0_16
LBB0_2:
	movq	%rsi, %r13
	movq	%rdi, %r15
	movq	8(%rdi), %rax
	movq	%rax, -88(%rbp)                 ## 8-byte Spill
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	movslq	%ecx, %rax
	shlq	$4, %rax
	addq	24(%rsi), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movq	8(%rbx), %rax
	movq	_CHECKSUM_PARTIAL@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_4
## %bb.3:
	movq	%rbx, %rdi
	callq	_skb_checksum_help
LBB0_4:
	movq	%rbx, %rdi
	callq	_skb_shinfo
	movl	(%rax), %eax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	leal	1(%rax), %ecx
	movl	(%r13), %eax
	addl	%ecx, %eax
	subl	4(%r13), %eax
	cmpl	(%r14), %eax
	jge	LBB0_5
## %bb.6:
	movq	%r12, -104(%rbp)                ## 8-byte Spill
	movl	%ecx, -92(%rbp)                 ## 4-byte Spill
	movq	%r15, -64(%rbp)                 ## 8-byte Spill
	movl	16(%rbx), %r15d
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	callq	_skb_headlen
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	-88(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movl	%r15d, %esi
	movl	%eax, %edx
	callq	_dma_map_single
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movl	%eax, (%rcx)
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_dma_mapping_error
	movl	%eax, %edi
	callq	_unlikely
	testq	%rax, %rax
	je	LBB0_7
LBB0_15:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rdi
	movl	8(%r13), %edx
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_netdev_err
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	movq	-104(%rbp), %r12                ## 8-byte Reload
LBB0_16:
	movq	%rbx, %rdi
	callq	_dev_kfree_skb
	incl	4(%r12)
	incl	(%r12)
	movq	_NETDEV_TX_OK@GOTPCREL(%rip), %rbx
	jmp	LBB0_17
LBB0_5:
	movq	(%r15), %rdi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_netdev_err
	movq	%r12, %rdi
	callq	_netif_stop_queue
	movq	_NETDEV_TX_BUSY@GOTPCREL(%rip), %rbx
LBB0_17:
	movl	(%rbx), %eax
	addq	$88, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	movq	_BGMAC_DESC_CTL0_SOF@GOTPCREL(%rip), %rax
	movq	_BGMAC_DESC_CTL0_EOF@GOTPCREL(%rip), %rcx
	movq	_BGMAC_DESC_CTL0_IOC@GOTPCREL(%rip), %rdx
	movl	(%rdx), %ebx
	orl	(%rcx), %ebx
	xorl	%ecx, %ecx
	movq	-72(%rbp), %r14                 ## 8-byte Reload
	testq	%r14, %r14
	cmovnel	%ecx, %ebx
	orl	(%rax), %ebx
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_skb_headlen
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	movl	-44(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %edx
	movl	%eax, %ecx
	movl	%ebx, %r8d
	callq	_bgmac_dma_tx_add_buf
	testl	%r14d, %r14d
	jle	LBB0_11
## %bb.8:
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	leal	-1(%rax), %ecx
	shlq	$2, %rcx
	movq	%rcx, -128(%rbp)                ## 8-byte Spill
	shlq	$2, %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	$1, %eax
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	movq	%r13, -112(%rbp)                ## 8-byte Spill
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, -96(%rbp)                 ## 4-byte Spill
	movq	%rax, -120(%rbp)                ## 8-byte Spill
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_skb_shinfo
	movq	8(%rax), %r12
	addq	%r14, %r12
	movq	%r12, %rdi
	callq	_skb_frag_size
	movl	%eax, %r9d
	incl	%r15d
	movl	%r15d, %eax
	cltd
	movq	_BGMAC_TX_RING_SLOTS@GOTPCREL(%rip), %rcx
	idivl	(%rcx)
	movq	24(%r13), %rbx
	movl	%edx, -44(%rbp)                 ## 4-byte Spill
	movslq	%edx, %r13
	shlq	$4, %r13
	leaq	(%rbx,%r13), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	movq	-88(%rbp), %r15                 ## 8-byte Reload
	movq	%r15, %rdi
	movq	%r12, %rsi
	movl	%r9d, %r12d
	xorl	%edx, %edx
	movl	%r9d, %ecx
	callq	_skb_frag_dma_map
	movl	%eax, (%rbx,%r13)
	movq	%r15, %rdi
	movl	%eax, %esi
	callq	_dma_mapping_error
	movl	%eax, %edi
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_13
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	_BGMAC_DESC_CTL0_IOC@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	_BGMAC_DESC_CTL0_EOF@GOTPCREL(%rip), %rcx
	orl	(%rcx), %eax
	cmpq	%r14, -128(%rbp)                ## 8-byte Folded Reload
	movl	$0, %ecx
	cmovnel	%ecx, %eax
	movl	-96(%rbp), %ebx                 ## 4-byte Reload
	orl	%eax, %ebx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movq	-112(%rbp), %r13                ## 8-byte Reload
	movq	%r13, %rsi
	movl	-44(%rbp), %r15d                ## 4-byte Reload
	movl	%r15d, %edx
	movl	%r12d, %ecx
	movl	%ebx, %r8d
	callq	_bgmac_dma_tx_add_buf
	movq	-120(%rbp), %rax                ## 8-byte Reload
	incl	%eax
	addq	$4, %r14
	cmpq	%r14, -72(%rbp)                 ## 8-byte Folded Reload
	jne	LBB0_9
LBB0_11:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	-80(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, 8(%rcx)
	movl	-92(%rbp), %ecx                 ## 4-byte Reload
	addl	%ecx, (%r13)
	movl	(%rax), %esi
	movq	-104(%rbp), %r14                ## 8-byte Reload
	movq	%r14, %rdi
	callq	_netdev_sent_queue
	xorl	%eax, %eax
	callq	_wmb
	movq	_BGMAC_DMA_TX_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	addl	8(%r13), %esi
	movl	(%r13), %eax
	cltd
	movq	_BGMAC_TX_RING_SLOTS@GOTPCREL(%rip), %rbx
	idivl	(%rbx)
	movslq	%edx, %rdx
	shlq	$2, %rdx
	addq	32(%r13), %rdx
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_bgmac_write
	movl	(%r13), %eax
	subl	4(%r13), %eax
	movl	(%rbx), %ecx
	addl	$-8, %ecx
	movq	_NETDEV_TX_OK@GOTPCREL(%rip), %rbx
	cmpl	%ecx, %eax
	jl	LBB0_17
## %bb.12:
	movq	%r14, %rdi
	callq	_netif_stop_queue
	jmp	LBB0_17
LBB0_13:
	movq	-80(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %r14d
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_skb_headlen
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movl	%r14d, %esi
	movl	%eax, %edx
	callq	_dma_unmap_single
	movq	-120(%rbp), %rcx                ## 8-byte Reload
	cmpl	$1, %ecx
	movq	-112(%rbp), %r13                ## 8-byte Reload
	movq	_BGMAC_TX_RING_SLOTS@GOTPCREL(%rip), %r12
	je	LBB0_15
	.p2align	4, 0x90
LBB0_14:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r13), %eax
	addl	%ecx, %eax
	addl	$-2, %eax
	cltd
	idivl	(%r12)
	movq	24(%r13), %r14
	movslq	%edx, %rbx
	movq	16(%r13), %rax
	movl	(%rax,%rbx,4), %edi
	movq	%rcx, %r15
	callq	_le32_to_cpu
	movq	_BGMAC_DESC_CTL1_LEN@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	shlq	$4, %rbx
	movl	(%r14,%rbx), %esi
	movq	_DMA_TO_DEVICE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	-88(%rbp), %rdi                 ## 8-byte Reload
	movl	%eax, %edx
	callq	_dma_unmap_page
	movq	%r15, %rcx
	decl	%ecx
	cmpl	$1, %ecx
	jg	LBB0_14
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_BGMAC_TX_RING_SLOTS,4,2        ## @BGMAC_TX_RING_SLOTS
	.comm	_BGMAC_DESC_CTL1_LEN,4,2        ## @BGMAC_DESC_CTL1_LEN
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Too long skb (%d)\n"

	.comm	_CHECKSUM_PARTIAL,8,3           ## @CHECKSUM_PARTIAL
L_.str.1:                               ## @.str.1
	.asciz	"TX ring is full, queue should be stopped!\n"

	.comm	_NETDEV_TX_BUSY,4,2             ## @NETDEV_TX_BUSY
	.comm	_DMA_TO_DEVICE,4,2              ## @DMA_TO_DEVICE
	.comm	_BGMAC_DESC_CTL0_SOF,4,2        ## @BGMAC_DESC_CTL0_SOF
	.comm	_BGMAC_DESC_CTL0_EOF,4,2        ## @BGMAC_DESC_CTL0_EOF
	.comm	_BGMAC_DESC_CTL0_IOC,4,2        ## @BGMAC_DESC_CTL0_IOC
	.comm	_BGMAC_DMA_TX_INDEX,4,2         ## @BGMAC_DMA_TX_INDEX
	.comm	_NETDEV_TX_OK,4,2               ## @NETDEV_TX_OK
L_.str.2:                               ## @.str.2
	.asciz	"Mapping error of skb on ring 0x%X\n"

	.no_dead_strip	_bgmac_dma_tx_add
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function bgmac_dma_tx_add
_bgmac_dma_tx_add:                      ; @bgmac_dma_tx_add
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x28, x27, [sp, #64]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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	x21, x2
	ldr	x27, [x0]
	ldr	w8, [x2]
Lloh0:
	adrp	x9, _BGMAC_DESC_CTL1_LEN@GOTPAGE
Lloh1:
	ldr	x9, [x9, _BGMAC_DESC_CTL1_LEN@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	cmp	w8, w9
	b.le	LBB0_2
; %bb.1:
	str	x8, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x27
	b	LBB0_7
LBB0_2:
	mov	x20, x1
	mov	x22, x0
	ldr	x28, [x0, #8]
	ldr	w19, [x1]
Lloh5:
	adrp	x25, _BGMAC_TX_RING_SLOTS@GOTPAGE
Lloh6:
	ldr	x25, [x25, _BGMAC_TX_RING_SLOTS@GOTPAGEOFF]
	ldr	w24, [x25]
	ldr	x23, [x1, #24]
	ldr	x8, [x21, #8]
Lloh7:
	adrp	x9, _CHECKSUM_PARTIAL@GOTPAGE
Lloh8:
	ldr	x9, [x9, _CHECKSUM_PARTIAL@GOTPAGEOFF]
Lloh9:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_4
; %bb.3:
	mov	x0, x21
	bl	_skb_checksum_help
LBB0_4:
	mov	x0, x21
	bl	_skb_shinfo
	ldr	w26, [x0]
	ldp	w8, w9, [x20]
	add	w10, w26, #1
	add	w8, w10, w8
	sub	w8, w8, w9
	ldr	w9, [x25]
	cmp	w8, w9
	b.ge	LBB0_9
; %bb.5:
	str	w10, [sp, #28]                  ; 4-byte Folded Spill
	sdiv	w8, w19, w24
	msub	w24, w8, w24, w19
	add	x19, x23, w24, sxtw #4
	ldr	w25, [x21, #16]
	mov	x0, x21
	bl	_skb_headlen
	mov	x2, x0
Lloh10:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh11:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh12:
	ldr	w3, [x8]
	mov	x0, x28
	mov	x1, x25
	bl	_dma_map_single
	mov	x1, x0
	str	w0, [x19]
	mov	x0, x28
	bl	_dma_mapping_error
	bl	_unlikely
	cbz	x0, LBB0_11
LBB0_6:
	ldr	x0, [x22]
	ldr	w8, [x20, #8]
	str	x8, [sp]
Lloh13:
	adrp	x1, l_.str.2@PAGE
Lloh14:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_7:
	bl	_netdev_err
	mov	x0, x21
	bl	_dev_kfree_skb
	ldr	d0, [x27]
	movi.2s	v1, #1
	add.2s	v0, v0, v1
	str	d0, [x27]
LBB0_8:
Lloh15:
	adrp	x8, _NETDEV_TX_OK@GOTPAGE
Lloh16:
	ldr	x8, [x8, _NETDEV_TX_OK@GOTPAGEOFF]
	b	LBB0_10
LBB0_9:
	ldr	x0, [x22]
Lloh17:
	adrp	x1, l_.str.1@PAGE
Lloh18:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_netdev_err
	mov	x0, x27
	bl	_netif_stop_queue
Lloh19:
	adrp	x8, _NETDEV_TX_BUSY@GOTPAGE
Lloh20:
	ldr	x8, [x8, _NETDEV_TX_BUSY@GOTPAGEOFF]
LBB0_10:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_11:
	str	x28, [sp, #48]                  ; 8-byte Folded Spill
	str	x27, [sp, #16]                  ; 8-byte Folded Spill
Lloh21:
	adrp	x8, _BGMAC_DESC_CTL0_SOF@GOTPAGE
Lloh22:
	ldr	x8, [x8, _BGMAC_DESC_CTL0_SOF@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
Lloh24:
	adrp	x9, _BGMAC_DESC_CTL0_EOF@GOTPAGE
Lloh25:
	ldr	x9, [x9, _BGMAC_DESC_CTL0_EOF@GOTPAGEOFF]
Lloh26:
	adrp	x10, _BGMAC_DESC_CTL0_IOC@GOTPAGE
Lloh27:
	ldr	x10, [x10, _BGMAC_DESC_CTL0_IOC@GOTPAGEOFF]
Lloh28:
	ldr	w9, [x9]
Lloh29:
	ldr	w10, [x10]
	orr	w9, w10, w9
	cmp	w26, #0
	csel	w9, w9, wzr, eq
	orr	w25, w9, w8
	str	x21, [sp, #56]                  ; 8-byte Folded Spill
	mov	x0, x21
	bl	_skb_headlen
	mov	x3, x0
	mov	x0, x22
	mov	x1, x20
	mov	x2, x24
	mov	x4, x25
	bl	_bgmac_dma_tx_add_buf
	cmp	w26, #1
	b.lt	LBB0_15
; %bb.12:
	mov	x23, #0
	mov	w25, #0
	sub	w8, w26, #1
	lsl	x9, x8, #2
	lsl	x8, x26, #2
	stp	x8, x9, [sp, #32]               ; 16-byte Folded Spill
	mov	w28, #1
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	mov	x21, x22
	ldr	x0, [sp, #56]                   ; 8-byte Folded Reload
	bl	_skb_shinfo
	ldr	x8, [x0, #8]
	add	x27, x8, x23
	mov	x0, x27
	bl	_skb_frag_size
	mov	x26, x0
	add	w8, w24, #1
Lloh30:
	adrp	x9, _BGMAC_TX_RING_SLOTS@GOTPAGE
Lloh31:
	ldr	x9, [x9, _BGMAC_TX_RING_SLOTS@GOTPAGEOFF]
Lloh32:
	ldr	w9, [x9]
	sdiv	w10, w8, w9
	msub	w24, w10, w9, w8
	ldr	x8, [x20, #24]
	add	x19, x8, w24, sxtw #4
Lloh33:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh34:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh35:
	ldr	w4, [x8]
	ldr	x22, [sp, #48]                  ; 8-byte Folded Reload
	mov	x0, x22
	mov	x1, x27
	mov	w2, #0
	mov	x3, x26
	bl	_skb_frag_dma_map
	mov	x1, x0
	str	w0, [x19]
	mov	x0, x22
	bl	_dma_mapping_error
	bl	_unlikely
	cbnz	x0, LBB0_17
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
Lloh36:
	adrp	x8, _BGMAC_DESC_CTL0_EOF@GOTPAGE
Lloh37:
	ldr	x8, [x8, _BGMAC_DESC_CTL0_EOF@GOTPAGEOFF]
Lloh38:
	ldr	w8, [x8]
Lloh39:
	adrp	x9, _BGMAC_DESC_CTL0_IOC@GOTPAGE
Lloh40:
	ldr	x9, [x9, _BGMAC_DESC_CTL0_IOC@GOTPAGEOFF]
Lloh41:
	ldr	w9, [x9]
	orr	w8, w9, w8
	ldr	x9, [sp, #40]                   ; 8-byte Folded Reload
	cmp	x9, x23
	csel	w8, w8, wzr, eq
	orr	w25, w8, w25
	mov	x22, x21
	mov	x0, x21
	mov	x1, x20
	mov	x2, x24
	mov	x3, x26
	mov	x4, x25
	bl	_bgmac_dma_tx_add_buf
	add	w28, w28, #1
	add	x23, x23, #4
	ldr	x8, [sp, #32]                   ; 8-byte Folded Reload
	cmp	x8, x23
	b.ne	LBB0_13
LBB0_15:
	ldr	x9, [sp, #56]                   ; 8-byte Folded Reload
	str	x9, [x19, #8]
	ldr	w8, [x20]
	ldr	w10, [sp, #28]                  ; 4-byte Folded Reload
	add	w8, w10, w8
	str	w8, [x20]
	ldr	w1, [x9]
	ldr	x19, [sp, #16]                  ; 8-byte Folded Reload
	mov	x0, x19
	bl	_netdev_sent_queue
	bl	_wmb
	ldr	w8, [x20, #8]
Lloh42:
	adrp	x9, _BGMAC_DMA_TX_INDEX@GOTPAGE
Lloh43:
	ldr	x9, [x9, _BGMAC_DMA_TX_INDEX@GOTPAGEOFF]
Lloh44:
	ldr	w9, [x9]
	add	w1, w9, w8
	ldr	x8, [x20, #32]
	ldr	w9, [x20]
Lloh45:
	adrp	x21, _BGMAC_TX_RING_SLOTS@GOTPAGE
Lloh46:
	ldr	x21, [x21, _BGMAC_TX_RING_SLOTS@GOTPAGEOFF]
	ldr	w10, [x21]
	sdiv	w11, w9, w10
	msub	w9, w11, w10, w9
	add	x2, x8, w9, sxtw #2
	mov	x0, x22
	bl	_bgmac_write
	ldp	w8, w9, [x20]
	ldr	w10, [x21]
	sub	w10, w10, #8
	sub	w8, w8, w9
	cmp	w8, w10
	b.lt	LBB0_8
; %bb.16:
	mov	x0, x19
	bl	_netif_stop_queue
	b	LBB0_8
LBB0_17:
	ldr	w24, [x19]
	ldr	x19, [sp, #56]                  ; 8-byte Folded Reload
	mov	x0, x19
	bl	_skb_headlen
	mov	x2, x0
Lloh47:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh48:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh49:
	ldr	w3, [x8]
	ldr	x26, [sp, #48]                  ; 8-byte Folded Reload
	mov	x0, x26
	mov	x1, x24
	bl	_dma_unmap_single
	cmp	w28, #1
	ldr	x27, [sp, #16]                  ; 8-byte Folded Reload
Lloh50:
	adrp	x24, _BGMAC_TX_RING_SLOTS@GOTPAGE
Lloh51:
	ldr	x24, [x24, _BGMAC_TX_RING_SLOTS@GOTPAGEOFF]
Lloh52:
	adrp	x25, _BGMAC_DESC_CTL1_LEN@GOTPAGE
Lloh53:
	ldr	x25, [x25, _BGMAC_DESC_CTL1_LEN@GOTPAGEOFF]
	mov	x22, x21
	mov	x21, x19
	b.eq	LBB0_6
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x20]
	add	w8, w28, w8
	sub	w8, w8, #2
	ldr	w9, [x24]
	sdiv	w10, w8, w9
	msub	w19, w10, w9, w8
	ldp	x8, x23, [x20, #16]
	ldr	w0, [x8, w19, sxtw #2]
	bl	_le32_to_cpu
	ldr	w8, [x25]
	and	w2, w8, w0
	sbfiz	x8, x19, #4, #32
	ldr	w1, [x23, x8]
Lloh54:
	adrp	x8, _DMA_TO_DEVICE@GOTPAGE
Lloh55:
	ldr	x8, [x8, _DMA_TO_DEVICE@GOTPAGEOFF]
Lloh56:
	ldr	w3, [x8]
	mov	x0, x26
	bl	_dma_unmap_page
	sub	w28, w28, #1
	cmp	w28, #1
	b.gt	LBB0_18
	b	LBB0_6
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpAdd	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh29
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh28
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGot	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.loh AdrpLdrGot	Lloh52, Lloh53
	.loh AdrpLdrGot	Lloh50, Lloh51
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh54, Lloh55, Lloh56
	.cfi_endproc
                                        ; -- End function
	.comm	_BGMAC_TX_RING_SLOTS,4,2        ; @BGMAC_TX_RING_SLOTS
	.comm	_BGMAC_DESC_CTL1_LEN,4,2        ; @BGMAC_DESC_CTL1_LEN
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Too long skb (%d)\n"

	.comm	_CHECKSUM_PARTIAL,8,3           ; @CHECKSUM_PARTIAL
l_.str.1:                               ; @.str.1
	.asciz	"TX ring is full, queue should be stopped!\n"

	.comm	_NETDEV_TX_BUSY,4,2             ; @NETDEV_TX_BUSY
	.comm	_DMA_TO_DEVICE,4,2              ; @DMA_TO_DEVICE
	.comm	_BGMAC_DESC_CTL0_SOF,4,2        ; @BGMAC_DESC_CTL0_SOF
	.comm	_BGMAC_DESC_CTL0_EOF,4,2        ; @BGMAC_DESC_CTL0_EOF
	.comm	_BGMAC_DESC_CTL0_IOC,4,2        ; @BGMAC_DESC_CTL0_IOC
	.comm	_BGMAC_DMA_TX_INDEX,4,2         ; @BGMAC_DMA_TX_INDEX
	.comm	_NETDEV_TX_OK,4,2               ; @NETDEV_TX_OK
l_.str.2:                               ; @.str.2
	.asciz	"Mapping error of skb on ring 0x%X\n"

	.no_dead_strip	_bgmac_dma_tx_add
.subsections_via_symbols
