	.file	"extr_ah.c_rvt_create_ah.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	rvt_create_ah
	.type	rvt_create_ah, @function
rvt_create_ah:
.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
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	mov	r12, rsi
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	mov	rbx, rdi
	call	ibah_to_rvtah@PLT
	mov	edi, DWORD PTR [rbx]
	mov	r13, rax
	call	ib_to_rvt@PLT
	mov	edi, DWORD PTR [rbx]
	mov	rsi, r12
	mov	rbp, rax
	call	rvt_check_ah@PLT
	test	rax, rax
	je	.L2
	mov	r14d, DWORD PTR EINVAL[rip]
	neg	r14d
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r14d
	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
.L2:
	.cfi_restore_state
	lea	r14, 16[rbp]
	xor	esi, esi
	mov	rdi, r14
	call	spin_lock_irqsave@PLT
	mov	rax, QWORD PTR 0[rbp]
	cmp	rax, QWORD PTR 24[rbp]
	je	.L9
	add	rax, 1
	mov	rdi, r14
	xor	esi, esi
	xor	r14d, r14d
	mov	QWORD PTR 0[rbp], rax
	call	spin_unlock_irqrestore@PLT
	mov	rsi, r12
	mov	rdi, r13
	call	rdma_copy_ah_attr@PLT
	mov	rax, QWORD PTR 8[rbp]
	test	rax, rax
	je	.L1
	mov	edi, DWORD PTR [rbx]
	mov	rdx, r13
	mov	rsi, r12
	call	rax
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r14d
	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
.L9:
	.cfi_restore_state
	mov	rdi, r14
	xor	esi, esi
	call	spin_unlock_irqrestore@PLT
	mov	r14d, DWORD PTR ENOMEM[rip]
	pop	rbx
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	neg	r14d
	pop	r13
	.cfi_def_cfa_offset 16
	mov	eax, r14d
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	rvt_create_ah, .-rvt_create_ah
	.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_ah.c_rvt_create_ah.c"
	.text
	.align	2
	.global	rvt_create_ah
	.syntax unified
	.arm
	.fpu softvfp
	.type	rvt_create_ah, %function
rvt_create_ah:
	@ 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
	mov	r7, r1
	bl	ibah_to_rvtah
	mov	r8, r0
	ldr	r0, [r5]
	bl	ib_to_rvt
	mov	r1, r7
	mov	r6, r0
	ldr	r0, [r5]
	bl	rvt_check_ah
	subs	r4, r0, #0
	beq	.L2
	ldr	r3, .L11
	ldr	r0, [r3]
	rsb	r4, r0, #0
.L1:
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L2:
	add	r9, r6, #8
	mov	r0, r9
	mov	r1, #0
	bl	spin_lock_irqsave
	ldr	r3, [r6]
	ldr	r2, [r6, #12]
	cmp	r3, r2
	beq	.L10
	add	r3, r3, #1
	str	r3, [r6]
	mov	r1, #0
	mov	r0, r9
	bl	spin_unlock_irqrestore
	mov	r1, r7
	mov	r0, r8
	bl	rdma_copy_ah_attr
	ldr	r3, [r6, #4]
	cmp	r3, #0
	beq	.L1
	mov	r2, r8
	mov	r1, r7
	ldr	r0, [r5]
	blx	r3
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L10:
	mov	r0, r9
	mov	r1, #0
	bl	spin_unlock_irqrestore
	ldr	r3, .L11+4
	ldr	r0, [r3]
	rsb	r4, r0, #0
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L12:
	.align	2
.L11:
	.word	EINVAL
	.word	ENOMEM
	.size	rvt_create_ah, .-rvt_create_ah
	.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
