	.file	"extr_sge.c_restart_offloadq.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	restart_offloadq, @function
restart_offloadq:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 40
	.cfi_def_cfa_offset 96
	mov	rax, QWORD PTR TXQ_OFLD[rip]
	mov	QWORD PTR 24[rsp], rdi
	lea	rdx, [rax+rax*8]
	mov	rax, QWORD PTR 8[rdi]
	mov	edi, DWORD PTR 4[rdi]
	lea	rbx, [rax+rdx*4]
	call	netdev_priv@PLT
	lea	rbp, 24[rbx]
	lea	r12, 28[rbx]
	mov	rdi, rbp
	mov	r14, QWORD PTR [rax]
	call	spin_lock@PLT
	mov	DWORD PTR 20[rsp], 0
.L2:
	mov	edx, DWORD PTR TX_RECLAIM_CHUNK[rip]
	mov	rsi, rbx
	mov	rdi, r14
	call	reclaim_completed_tx@PLT
	jmp	.L3
	.p2align 4,,10
	.p2align 3
.L11:
	mov	ecx, DWORD PTR 12[rbx]
	mov	edx, DWORD PTR [rbx]
	add	DWORD PTR 4[rbx], r13d
	mov	r8d, DWORD PTR 8[rbx]
	lea	eax, 0[r13+rcx]
	add	DWORD PTR 20[rsp], r13d
	mov	DWORD PTR 12[rbx], eax
	cmp	eax, edx
	jb	.L10
	sub	eax, edx
	mov	DWORD PTR 12[rbx], eax
	mov	eax, r8d
	xor	eax, 1
	mov	DWORD PTR 8[rbx], eax
.L10:
	mov	rsi, r12
	mov	rdi, r15
	mov	DWORD PTR 16[rsp], ecx
	mov	DWORD PTR 12[rsp], r8d
	call	__skb_unlink@PLT
	mov	rdi, rbp
	call	spin_unlock@PLT
	sub	rsp, 8
	.cfi_def_cfa_offset 104
	push	QWORD PTR 8[r15]
	.cfi_def_cfa_offset 112
	mov	rdx, rbx
	mov	r8d, DWORD PTR 28[rsp]
	mov	r9d, r13d
	mov	rsi, r15
	mov	rdi, r14
	mov	ecx, DWORD PTR 32[rsp]
	call	write_ofld_wr@PLT
	mov	rdi, rbp
	call	spin_lock@PLT
	pop	rax
	.cfi_def_cfa_offset 104
	pop	rdx
	.cfi_def_cfa_offset 96
.L3:
	mov	rdi, r12
	call	skb_peek@PLT
	mov	r15, rax
	test	rax, rax
	je	.L6
	mov	r13d, DWORD PTR [r15]
	mov	eax, DWORD PTR [rbx]
	xor	edi, edi
	sub	eax, DWORD PTR 4[rbx]
	cmp	eax, r13d
	setb	dil
	call	unlikely@PLT
	test	rax, rax
	jne	.L21
	mov	rdi, r15
	call	immediate@PLT
	test	eax, eax
	jne	.L11
	mov	rdx, QWORD PTR 8[r15]
	mov	edi, DWORD PTR [r14]
	mov	rsi, r15
	call	map_skb@PLT
	test	rax, rax
	je	.L11
.L6:
	mov	rdi, rbp
	call	spin_unlock@PLT
	xor	eax, eax
	call	wmb@PLT
	mov	edi, DWORD PTR 20[rsp]
	call	likely@PLT
	test	rax, rax
	jne	.L22
	add	rsp, 40
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L21:
	.cfi_restore_state
	mov	rdi, QWORD PTR TXQ_OFLD[rip]
	mov	rsi, QWORD PTR 24[rsp]
	call	set_bit@PLT
	xor	eax, eax
	call	smp_mb__after_atomic@PLT
	mov	rdi, rbx
	call	should_restart_tx@PLT
	test	rax, rax
	je	.L7
	mov	rsi, QWORD PTR 24[rsp]
	mov	rdi, QWORD PTR TXQ_OFLD[rip]
	call	test_and_clear_bit@PLT
	test	rax, rax
	jne	.L2
.L7:
	add	DWORD PTR 32[rbx], 1
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L22:
	mov	edi, DWORD PTR 16[rbx]
	call	V_EGRCNTX@PLT
	mov	esi, DWORD PTR A_SG_KDOORBELL[rip]
	or	eax, DWORD PTR F_SELEGRCNTX[rip]
	add	rsp, 40
	.cfi_def_cfa_offset 56
	pop	rbx
	.cfi_def_cfa_offset 48
	mov	rdi, r14
	pop	rbp
	.cfi_def_cfa_offset 40
	mov	edx, eax
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	jmp	t3_write_reg@PLT
	.cfi_endproc
