	.file	"extr_ocrdma_hw.c_ocrdma_mbx_modify_qp.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	ocrdma_mbx_modify_qp
	.type	ocrdma_mbx_modify_qp, @function
ocrdma_mbx_modify_qp:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	r15, rsi
	mov	esi, 12
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	mov	r14, rdi
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13d, ecx
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rdx
	sub	rsp, 8
	.cfi_def_cfa_offset 64
	mov	edi, DWORD PTR OCRDMA_CMD_MODIFY_QP[rip]
	mov	r12d, DWORD PTR ENOMEM[rip]
	call	ocrdma_init_emb_mqe@PLT
	neg	r12d
	test	rax, rax
	je	.L1
	mov	rbp, rax
	mov	eax, DWORD PTR 4[r15]
	mov	DWORD PTR 8[rbp], 0
	mov	DWORD PTR 4[rbp], eax
	test	DWORD PTR IB_QP_STATE[rip], r13d
	jne	.L9
	mov	ecx, DWORD PTR OCRDMA_QP_PARAMS_STATE_SHIFT[rip]
	mov	eax, DWORD PTR [r15]
	sal	eax, cl
	and	eax, DWORD PTR OCRDMA_QP_PARAMS_STATE_MASK[rip]
	or	DWORD PTR 0[rbp], eax
.L5:
	mov	ecx, r13d
	mov	rdx, rbx
	mov	rsi, rbp
	mov	rdi, r15
	call	ocrdma_set_qp_params@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L10
.L6:
	mov	rdi, rbp
	call	kfree@PLT
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r12d
	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
.L10:
	.cfi_restore_state
	mov	rsi, rbp
	mov	rdi, r14
	call	ocrdma_mbx_cmd@PLT
	mov	r12d, eax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L9:
	mov	edi, DWORD PTR [rbx]
	call	get_ocrdma_qp_state@PLT
	mov	ecx, DWORD PTR OCRDMA_QP_PARAMS_STATE_SHIFT[rip]
	sal	eax, cl
	and	eax, DWORD PTR OCRDMA_QP_PARAMS_STATE_MASK[rip]
	or	DWORD PTR 0[rbp], eax
	mov	eax, DWORD PTR OCRDMA_QP_PARA_QPS_VALID[rip]
	or	DWORD PTR 8[rbp], eax
	jmp	.L5
	.cfi_endproc
.LFE0:
	.size	ocrdma_mbx_modify_qp, .-ocrdma_mbx_modify_qp
	.comm	OCRDMA_QP_PARA_QPS_VALID,4,4
	.comm	OCRDMA_QP_PARAMS_STATE_SHIFT,4,4
	.comm	OCRDMA_QP_PARAMS_STATE_MASK,4,4
	.comm	OCRDMA_CMD_MODIFY_QP,4,4
	.comm	IB_QP_STATE,4,4
	.comm	ENOMEM,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_ocrdma_hw.c_ocrdma_mbx_modify_qp.c"
	.text
	.align	2
	.global	ocrdma_mbx_modify_qp
	.syntax unified
	.arm
	.fpu softvfp
	.type	ocrdma_mbx_modify_qp, %function
ocrdma_mbx_modify_qp:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r6, r1
	ldr	r1, .L11
	ldr	ip, .L11+4
	mov	r9, r0
	ldr	r0, [r1]
	mov	r1, #12
	ldr	r5, [ip]
	mov	r8, r2
	mov	r7, r3
	bl	ocrdma_init_emb_mqe
	subs	r4, r0, #0
	rsbeq	r5, r5, #0
	beq	.L1
	mov	r1, #0
	ldr	r2, .L11+8
	ldr	r3, [r6, #4]
	ldr	r2, [r2]
	str	r1, [r4, #8]
	tst	r7, r2
	str	r3, [r4, #4]
	bne	.L9
	ldr	r2, .L11+12
	ldr	r3, .L11+16
	ldr	r1, [r2]
	ldr	r0, [r6]
	ldr	r2, [r3]
	ldr	r3, [r4]
	and	r2, r2, r0, lsl r1
	orr	r3, r3, r2
	str	r3, [r4]
.L5:
	mov	r3, r7
	mov	r2, r8
	mov	r0, r6
	mov	r1, r4
	bl	ocrdma_set_qp_params
	subs	r5, r0, #0
	beq	.L10
.L6:
	mov	r0, r4
	bl	kfree
.L1:
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L10:
	mov	r0, r9
	mov	r1, r4
	bl	ocrdma_mbx_cmd
	mov	r5, r0
	b	.L6
.L9:
	ldr	r0, [r8]
	bl	get_ocrdma_qp_state
	ldr	r3, .L11+12
	ldr	r2, .L11+16
	ldr	r3, [r3]
	ldr	r2, [r2]
	ldr	r1, .L11+20
	and	r2, r2, r0, lsl r3
	ldr	r1, [r1]
	ldr	r0, [r4]
	ldr	r3, [r4, #8]
	orr	r0, r0, r2
	orr	r3, r3, r1
	str	r0, [r4]
	str	r3, [r4, #8]
	b	.L5
.L12:
	.align	2
.L11:
	.word	OCRDMA_CMD_MODIFY_QP
	.word	ENOMEM
	.word	IB_QP_STATE
	.word	OCRDMA_QP_PARAMS_STATE_SHIFT
	.word	OCRDMA_QP_PARAMS_STATE_MASK
	.word	OCRDMA_QP_PARA_QPS_VALID
	.size	ocrdma_mbx_modify_qp, .-ocrdma_mbx_modify_qp
	.comm	OCRDMA_QP_PARA_QPS_VALID,4,4
	.comm	OCRDMA_QP_PARAMS_STATE_SHIFT,4,4
	.comm	OCRDMA_QP_PARAMS_STATE_MASK,4,4
	.comm	OCRDMA_CMD_MODIFY_QP,4,4
	.comm	IB_QP_STATE,4,4
	.comm	ENOMEM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
