	.file	"extr_ipw2100.c_ipw2100_rx_allocate.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"enter\n"
.LC1:
	.string	"failed bd_queue_allocate\n"
.LC2:
	.string	"failed status_queue_allocate\n"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC3:
	.string	"can't allocate rx packet buffer table\n"
	.text
	.p2align 4
	.type	ipw2100_rx_allocate, @function
ipw2100_rx_allocate:
.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
	mov	rbp, rdi
	lea	rdi, .LC0[rip]
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	call	IPW_DEBUG_INFO@PLT
	mov	edx, DWORD PTR RX_QUEUE_LENGTH[rip]
	mov	rsi, rbp
	mov	rdi, rbp
	call	bd_queue_allocate@PLT
	mov	DWORD PTR 12[rsp], eax
	test	eax, eax
	jne	.L25
	mov	esi, DWORD PTR RX_QUEUE_LENGTH[rip]
	mov	rdi, rbp
	call	status_queue_allocate@PLT
	mov	DWORD PTR 12[rsp], eax
	test	eax, eax
	jne	.L26
	mov	edi, DWORD PTR RX_QUEUE_LENGTH[rip]
	mov	edx, DWORD PTR GFP_KERNEL[rip]
	mov	esi, 8
	call	kmalloc_array@PLT
	mov	QWORD PTR 8[rbp], rax
	mov	rdi, rax
	test	rax, rax
	je	.L5
	mov	eax, DWORD PTR RX_QUEUE_LENGTH[rip]
	xor	r12d, r12d
	test	eax, eax
	jg	.L6
	jmp	.L27
	.p2align 4,,10
	.p2align 3
.L8:
	mov	eax, DWORD PTR 4[rbx]
	add	r15, QWORD PTR 0[rbp]
	lea	r14d, 1[r12]
	mov	DWORD PTR 4[r15], eax
	mov	eax, DWORD PTR IPW_RX_NIC_BUFFER_LENGTH[rip]
	mov	DWORD PTR [r15], eax
	mov	rax, QWORD PTR 24[rbp]
	mov	QWORD PTR [rax+r12*8], 0
	mov	eax, DWORD PTR RX_QUEUE_LENGTH[rip]
	add	r12, 1
	cmp	eax, r12d
	jle	.L10
	mov	rdi, QWORD PTR 8[rbp]
.L6:
	lea	r15, 0[0+r12*8]
	mov	r14d, r12d
	lea	rbx, [rdi+r15]
	mov	rdi, rbp
	mov	rsi, rbx
	call	ipw2100_alloc_skb@PLT
	mov	edi, eax
	mov	r13d, eax
	call	unlikely@PLT
	test	rax, rax
	je	.L8
	mov	eax, DWORD PTR ENOMEM[rip]
	neg	eax
	cmp	DWORD PTR RX_QUEUE_LENGTH[rip], r12d
	je	.L1
	mov	DWORD PTR 12[rsp], eax
	mov	rdi, QWORD PTR 8[rbp]
	test	r12d, r12d
	jle	.L12
.L15:
	xor	ebx, ebx
	.p2align 4,,10
	.p2align 3
.L14:
	mov	esi, DWORD PTR 4[rdi+rbx*8]
	mov	ecx, DWORD PTR PCI_DMA_FROMDEVICE[rip]
	mov	edx, 8
	mov	edi, DWORD PTR 16[rbp]
	call	pci_unmap_single@PLT
	mov	rax, QWORD PTR 8[rbp]
	mov	edi, DWORD PTR [rax+rbx*8]
	add	rbx, 1
	call	dev_kfree_skb@PLT
	mov	rdi, QWORD PTR 8[rbp]
	cmp	r14d, ebx
	jg	.L14
.L12:
	call	kfree@PLT
	mov	QWORD PTR 8[rbp], 0
	mov	rdi, rbp
	mov	rsi, rbp
	call	bd_queue_free@PLT
	mov	rdi, rbp
	call	status_queue_free@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L26:
	lea	rdi, .LC2[rip]
	call	IPW_DEBUG_INFO@PLT
	mov	rsi, rbp
	mov	rdi, rbp
	call	bd_queue_free@PLT
.L1:
	mov	eax, DWORD PTR 12[rsp]
	add	rsp, 24
	.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
.L25:
	.cfi_restore_state
	lea	rdi, .LC1[rip]
	call	IPW_DEBUG_INFO@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L10:
	cmp	r14d, eax
	je	.L1
	mov	DWORD PTR 12[rsp], r13d
	mov	rdi, QWORD PTR 8[rbp]
	jmp	.L15
	.p2align 4,,10
	.p2align 3
.L5:
	lea	rdi, .LC3[rip]
	call	IPW_DEBUG_INFO@PLT
	mov	rsi, rbp
	mov	rdi, rbp
	call	bd_queue_free@PLT
	mov	rdi, rbp
	call	status_queue_free@PLT
	mov	eax, DWORD PTR ENOMEM[rip]
	neg	eax
	mov	DWORD PTR 12[rsp], eax
	jmp	.L1