.LFE0:
	.size	restart_offloadq, .-restart_offloadq
	.comm	TX_RECLAIM_CHUNK,4,4
	.comm	TXQ_RUNNING,8,8
	.comm	TXQ_OFLD,8,8
	.comm	TXQ_LAST_PKT_DB,8,8
	.comm	F_SELEGRCNTX,4,4
	.comm	A_SG_KDOORBELL,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_sge.c_restart_offloadq.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	restart_offloadq, %function
restart_offloadq:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldr	r3, .L23
	ldr	r4, [r0, #8]
	ldr	r3, [r3]
	sub	sp, sp, #28
	add	r3, r3, r3, lsl #3
	str	r0, [sp, #20]
	ldr	r0, [r0, #4]
	add	r4, r4, r3, lsl #2
	bl	netdev_priv
	mov	r3, r0
	add	r7, r4, #24
	mov	r0, r7
	ldr	r10, [r3]
	mov	r9, #0
	bl	spin_lock
	add	r8, r4, #28
.L2:
	ldr	r3, .L23+4
	mov	r1, r4
	mov	r0, r10
	ldr	r2, [r3]
	bl	reclaim_completed_tx
	b	.L3
.L11:
	ldr	r3, [r4, #12]
	ldm	r4, {r0, r1}
	add	r2, r6, r3
	add	r1, r1, r6
	cmp	r2, r0
	ldr	fp, [r4, #8]
	add	r9, r9, r6
	str	r2, [r4, #12]
	str	r1, [r4, #4]
	subcs	r2, r2, r0
	eorcs	r1, fp, #1
	strcs	r2, [r4, #12]
	strcs	r1, [r4, #8]
.L10:
	mov	r1, r8
	mov	r0, r5
	str	r3, [sp, #16]
	bl	__skb_unlink
	mov	r0, r7
	bl	spin_unlock
	ldr	r2, [r5, #4]
	mov	r1, r5
	str	r2, [sp, #8]
	mov	r0, r10
	mov	r2, r4
	ldr	r3, [sp, #16]
	str	r6, [sp, #4]
	str	fp, [sp]
	bl	write_ofld_wr
	mov	r0, r7
	bl	spin_lock
.L3:
	mov	r0, r8
	bl	skb_peek
	subs	r5, r0, #0
	beq	.L6
	ldm	r4, {r0, r3}
	ldr	r6, [r5]
	sub	r0, r0, r3
	cmp	r0, r6
	movcs	r0, #0
	movcc	r0, #1
	bl	unlikely
	cmp	r0, #0
	bne	.L21
	mov	r0, r5
	bl	immediate
	cmp	r0, #0
	bne	.L11
	mov	r1, r5
	ldr	r2, [r5, #4]
	ldr	r0, [r10]
	bl	map_skb
	cmp	r0, #0
	beq	.L11
.L6:
	mov	r0, r7
	bl	spin_unlock
	bl	wmb
	mov	r0, r9
	bl	likely
	cmp	r0, #0
	bne	.L22
	add	sp, sp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L21:
	ldr	r3, .L23
	ldr	r1, [sp, #20]
	ldr	r0, [r3]
	bl	set_bit
	bl	smp_mb__after_atomic
	mov	r0, r4
	bl	should_restart_tx
	cmp	r0, #0
	beq	.L7
	ldr	r3, .L23
	ldr	r1, [sp, #20]
	ldr	r0, [r3]
	bl	test_and_clear_bit
	cmp	r0, #0
	bne	.L2
.L7:
	ldr	r3, [r4, #32]
	add	r3, r3, #1
	str	r3, [r4, #32]
	b	.L6
.L22:
	ldr	r3, .L23+8
	ldr	r0, [r4, #16]
	ldr	r4, [r3]
	bl	V_EGRCNTX
	mov	r2, r0
	mov	r1, r4
	mov	r0, r10
	ldr	r3, .L23+12
	ldr	r3, [r3]
	orr	r2, r2, r3
	add	sp, sp, #28
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	b	t3_write_reg
.L24:
	.align	2
.L23:
	.word	TXQ_OFLD
	.word	TX_RECLAIM_CHUNK
	.word	A_SG_KDOORBELL
	.word	F_SELEGRCNTX
	.size	restart_offloadq, .-restart_offloadq
	.comm	TX_RECLAIM_CHUNK,4,4
	.comm	TXQ_RUNNING,4,4
	.comm	TXQ_OFLD,4,4
	.comm	TXQ_LAST_PKT_DB,4,4
	.comm	F_SELEGRCNTX,4,4
	.comm	A_SG_KDOORBELL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
