	.file	"extr_ena_com.c_ena_com_handle_admin_completion.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	ena_com_handle_admin_completion, @function
ena_com_handle_admin_completion:
.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
	xor	r13d, r13d
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	eax, DWORD PTR [rdi]
	mov	r14d, DWORD PTR 20[rdi]
	lea	ebx, -1[rax]
	mov	rax, QWORD PTR 24[rdi]
	and	ebx, DWORD PTR 16[rdi]
	movsx	rbx, ebx
	lea	rbp, [rax+rbx*4]
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L9:
	lea	rbp, 0[0+rbx*4]
.L4:
	add	rbp, QWORD PTR 24[r12]
.L2:
	mov	edi, DWORD PTR 0[rbp]
	call	READ_ONCE@PLT
	and	eax, DWORD PTR ENA_ADMIN_ACQ_COMMON_DESC_PHASE_MASK[rip]
	cmp	eax, r14d
	jne	.L8
	xor	eax, eax
	add	rbx, 1
	add	r13, 1
	call	dma_rmb@PLT
	mov	rdi, r12
	mov	rsi, rbp
	call	ena_com_handle_single_admin_completion@PLT
	movsx	rax, DWORD PTR [r12]
	xor	edi, edi
	cmp	rax, rbx
	sete	dil
	call	unlikely@PLT
	test	rax, rax
	je	.L9
	test	r14d, r14d
	sete	r14b
	xor	ebp, ebp
	xor	ebx, ebx
	movzx	r14d, r14b
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L8:
	pop	rbx
	.cfi_def_cfa_offset 40
	add	DWORD PTR 16[r12], r13d
	pop	rbp
	.cfi_def_cfa_offset 32
	add	DWORD PTR 8[r12], r13d
	add	DWORD PTR 4[r12], r13d
	mov	DWORD PTR 20[r12], r14d
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	ena_com_handle_admin_completion, .-ena_com_handle_admin_completion
	.comm	ENA_ADMIN_ACQ_COMMON_DESC_PHASE_MASK,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_ena_com.c_ena_com_handle_admin_completion.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	ena_com_handle_admin_completion, %function
ena_com_handle_admin_completion:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	ldr	r5, [r0]
	ldr	r3, [r0, #12]
	ldr	r4, [r0, #20]
	sub	r5, r5, #1
	and	r5, r5, r3
	mov	r6, r0
	mov	r8, #0
	ldr	r7, [r0, #16]
	ldr	r9, .L8
	add	r4, r4, r5, lsl #2
	b	.L2
.L5:
	bl	dma_rmb
	mov	r1, r4
	mov	r0, r6
	bl	ena_com_handle_single_admin_completion
	ldr	r0, [r6]
	add	r8, r8, #1
	sub	r0, r0, r5
	clz	r0, r0
	lsr	r0, r0, #5
	bl	unlikely
	cmp	r0, #0
	movne	r5, #0
	clzne	r7, r7
	movne	r1, r5
	ldr	r4, [r6, #20]
	lsleq	r1, r5, #2
	lsrne	r7, r7, #5
	add	r4, r4, r1
.L2:
	ldr	r0, [r4]
	bl	READ_ONCE
	ldr	r3, [r9]
	add	r5, r5, #1
	and	r0, r0, r3
	cmp	r0, r7
	beq	.L5
	ldr	r1, [r6, #12]
	ldr	r2, [r6, #8]
	ldr	r3, [r6, #4]
	add	r1, r1, r8
	add	r2, r2, r8
	add	r8, r3, r8
	str	r7, [r6, #16]
	str	r1, [r6, #12]
	str	r2, [r6, #8]
	str	r8, [r6, #4]
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L9:
	.align	2
.L8:
	.word	ENA_ADMIN_ACQ_COMMON_DESC_PHASE_MASK
	.size	ena_com_handle_admin_completion, .-ena_com_handle_admin_completion
	.comm	ENA_ADMIN_ACQ_COMMON_DESC_PHASE_MASK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
