	.file	"extr_vnic_rq.c_vnic_rq_alloc.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"Failed to hook RQ[%d] resource\n"
	.text
	.p2align 4
	.globl	vnic_rq_alloc
	.type	vnic_rq_alloc, @function
vnic_rq_alloc:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	r15d, r8d
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14d, ecx
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13d, edx
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rsi
	mov	DWORD PTR [rsi], edx
	mov	QWORD PTR 16[rsi], rdi
	mov	esi, DWORD PTR RES_TYPE_RQ[rip]
	call	vnic_dev_get_res@PLT
	mov	DWORD PTR 8[rbp], eax
	test	eax, eax
	je	.L9
	mov	rdi, rbp
	call	vnic_rq_disable@PLT
	mov	rdi, r12
	lea	rsi, 4[rbp]
	mov	ecx, r15d
	mov	edx, r14d
	call	vnic_dev_alloc_desc_ring@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L10
.L1:
	pop	rbp
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	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
.L10:
	.cfi_restore_state
	mov	rdi, rbp
	call	vnic_rq_alloc_bufs@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L1
	mov	rdi, rbp
	call	vnic_rq_free@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L9:
	mov	esi, r13d
	lea	rdi, .LC0[rip]
	call	pr_err@PLT
	mov	r12d, DWORD PTR EINVAL[rip]
	pop	rbp
	.cfi_def_cfa_offset 40
	neg	r12d
	mov	eax, r12d
	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
	.cfi_endproc
.LFE0:
	.size	vnic_rq_alloc, .-vnic_rq_alloc
	.comm	RES_TYPE_RQ,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_vnic_rq.c_vnic_rq_alloc.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Failed to hook RQ[%d] resource\012\000"
	.text
	.align	2
	.global	vnic_rq_alloc
	.syntax unified
	.arm
	.fpu softvfp
	.type	vnic_rq_alloc, %function
vnic_rq_alloc:
	@ args = 4, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r1
	ldr	r1, .L11
	str	r2, [r4]
	ldr	r1, [r1]
	str	r0, [r4, #12]
	mov	r6, r2
	mov	r5, r0
	mov	r7, r3
	bl	vnic_dev_get_res
	cmp	r0, #0
	str	r0, [r4, #8]
	beq	.L9
	mov	r0, r4
	bl	vnic_rq_disable
	mov	r0, r5
	mov	r2, r7
	ldr	r3, [sp, #24]
	add	r1, r4, #4
	bl	vnic_dev_alloc_desc_ring
	subs	r5, r0, #0
	beq	.L10
.L1:
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, pc}
.L10:
	mov	r0, r4
	bl	vnic_rq_alloc_bufs
	subs	r5, r0, #0
	beq	.L1
	mov	r0, r4
	bl	vnic_rq_free
	b	.L1
.L9:
	mov	r1, r6
	ldr	r0, .L11+4
	bl	pr_err
	ldr	r3, .L11+8
	ldr	r5, [r3]
	rsb	r5, r5, #0
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, pc}
.L12:
	.align	2
.L11:
	.word	RES_TYPE_RQ
	.word	.LC0
	.word	EINVAL
	.size	vnic_rq_alloc, .-vnic_rq_alloc
	.comm	RES_TYPE_RQ,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
