	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bfa_nw_flash_update_part       ## -- Begin function bfa_nw_flash_update_part
	.p2align	4, 0x90
_bfa_nw_flash_update_part:              ## @bfa_nw_flash_update_part
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r9d, -44(%rbp)                 ## 4-byte Spill
	movl	%r8d, %r12d
	movq	%rcx, %r15
	movl	%edx, %r13d
	movl	%esi, %r14d
	movq	%rdi, %rbx
	movl	52(%rdi), %edi
	callq	_bfa_nw_ioc_is_operational
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movq	_BFA_STATUS_FLASH_BAD_LEN@GOTPCREL(%rip), %rax
	testl	%r12d, %r12d
	je	LBB0_9
## %bb.3:
	movl	%r12d, %ecx
	andl	$3, %ecx
	jne	LBB0_9
## %bb.4:
	movq	_BFA_FLASH_PART_MFG@GOTPCREL(%rip), %rax
	cmpl	%r14d, (%rax)
	jne	LBB0_6
## %bb.5:
	movq	_BFA_STATUS_EINVAL@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_1:
	movq	_BFA_STATUS_IOC_NON_OP@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_6:
	cmpl	$0, (%rbx)
	je	LBB0_8
## %bb.7:
	movq	_BFA_STATUS_DEVBUSY@GOTPCREL(%rip), %rax
	jmp	LBB0_9
LBB0_8:
	movq	24(%rbp), %rax
	movl	16(%rbp), %ecx
	movl	$1, (%rbx)
	movl	%ecx, 48(%rbx)
	movq	%rax, 40(%rbx)
	movl	%r14d, 4(%rbx)
	movl	%r13d, 32(%rbx)
	movl	%r12d, 8(%rbx)
	movq	$0, 24(%rbx)
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, 12(%rbx)
	movq	%r15, 16(%rbx)
	movq	%rbx, %rdi
	callq	_bfa_flash_write_send
	movq	_BFA_STATUS_OK@GOTPCREL(%rip), %rax
LBB0_9:
	movl	(%rax), %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_BFA_STATUS_IOC_NON_OP,4,2      ## @BFA_STATUS_IOC_NON_OP
	.comm	_BFA_STATUS_FLASH_BAD_LEN,4,2   ## @BFA_STATUS_FLASH_BAD_LEN
	.comm	_BFA_FLASH_PART_MFG,4,2         ## @BFA_FLASH_PART_MFG
	.comm	_BFA_STATUS_EINVAL,4,2          ## @BFA_STATUS_EINVAL
	.comm	_BFA_STATUS_DEVBUSY,4,2         ## @BFA_STATUS_DEVBUSY
	.comm	_BFA_STATUS_OK,4,2              ## @BFA_STATUS_OK
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bfa_nw_flash_update_part       ; -- Begin function bfa_nw_flash_update_part
	.p2align	2
_bfa_nw_flash_update_part:              ; @bfa_nw_flash_update_part
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	mov	x23, x7
	mov	x24, x6
	mov	x19, x5
	mov	x22, x4
	mov	x20, x3
	mov	x25, x2
	mov	x26, x1
	mov	x21, x0
	ldr	w0, [x0, #52]
	bl	_bfa_nw_ioc_is_operational
	cbz	w0, LBB0_5
; %bb.1:
Lloh0:
	adrp	x8, _BFA_STATUS_FLASH_BAD_LEN@GOTPAGE
Lloh1:
	ldr	x8, [x8, _BFA_STATUS_FLASH_BAD_LEN@GOTPAGEOFF]
	cbz	w22, LBB0_9
; %bb.2:
	and	w9, w22, #0x3
	cbnz	w9, LBB0_9
; %bb.3:
Lloh2:
	adrp	x8, _BFA_FLASH_PART_MFG@GOTPAGE
Lloh3:
	ldr	x8, [x8, _BFA_FLASH_PART_MFG@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	cmp	w8, w26
	b.ne	LBB0_6
; %bb.4:
Lloh5:
	adrp	x8, _BFA_STATUS_EINVAL@GOTPAGE
Lloh6:
	ldr	x8, [x8, _BFA_STATUS_EINVAL@GOTPAGEOFF]
	b	LBB0_9
LBB0_5:
Lloh7:
	adrp	x8, _BFA_STATUS_IOC_NON_OP@GOTPAGE
Lloh8:
	ldr	x8, [x8, _BFA_STATUS_IOC_NON_OP@GOTPAGEOFF]
	b	LBB0_9
LBB0_6:
	ldr	w8, [x21]
	cbz	w8, LBB0_8
; %bb.7:
Lloh9:
	adrp	x8, _BFA_STATUS_DEVBUSY@GOTPAGE
Lloh10:
	ldr	x8, [x8, _BFA_STATUS_DEVBUSY@GOTPAGEOFF]
	b	LBB0_9
LBB0_8:
	mov	w8, #1
	str	w24, [x21, #48]
	str	x23, [x21, #40]
	stp	w8, w26, [x21]
	str	w25, [x21, #32]
	stp	w22, w19, [x21, #8]
	stp	x20, xzr, [x21, #16]
	mov	x0, x21
	bl	_bfa_flash_write_send
Lloh11:
	adrp	x8, _BFA_STATUS_OK@GOTPAGE
Lloh12:
	ldr	x8, [x8, _BFA_STATUS_OK@GOTPAGEOFF]
LBB0_9:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_BFA_STATUS_IOC_NON_OP,4,2      ; @BFA_STATUS_IOC_NON_OP
	.comm	_BFA_STATUS_FLASH_BAD_LEN,4,2   ; @BFA_STATUS_FLASH_BAD_LEN
	.comm	_BFA_FLASH_PART_MFG,4,2         ; @BFA_FLASH_PART_MFG
	.comm	_BFA_STATUS_EINVAL,4,2          ; @BFA_STATUS_EINVAL
	.comm	_BFA_STATUS_DEVBUSY,4,2         ; @BFA_STATUS_DEVBUSY
	.comm	_BFA_STATUS_OK,4,2              ; @BFA_STATUS_OK
.subsections_via_symbols
