	.file	"extr_if_rt.c_rt_tx_done_task.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Tx done task\n"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC1:
	.string	"Tx done task: scheduling again\n"
	.text
	.p2align 4
	.type	rt_tx_done_task, @function
rt_tx_done_task:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	lea	rdx, .LC0[rip]
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	r12, QWORD PTR 48[rdi]
	mov	esi, DWORD PTR RT_DEBUG_TX[rip]
	call	RT_DPRINTF@PLT
	mov	edx, DWORD PTR [r12]
	test	DWORD PTR IFF_DRV_RUNNING[rip], edx
	je	.L1
	mov	ebx, DWORD PTR RT_SOFTC_TX_RING_COUNT[rip]
	sub	ebx, 1
	js	.L4
	movsx	r13, ebx
	sal	r13, 2
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L5:
	sub	ebx, 1
	sub	r13, 4
	cmp	ebx, -1
	je	.L21
.L6:
	mov	eax, DWORD PTR 4[rbp]
	mov	ecx, ebx
	mov	edx, DWORD PTR 0[rbp]
	sal	eax, cl
	test	edx, eax
	je	.L5
	not	eax
	mov	rsi, QWORD PTR 40[rbp]
	mov	rdi, rbp
	sub	ebx, 1
	and	eax, edx
	mov	DWORD PTR 0[rbp], eax
	add	rsi, r13
	sub	r13, 4
	call	rt_tx_eof@PLT
	cmp	ebx, -1
	jne	.L6
.L21:
	mov	edx, DWORD PTR [r12]
.L4:
	mov	eax, DWORD PTR IFF_DRV_OACTIVE[rip]
	mov	QWORD PTR 32[rbp], 0
	not	eax
	and	eax, edx
	mov	DWORD PTR [r12], eax
	mov	rax, QWORD PTR 8[rbp]
	cmp	rax, QWORD PTR RT_CHIPID_RT5350[rip]
	je	.L7
	cmp	rax, QWORD PTR RT_CHIPID_MT7620[rip]
	je	.L7
	cmp	rax, QWORD PTR RT_CHIPID_MT7621[rip]
	je	.L7
	mov	ebx, DWORD PTR INT_TXQ3_DONE[rip]
	or	ebx, DWORD PTR INT_TXQ2_DONE[rip]
	or	ebx, DWORD PTR INT_TXQ1_DONE[rip]
	or	ebx, DWORD PTR INT_TXQ0_DONE[rip]
	jmp	.L9
	.p2align 4,,10
	.p2align 3
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	mov	ebx, DWORD PTR RT5350_INT_TXQ3_DONE[rip]
	or	ebx, DWORD PTR RT5350_INT_TXQ2_DONE[rip]
	or	ebx, DWORD PTR RT5350_INT_TXQ1_DONE[rip]
	or	ebx, DWORD PTR RT5350_INT_TXQ0_DONE[rip]
.L9:
	mov	rdi, rbp
	call	RT_SOFTC_LOCK@PLT
	mov	esi, DWORD PTR 0[rbp]
	mov	rdi, rbp
	not	esi
	and	esi, DWORD PTR 16[rbp]
	and	esi, ebx
	call	rt_intr_enable@PLT
	test	DWORD PTR 0[rbp], ebx
	jne	.L22
.L10:
	mov	rdi, rbp
	call	RT_SOFTC_UNLOCK@PLT
	lea	rdi, 4[r12]
	call	IFQ_IS_EMPTY@PLT
	test	eax, eax
	jne	.L1
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	rdi, r12
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	rt_start@PLT
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	mov	esi, DWORD PTR RT_DEBUG_TX[rip]
	mov	rdi, rbp
	lea	rdx, .LC1[rip]
	call	RT_DPRINTF@PLT
	mov	edi, DWORD PTR 24[rbp]
	lea	rsi, 20[rbp]
	call	taskqueue_enqueue@PLT
	jmp	.L10
	.cfi_endproc
.LFE0:
	.size	rt_tx_done_task, .-rt_tx_done_task
	.comm	RT_SOFTC_TX_RING_COUNT,4,4
	.comm	RT_DEBUG_TX,4,4
	.comm	RT_CHIPID_RT5350,8,8
	.comm	RT_CHIPID_MT7621,8,8
	.comm	RT_CHIPID_MT7620,8,8
	.comm	RT5350_INT_TXQ3_DONE,4,4
	.comm	RT5350_INT_TXQ2_DONE,4,4
	.comm	RT5350_INT_TXQ1_DONE,4,4
	.comm	RT5350_INT_TXQ0_DONE,4,4
	.comm	INT_TXQ3_DONE,4,4
	.comm	INT_TXQ2_DONE,4,4
	.comm	INT_TXQ1_DONE,4,4
	.comm	INT_TXQ0_DONE,4,4
	.comm	IFF_DRV_RUNNING,4,4
	.comm	IFF_DRV_OACTIVE,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_rt.c_rt_tx_done_task.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Tx done task\012\000"
	.align	2
.LC1:
	.ascii	"Tx done task: scheduling again\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	rt_tx_done_task, %function