.L27:
	jne	.L12
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	ipw2100_rx_allocate, .-ipw2100_rx_allocate
	.comm	RX_QUEUE_LENGTH,4,4
	.comm	PCI_DMA_FROMDEVICE,4,4
	.comm	IPW_RX_NIC_BUFFER_LENGTH,4,4
	.comm	GFP_KERNEL,4,4
	.comm	ENOMEM,4,4
	.comm	EINVAL,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_ipw2100.c_ipw2100_rx_allocate.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"enter\012\000"
	.align	2
.LC1:
	.ascii	"failed bd_queue_allocate\012\000"
	.align	2
.LC2:
	.ascii	"failed status_queue_allocate\012\000"
	.align	2
.LC3:
	.ascii	"can't allocate rx packet buffer table\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	ipw2100_rx_allocate, %function
ipw2100_rx_allocate:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r5, r0
	ldr	r9, .L24
	ldr	r0, .L24+4
	bl	IPW_DEBUG_INFO
	mov	r1, r5
	mov	r0, r5
	ldr	r2, [r9]
	bl	bd_queue_allocate
	subs	r7, r0, #0
	bne	.L21
	mov	r0, r5
	ldr	r1, [r9]
	bl	status_queue_allocate
	subs	r7, r0, #0
	bne	.L22
	ldr	r3, .L24+8
	mov	r1, #8
	ldr	r2, [r3]
	ldr	r0, [r9]
	bl	kmalloc_array
	cmp	r0, #0
	str	r0, [r5, #4]
	beq	.L5
	ldr	r3, [r9]
	cmp	r3, #0
	movgt	r6, r7
	ldrgt	r10, .L24+12
	bgt	.L6
	b	.L23
.L8:
	ldr	r2, [r5]
	ldr	lr, [r4, #4]
	ldr	r1, [r5, #12]
	ldr	ip, [r10]
	add	r3, r2, r3
	str	lr, [r3, #4]
	ldr	r3, [r9]
	str	ip, [r2, r6, lsl #3]
	str	r0, [r1, r6, lsl #2]
	add	r6, r6, #1
	cmp	r3, r6
	ble	.L10
	ldr	r0, [r5, #4]
.L6:
	add	r4, r0, r6, lsl #3
	mov	r1, r4
	mov	r0, r5
	bl	ipw2100_alloc_skb
	mov	r8, r0
	bl	unlikely
	cmp	r0, #0
	lsl	r3, r6, #3
	beq	.L8
	ldr	r2, .L24+16
	ldr	r3, [r9]
	ldr	r8, [r2]
	cmp	r3, r6
	rsb	r8, r8, #0
	beq	.L1
	cmp	r6, #0
	ldr	r0, [r5, #4]
	ble	.L17
.L15:
	ldr	r4, .L24+20
	b	.L14
.L13:
	ldr	r0, [r5, #4]
.L14:
	add	r1, r0, r7, lsl #3
	mov	r2, #8
	ldr	r1, [r1, #4]
	ldr	r3, [r4]
	ldr	r0, [r5, #8]
	bl	pci_unmap_single
	ldr	r3, [r5, #4]
	ldr	r0, [r3, r7, lsl #3]
	add	r7, r7, #1
	bl	dev_kfree_skb
	cmp	r7, r6
	blt	.L13
	mov	r7, r8
	ldr	r0, [r5, #4]
.L12:
	bl	kfree
	mov	r3, #0
	mov	r1, r5
	str	r3, [r5, #4]
	mov	r0, r5
	bl	bd_queue_free
	mov	r0, r5
	bl	status_queue_free
	mov	r0, r7
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L22:
	ldr	r0, .L24+24
	bl	IPW_DEBUG_INFO
	mov	r1, r5
	mov	r0, r5
	bl	bd_queue_free
.L1:
	mov	r0, r7
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L21:
	ldr	r0, .L24+28
	bl	IPW_DEBUG_INFO
	mov	r0, r7
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L10:
	beq	.L1
	ldr	r0, [r5, #4]
	b	.L15
.L5:
	ldr	r0, .L24+32
	bl	IPW_DEBUG_INFO
	mov	r1, r5
	mov	r0, r5
	bl	bd_queue_free
	mov	r0, r5
	bl	status_queue_free
	ldr	r3, .L24+16
	ldr	r7, [r3]
	rsb	r7, r7, #0
	b	.L1
.L23:
	bne	.L12
	b	.L1
.L17:
	mov	r7, r8
	b	.L12
.L25:
	.align	2
.L24:
	.word	RX_QUEUE_LENGTH
	.word	.LC0
	.word	GFP_KERNEL
	.word	IPW_RX_NIC_BUFFER_LENGTH
	.word	ENOMEM
	.word	PCI_DMA_FROMDEVICE
	.word	.LC2
	.word	.LC1
	.word	.LC3
	.size	ipw2100_rx_allocate, .-ipw2100_rx_allocate
	.comm	RX_QUEUE_LENGTH,4,4
	.comm	PCI_DMA_FROMDEVICE,4,4
	.comm	IPW_RX_NIC_BUFFER_LENGTH,4,4
	.comm	GFP_KERNEL,4,4
	.comm	ENOMEM,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
