	.file	"extr_if_bge.c_bge_free_tx_ring.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	bge_free_tx_ring, @function
bge_free_tx_ring:
.LFB0:
	.cfi_startproc
	endbr64
	cmp	QWORD PTR [rdi], 0
	je	.L8
	mov	eax, DWORD PTR BGE_TX_RING_CNT[rip]
	test	eax, eax
	jle	.L8
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	xor	ebx, ebx
	.p2align 4,,10
	.p2align 3
.L5:
	mov	rax, QWORD PTR 8[rbp]
	lea	r12, 0[0+rbx*4]
	cmp	QWORD PTR [rax+rbx*8], 0
	je	.L4
	mov	rax, QWORD PTR 16[rbp]
	mov	edx, DWORD PTR BUS_DMASYNC_POSTWRITE[rip]
	mov	edi, DWORD PTR 24[rbp]
	mov	esi, DWORD PTR [rax+rbx*4]
	call	bus_dmamap_sync@PLT
	mov	rax, QWORD PTR 16[rbp]
	mov	edi, DWORD PTR 24[rbp]
	mov	esi, DWORD PTR [rax+rbx*4]
	call	bus_dmamap_unload@PLT
	mov	rax, QWORD PTR 8[rbp]
	mov	rdi, QWORD PTR [rax+rbx*8]
	call	m_freem@PLT
	mov	rax, QWORD PTR 8[rbp]
	mov	QWORD PTR [rax+rbx*8], 0
.L4:
	mov	rdi, QWORD PTR 0[rbp]
	mov	esi, 4
	add	rbx, 1
	add	rdi, r12
	call	bzero@PLT
	cmp	DWORD PTR BGE_TX_RING_CNT[rip], ebx
	jg	.L5
	pop	rbx
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore 3
	.cfi_restore 6
	.cfi_restore 12
	ret
	.cfi_endproc
.LFE0:
	.size	bge_free_tx_ring, .-bge_free_tx_ring
	.comm	BUS_DMASYNC_POSTWRITE,4,4
	.comm	BGE_TX_RING_CNT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_if_bge.c_bge_free_tx_ring.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	bge_free_tx_ring, %function
bge_free_tx_ring:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, [r0]
	cmp	r3, #0
	bxeq	lr
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r7, .L17
	ldr	r3, [r7]
	cmp	r3, #0
	pople	{r4, r5, r6, r7, r8, r9, r10, pc}
	mov	r4, #0
	mov	r5, r0
	mov	r9, r4
	ldr	r8, .L17+4
.L4:
	ldr	r3, [r5, #4]
	lsl	r6, r4, #2
	ldr	r3, [r3, r4, lsl #2]
	cmp	r3, #0
	beq	.L3
	ldr	r3, [r5, #8]
	ldr	r2, [r8]
	ldr	r1, [r3, r4, lsl #2]
	ldr	r0, [r5, #12]
	bl	bus_dmamap_sync
	ldr	r3, [r5, #8]
	ldr	r0, [r5, #12]
	ldr	r1, [r3, r4, lsl #2]
	bl	bus_dmamap_unload
	ldr	r3, [r5, #4]
	ldr	r0, [r3, r4, lsl #2]
	bl	m_freem
	ldr	r3, [r5, #4]
	str	r9, [r3, r4, lsl #2]
.L3:
	ldr	r0, [r5]
	mov	r1, #4
	add	r0, r0, r6
	bl	bzero
	ldr	r3, [r7]
	add	r4, r4, #1
	cmp	r3, r4
	bgt	.L4
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L18:
	.align	2
.L17:
	.word	BGE_TX_RING_CNT
	.word	BUS_DMASYNC_POSTWRITE
	.size	bge_free_tx_ring, .-bge_free_tx_ring
	.comm	BUS_DMASYNC_POSTWRITE,4,4
	.comm	BGE_TX_RING_CNT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