rt_tx_done_task:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	ldr	r7, .L23
	ldr	r2, .L23+4
	ldr	r1, [r7]
	ldr	r6, [r0, #32]
	mov	r4, r0
	bl	RT_DPRINTF
	ldr	r2, .L23+8
	ldr	r3, [r6]
	ldr	r2, [r2]
	tst	r3, r2
	popeq	{r4, r5, r6, r7, r8, pc}
	ldr	r2, .L23+12
	ldr	r5, [r2]
	subs	r5, r5, #1
	bpl	.L6
	b	.L4
.L5:
	subs	r5, r5, #1
	bcc	.L21
.L6:
	ldm	r4, {r2, r3}
	lsl	r3, r3, r5
	tst	r2, r3
	beq	.L5
	ldr	r1, [r4, #28]
	bic	r3, r2, r3
	add	r1, r1, r5, lsl #2
	mov	r0, r4
	str	r3, [r4]
	bl	rt_tx_eof
	subs	r5, r5, #1
	bcs	.L6
.L21:
	ldr	r3, [r6]
.L4:
	mov	r0, #0
	ldr	r2, .L23+16
	ldr	r1, .L23+20
	ldr	r2, [r2]
	ldr	r1, [r1]
	bic	r3, r3, r2
	ldr	r2, [r4, #8]
	str	r0, [r4, #24]
	cmp	r2, r1
	str	r3, [r6]
	beq	.L7
	ldr	r3, .L23+24
	ldr	r3, [r3]
	cmp	r2, r3
	beq	.L7
	ldr	r3, .L23+28
	ldr	r3, [r3]
	cmp	r2, r3
	beq	.L7
	ldr	r1, .L23+32
	ldr	r3, .L23+36
	ldr	r5, [r1]
	ldr	r3, [r3]
	ldr	r2, .L23+40
	orr	r5, r5, r3
	ldr	r3, .L23+44
	ldr	r2, [r2]
	ldr	r3, [r3]
	orr	r5, r5, r2
	orr	r5, r5, r3
	b	.L9
.L7:
	ldr	r1, .L23+48
	ldr	r3, .L23+52
	ldr	r5, [r1]
	ldr	r3, [r3]
	ldr	r2, .L23+56
	orr	r5, r5, r3
	ldr	r3, .L23+60
	ldr	r2, [r2]
	ldr	r3, [r3]
	orr	r5, r5, r2
	orr	r5, r5, r3
.L9:
	mov	r0, r4
	bl	RT_SOFTC_LOCK
	ldr	r3, [r4]
	ldr	r1, [r4, #12]
	mov	r0, r4
	bic	r1, r1, r3
	and	r1, r1, r5
	bl	rt_intr_enable
	ldr	r3, [r4]
	tst	r5, r3
	bne	.L22
.L10:
	mov	r0, r4
	bl	RT_SOFTC_UNLOCK
	add	r0, r6, #4
	bl	IFQ_IS_EMPTY
	cmp	r0, #0
	popne	{r4, r5, r6, r7, r8, pc}
	mov	r0, r6
	pop	{r4, r5, r6, r7, r8, lr}
	b	rt_start
.L22:
	ldr	r1, [r7]
	mov	r0, r4
	ldr	r2, .L23+64
	bl	RT_DPRINTF
	ldr	r0, [r4, #20]
	add	r1, r4, #16
	bl	taskqueue_enqueue
	b	.L10
.L24:
	.align	2
.L23:
	.word	RT_DEBUG_TX
	.word	.LC0
	.word	IFF_DRV_RUNNING
	.word	RT_SOFTC_TX_RING_COUNT
	.word	IFF_DRV_OACTIVE
	.word	RT_CHIPID_RT5350
	.word	RT_CHIPID_MT7620
	.word	RT_CHIPID_MT7621
	.word	INT_TXQ3_DONE
	.word	INT_TXQ2_DONE
	.word	INT_TXQ1_DONE
	.word	INT_TXQ0_DONE
	.word	RT5350_INT_TXQ3_DONE
	.word	RT5350_INT_TXQ2_DONE
	.word	RT5350_INT_TXQ1_DONE
	.word	RT5350_INT_TXQ0_DONE
	.word	.LC1
	.size	rt_tx_done_task, .-rt_tx_done_task
	.comm	RT_SOFTC_TX_RING_COUNT,4,4
	.comm	RT_DEBUG_TX,4,4
	.comm	RT_CHIPID_RT5350,4,4
	.comm	RT_CHIPID_MT7621,4,4
	.comm	RT_CHIPID_MT7620,4,4
	.comm	RT5350_INT_TXQ3_DONE,4,4
	.comm	RT5350_INT_TXQ2_DONE,4,4
	.comm	RT5350_INT_TXQ1_DONE,4,4
	.comm	RT5350_INT_TXQ0_DONE,4,4
	.comm	INT_TXQ3_DONE,4,4
	.comm	INT_TXQ2_DONE,4,4
	.comm	INT_TXQ1_DONE,4,4
	.comm	INT_TXQ0_DONE,4,4
	.comm	IFF_DRV_RUNNING,4,4
	.comm	IFF_DRV_OACTIVE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
