	.file	"extr_bfad_bsg.c_bfad_iocmd_flash_read_part.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.globl	bfad_iocmd_flash_read_part
	.type	bfad_iocmd_flash_read_part, @function
bfad_iocmd_flash_read_part:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rdi
	mov	edi, edx
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	rbx, rsi
	sub	rsp, 56
	.cfi_def_cfa_offset 112
	mov	edx, DWORD PTR 8[rsi]
	mov	esi, 24
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 40[rsp], rax
	xor	eax, eax
	call	bfad_chk_iocmd_sz@PLT
	cmp	rax, QWORD PTR BFA_STATUS_OK[rip]
	je	.L2
	mov	rax, QWORD PTR BFA_STATUS_VERSION_FAIL[rip]
	mov	QWORD PTR [rbx], rax
.L3:
	mov	rax, QWORD PTR 40[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L7
	add	rsp, 56
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xor	eax, eax
	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
.L2:
	.cfi_restore_state
	lea	r13, 24[rsp]
	lea	r9, 16[rsp]
	xor	r12d, r12d
	mov	rdi, r13
	mov	QWORD PTR 8[rsp], r9
	call	init_completion@PLT
	mov	rsi, r12
	mov	rdi, rbp
	call	spin_lock_irqsave@PLT
	mov	edx, DWORD PTR bfad_hcb_comp[rip]
	mov	r8d, DWORD PTR 8[rbx]
	lea	rdi, 4[rbp]
	mov	r15d, DWORD PTR 12[rbx]
	mov	r14d, DWORD PTR 16[rbx]
	mov	DWORD PTR 4[rsp], edx
	mov	DWORD PTR [rsp], r8d
	call	BFA_FLASH@PLT
	mov	r9, QWORD PTR 8[rsp]
	lea	rcx, 24[rbx]
	mov	esi, r14d
	mov	edi, eax
	push	r9
	.cfi_def_cfa_offset 120
	mov	edx, DWORD PTR 12[rsp]
	xor	r9d, r9d
	push	rdx
	.cfi_def_cfa_offset 128
	mov	r8d, DWORD PTR 16[rsp]
	mov	edx, r15d
	call	bfa_flash_read_part@PLT
	mov	rsi, r12
	mov	rdi, rbp
	mov	QWORD PTR [rbx], rax
	call	spin_unlock_irqrestore@PLT
	pop	rax
	.cfi_def_cfa_offset 120
	mov	rax, QWORD PTR BFA_STATUS_OK[rip]
	pop	rdx
	.cfi_def_cfa_offset 112
	cmp	QWORD PTR [rbx], rax
	jne	.L3
	mov	rdi, r13
	call	wait_for_completion@PLT
	mov	rax, QWORD PTR 16[rsp]
	mov	QWORD PTR [rbx], rax
	jmp	.L3
.L7:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	bfad_iocmd_flash_read_part, .-bfad_iocmd_flash_read_part
	.comm	bfad_hcb_comp,4,4
	.comm	BFA_STATUS_VERSION_FAIL,8,8
	.comm	BFA_STATUS_OK,8,8
	.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_bfad_bsg.c_bfad_iocmd_flash_read_part.c"
	.text
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC0:
	.word	__stack_chk_guard
	.text
	.align	2
	.global	bfad_iocmd_flash_read_part
	.syntax unified
	.arm
	.fpu softvfp
	.type	bfad_iocmd_flash_read_part, %function
bfad_iocmd_flash_read_part:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	mov	ip, r2
	push	{r4, r5, r6, r7, lr}
	ldr	r3, .L8
	ldr	r2, [r1, #4]
	sub	sp, sp, #36
	mov	r4, r1
	mov	r6, r0
	mov	r1, #16
	mov	r0, ip
	ldr	r3, [r3]
	str	r3, [sp, #28]
	mov	r3,#0
	bl	bfad_chk_iocmd_sz
	ldr	r5, .L8+4
	ldr	r3, [r5]
	cmp	r0, r3
	beq	.L2
	ldr	r3, .L8+8
	ldr	r3, [r3]
	str	r3, [r4]
.L3:
	ldr	r3, .L8
	ldr	r2, [r3]
	ldr	r3, [sp, #28]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L7
	mov	r0, #0
	add	sp, sp, #36
	@ sp needed
	pop	{r4, r5, r6, r7, pc}
.L2:
	mov	r7, #0
	add	r0, sp, #24
	bl	init_completion
	mov	r1, r7
	mov	r0, r6
	bl	spin_lock_irqsave
	add	r0, r6, #4
	bl	BFA_FLASH
	mov	r1, r7
	ldr	r3, .L8+12
	ldr	r2, [r4, #4]
	ldr	ip, [r3]
	add	r3, sp, #20
	stmib	sp, {r1, ip}
	str	r3, [sp, #12]
	str	r2, [sp]
	ldr	r2, [r4, #8]
	add	r3, r4, #16
	ldr	r1, [r4, #12]
	bl	bfa_flash_read_part
	mov	r1, r7
	str	r0, [r4]
	mov	r0, r6
	bl	spin_unlock_irqrestore
	ldr	r3, [r5]
	ldr	r2, [r4]
	cmp	r2, r3
	bne	.L3
	add	r0, sp, #24
	bl	wait_for_completion
	ldr	r3, [sp, #20]
	str	r3, [r4]
	b	.L3
.L7:
	bl	__stack_chk_fail
.L9:
	.align	2
.L8:
	.word	.LC0
	.word	BFA_STATUS_OK
	.word	BFA_STATUS_VERSION_FAIL
	.word	bfad_hcb_comp
	.size	bfad_iocmd_flash_read_part, .-bfad_iocmd_flash_read_part
	.comm	bfad_hcb_comp,4,4
	.comm	BFA_STATUS_VERSION_FAIL,4,4
	.comm	BFA_STATUS_OK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
