	.file	"extr_mpr_user.c_mpi_pre_fw_download.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	mpi_pre_fw_download, @function
mpi_pre_fw_download:
.LFB0:
	.cfi_startproc
	endbr64
	cmp	DWORD PTR [rsi], 40
	je	.L2
	mov	eax, DWORD PTR EINVAL[rip]
	ret
	.p2align 4,,10
	.p2align 3
.L2:
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	mov	rbx, rsi
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	cmp	DWORD PTR 4[rsi], 4
	je	.L14
.L6:
	mov	eax, DWORD PTR EINVAL[rip]
.L1:
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L14:
	.cfi_restore_state
	mov	rdx, QWORD PTR 8[rsi]
	test	rdx, rdx
	je	.L6
	mov	r12, QWORD PTR 8[rdi]
	mov	esi, DWORD PTR 4[rdi]
	mov	rbp, rdi
	mov	edi, DWORD PTR 16[rbx]
	call	copyin@PLT
	test	eax, eax
	jne	.L1
	lea	r13, 24[r12]
	mov	rsi, r12
	mov	rdi, rbp
	mov	rdx, r13
	call	mpr_init_sge@PLT
	mov	eax, DWORD PTR [r12]
	test	DWORD PTR MPI2_FW_DOWNLOAD_MSGFLGS_LAST_SEGMENT[rip], eax
	je	.L6
	mov	rax, QWORD PTR 8[rbx]
	cmp	QWORD PTR 8[r12], rax
	jne	.L6
	mov	QWORD PTR 16[r12], rax
	mov	eax, DWORD PTR MPR_CM_FLAGS_DATAOUT[rip]
	mov	rsi, r13
	xor	edx, edx
	mov	QWORD PTR 32[r12], 0
	mov	rdi, rbp
	or	DWORD PTR 0[rbp], eax
	add	rsp, 8
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_restore 3
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_restore 6
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_restore 12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_restore 13
	.cfi_def_cfa_offset 8
	jmp	mpr_push_ieee_sge@PLT
	.cfi_endproc
.LFE0:
	.size	mpi_pre_fw_download, .-mpi_pre_fw_download
	.comm	MPR_CM_FLAGS_DATAOUT,4,4
	.comm	MPI2_FW_DOWNLOAD_MSGFLGS_LAST_SEGMENT,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_mpr_user.c_mpi_pre_fw_download.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	mpi_pre_fw_download, %function
mpi_pre_fw_download:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, [r1]
	push	{r4, r5, r6, r7, r8, lr}
	cmp	r3, #20
	bne	.L6
	ldr	r3, [r1, #4]
	mov	r4, r1
	cmp	r3, #4
	beq	.L12
.L6:
	ldr	r3, .L13
	ldr	r5, [r3]
.L1:
	mov	r0, r5
	pop	{r4, r5, r6, r7, r8, pc}
.L12:
	ldr	r2, [r1, #8]
	cmp	r2, #0
	beq	.L6
	mov	r6, r0
	ldr	r1, [r0, #4]
	ldr	r0, [r4, #12]
	ldr	r7, [r6, #8]
	bl	copyin
	subs	r5, r0, #0
	bne	.L1
	add	r8, r7, #12
	mov	r2, r8
	mov	r1, r7
	mov	r0, r6
	bl	mpr_init_sge
	ldr	r3, .L13+4
	ldr	r2, [r7]
	ldr	r3, [r3]
	tst	r2, r3
	beq	.L6
	ldr	r2, [r4, #8]
	ldr	r3, [r7, #4]
	cmp	r3, r2
	bne	.L6
	ldr	r2, .L13+8
	str	r5, [r7, #16]
	ldr	r1, [r2]
	ldr	r2, [r6]
	str	r3, [r7, #8]
	orr	r3, r2, r1
	mov	r0, r6
	mov	r2, r5
	mov	r1, r8
	str	r3, [r6]
	pop	{r4, r5, r6, r7, r8, lr}
	b	mpr_push_ieee_sge
.L14:
	.align	2
.L13:
	.word	EINVAL
	.word	MPI2_FW_DOWNLOAD_MSGFLGS_LAST_SEGMENT
	.word	MPR_CM_FLAGS_DATAOUT
	.size	mpi_pre_fw_download, .-mpi_pre_fw_download
	.comm	MPR_CM_FLAGS_DATAOUT,4,4
	.comm	MPI2_FW_DOWNLOAD_MSGFLGS_LAST_SEGMENT,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
