	.file	"extr_mthca_eq.c_mthca_cleanup_eq_table.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	mthca_cleanup_eq_table
	.type	mthca_cleanup_eq_table, @function
mthca_cleanup_eq_table:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	call	mthca_free_irqs@PLT
	mov	rdx, QWORD PTR MTHCA_EQ_ASYNC[rip]
	mov	rax, QWORD PTR 8[rbp]
	mov	rdi, rbp
	mov	r12d, DWORD PTR [rax+rdx*4]
	call	async_mask@PLT
	mov	edx, 1
	mov	rdi, rbp
	mov	esi, eax
	mov	ecx, r12d
	call	mthca_MAP_EQ@PLT
	mov	rdx, QWORD PTR MTHCA_EQ_CMD[rip]
	mov	rax, QWORD PTR 8[rbp]
	mov	rdi, rbp
	mov	esi, DWORD PTR MTHCA_CMD_EVENT_MASK[rip]
	mov	ecx, DWORD PTR [rax+rdx*4]
	mov	edx, 1
	call	mthca_MAP_EQ@PLT
	mov	eax, DWORD PTR MTHCA_NUM_EQ[rip]
	test	eax, eax
	jle	.L2
	xor	ebx, ebx
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rax, QWORD PTR 8[rbp]
	mov	rdi, rbp
	lea	rsi, [rax+rbx*4]
	add	rbx, 1
	call	mthca_free_eq@PLT
	cmp	DWORD PTR MTHCA_NUM_EQ[rip], ebx
	jg	.L3
.L2:
	mov	rdi, rbp
	call	mthca_unmap_eq_regs@PLT
	pop	rbx
	.cfi_def_cfa_offset 24
	mov	rdi, rbp
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	jmp	mthca_alloc_cleanup@PLT
	.cfi_endproc
.LFE0:
	.size	mthca_cleanup_eq_table, .-mthca_cleanup_eq_table
	.comm	MTHCA_NUM_EQ,4,4
	.comm	MTHCA_EQ_CMD,8,8
	.comm	MTHCA_EQ_ASYNC,8,8
	.comm	MTHCA_CMD_EVENT_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_mthca_eq.c_mthca_cleanup_eq_table.c"
	.text
	.align	2
	.global	mthca_cleanup_eq_table
	.syntax unified
	.arm
	.fpu softvfp
	.type	mthca_cleanup_eq_table, %function
mthca_cleanup_eq_table:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	mov	r5, r0
	bl	mthca_free_irqs
	mov	r0, r5
	bl	async_mask
	ldr	r2, .L7
	ldr	r3, [r5, #4]
	ldr	r2, [r2]
	mov	r1, r0
	ldr	r3, [r3, r2, lsl #2]
	mov	r0, r5
	mov	r2, #1
	bl	mthca_MAP_EQ
	ldr	r2, .L7+4
	ldr	r3, [r5, #4]
	ldr	r1, [r2]
	ldr	r2, .L7+8
	ldr	r6, .L7+12
	ldr	r3, [r3, r1, lsl #2]
	mov	r0, r5
	ldr	r1, [r2]
	mov	r2, #1
	bl	mthca_MAP_EQ
	ldr	r3, [r6]
	cmp	r3, #0
	ble	.L2
	mov	r4, #0
.L3:
	ldr	r1, [r5, #4]
	mov	r0, r5
	add	r1, r1, r4, lsl #2
	bl	mthca_free_eq
	ldr	r3, [r6]
	add	r4, r4, #1
	cmp	r3, r4
	bgt	.L3
.L2:
	mov	r0, r5
	bl	mthca_unmap_eq_regs
	mov	r0, r5
	pop	{r4, r5, r6, lr}
	b	mthca_alloc_cleanup
.L8:
	.align	2
.L7:
	.word	MTHCA_EQ_ASYNC
	.word	MTHCA_EQ_CMD
	.word	MTHCA_CMD_EVENT_MASK
	.word	MTHCA_NUM_EQ
	.size	mthca_cleanup_eq_table, .-mthca_cleanup_eq_table
	.comm	MTHCA_NUM_EQ,4,4
	.comm	MTHCA_EQ_CMD,4,4
	.comm	MTHCA_EQ_ASYNC,4,4
	.comm	MTHCA_CMD_EVENT_MASK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
