	.file	"extr_at91_can.c_at91_irq_tx.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	at91_irq_tx, @function
at91_irq_tx:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13, rdi
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	ebx, esi
	call	netdev_priv@PLT
	mov	r12, QWORD PTR [rax]
	mov	rbp, rax
	mov	rax, r12
	sub	rax, QWORD PTR 8[rbp]
	test	rax, rax
	jle	.L2
	mov	r14d, 1
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L5:
	mov	rax, QWORD PTR 8[rbp]
	mov	r12, QWORD PTR 0[rbp]
	add	rax, 1
	mov	rcx, r12
	sub	rcx, rax
	mov	QWORD PTR 8[rbp], rax
	test	rcx, rcx
	jle	.L2
.L6:
	mov	rdi, rbp
	call	get_tx_echo_mb@PLT
	bt	ebx, eax
	mov	r12d, eax
	jnc	.L21
	mov	ecx, eax
	mov	esi, DWORD PTR AT91_IDR[rip]
	mov	edx, r14d
	mov	rdi, rbp
	sal	edx, cl
	call	at91_write@PLT
	mov	edi, r12d
	call	AT91_MSR@PLT
	mov	rdi, rbp
	mov	esi, eax
	call	at91_read@PLT
	mov	edi, eax
	and	edi, DWORD PTR AT91_MSR_MRDY[rip]
	je	.L4
	xor	edi, edi
	not	eax
	test	DWORD PTR AT91_MSR_MABT[rip], eax
	setne	dil
.L4:
	call	likely@PLT
	test	rax, rax
	je	.L5
	mov	rdi, rbp
	call	get_mb_tx_first@PLT
	mov	esi, r12d
	mov	rdi, r13
	sub	rsi, rax
	call	can_get_echo_skb@PLT
	add	DWORD PTR 0[r13], 1
	mov	esi, DWORD PTR CAN_LED_EVENT_TX[rip]
	mov	rdi, r13
	call	can_led_event@PLT
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L21:
	mov	r12, QWORD PTR 0[rbp]
.L2:
	mov	rdi, rbp
	call	get_next_mask@PLT
	cdqe
	test	rax, r12
	jne	.L8
	mov	rdi, rbp
	mov	rbx, QWORD PTR 8[rbp]
	call	get_next_mask@PLT
	cdqe
	test	rax, rbx
	je	.L8
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	pop	rbx
	.cfi_def_cfa_offset 40
	mov	rdi, r13
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	netif_wake_queue@PLT
	.cfi_endproc
.LFE0:
	.size	at91_irq_tx, .-at91_irq_tx
	.comm	CAN_LED_EVENT_TX,4,4
	.comm	AT91_MSR_MRDY,4,4
	.comm	AT91_MSR_MABT,4,4
	.comm	AT91_IDR,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_at91_can.c_at91_irq_tx.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	at91_irq_tx, %function
at91_irq_tx:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r6, r1
	mov	r5, r0
	bl	netdev_priv
	ldr	r4, [r0]
	ldr	r2, [r0, #4]
	mov	fp, r0
	sub	r2, r4, r2
	cmp	r2, #0
	ble	.L2
	mov	r7, #1
	ldr	r9, .L23
	ldr	r8, .L23+4
	ldr	r10, .L23+8
	b	.L6
.L5:
	ldr	r2, [fp, #4]
	ldr	r4, [fp]
	add	r2, r2, #1
	sub	r1, r4, r2
	cmp	r1, #0
	str	r2, [fp, #4]
	ble	.L2
.L6:
	mov	r0, fp
	bl	get_tx_echo_mb
	asr	r1, r6, r0
	tst	r1, #1
	mov	r4, r0
	lsl	r2, r7, r0
	beq	.L22
	ldr	r1, [r9]
	mov	r0, fp
	bl	at91_write
	mov	r0, r4
	bl	AT91_MSR
	mov	r1, r0
	mov	r0, fp
	bl	at91_read
	ldr	r2, [r8]
	mov	r1, r0
	ands	r0, r0, r2
	beq	.L4
	ldr	r2, [r10]
	bics	r3, r2, r1
	movne	r0, #1
	moveq	r0, #0
.L4:
	bl	likely
	cmp	r0, #0
	beq	.L5
	mov	r0, fp
	bl	get_mb_tx_first
	mov	r1, r0
	mov	r0, r5
	sub	r1, r4, r1
	bl	can_get_echo_skb
	ldr	r2, [r5]
	ldr	r3, .L23+12
	add	r2, r2, #1
	str	r2, [r5]
	mov	r0, r5
	ldr	r1, [r3]
	bl	can_led_event
	b	.L5
.L22:
	ldr	r4, [fp]
.L2:
	mov	r0, fp
	bl	get_next_mask
	tst	r0, r4
	beq	.L7
	mov	r0, r5
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	b	netif_wake_queue
.L7:
	mov	r0, fp
	ldr	r4, [fp, #4]
	bl	get_next_mask
	tst	r4, r0
	popne	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
	mov	r0, r5
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	b	netif_wake_queue
.L24:
	.align	2
.L23:
	.word	AT91_IDR
	.word	AT91_MSR_MRDY
	.word	AT91_MSR_MABT
	.word	CAN_LED_EVENT_TX
	.size	at91_irq_tx, .-at91_irq_tx
	.comm	CAN_LED_EVENT_TX,4,4
	.comm	AT91_MSR_MRDY,4,4
	.comm	AT91_MSR_MABT,4,4
	.comm	AT91_IDR,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
