	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qlcnic_check_flash_fw_ver      ## -- Begin function qlcnic_check_flash_fw_ver
	.p2align	4, 0x90
_qlcnic_check_flash_fw_ver:             ## @qlcnic_check_flash_fw_ver
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	$-1, -48(%rbp)
	movq	8(%rdi), %rax
	movq	(%rax), %rax
	movq	_QLCNIC_P3P_C0@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_1
## %bb.2:
	movq	_QLCNIC_C0_FW_IMAGE_REGION@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_1:
	movq	_QLCNIC_B0_FW_IMAGE_REGION@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %esi
	leaq	-72(%rbp), %rdx
	movq	%r14, %rdi
	callq	_qlcnic_get_flt_entry
	testl	%eax, %eax
	je	LBB0_4
## %bb.5:
	movq	_QLCNIC_FW_VERSION_OFFSET@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	jmp	LBB0_6
LBB0_4:
	movq	-72(%rbp), %rsi
	addq	$4, %rsi
LBB0_6:
	leaq	-48(%rbp), %rdx
	movq	%r14, %rdi
	callq	_qlcnic_rom_fast_read
	movq	-48(%rbp), %rdi
	callq	_QLCNIC_DECODE_VERSION
	movq	%rax, -48(%rbp)
	movq	_QLCNIC_MIN_FW_VERSION@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rbx
	xorl	%ecx, %ecx
	cmpq	%rbx, %rax
	jge	LBB0_8
## %bb.7:
	movq	(%r14), %rcx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movq	%rax, %rdi
	callq	__major
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	-48(%rbp), %rdi
	callq	__minor
	movl	%eax, %r12d
	movq	-48(%rbp), %rdi
	callq	__build
	movl	%eax, %r13d
	movq	%rbx, %rdi
	callq	__major
	movl	%eax, %r14d
	movq	%rbx, %rdi
	callq	__minor
	movl	%eax, %r15d
	movq	%rbx, %rdi
	callq	__build
                                        ## kill: def $eax killed $eax def $rax
	leaq	L_.str(%rip), %rsi
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	movl	%r12d, %ecx
	movl	%r13d, %r8d
	movl	%r14d, %r9d
	pushq	%rax
	pushq	%r15
	callq	_dev_err
	addq	$16, %rsp
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ecx, %ecx
	subl	(%rax), %ecx
LBB0_8:
	movl	%ecx, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_QLCNIC_P3P_C0,8,3              ## @QLCNIC_P3P_C0
	.comm	_QLCNIC_C0_FW_IMAGE_REGION,4,2  ## @QLCNIC_C0_FW_IMAGE_REGION
	.comm	_QLCNIC_B0_FW_IMAGE_REGION,4,2  ## @QLCNIC_B0_FW_IMAGE_REGION
	.comm	_QLCNIC_FW_VERSION_OFFSET,8,3   ## @QLCNIC_FW_VERSION_OFFSET
	.comm	_QLCNIC_MIN_FW_VERSION,8,3      ## @QLCNIC_MIN_FW_VERSION
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"firmware version %d.%d.%d unsupported.Min supported version %d.%d.%d\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_qlcnic_check_flash_fw_ver      ; -- Begin function qlcnic_check_flash_fw_ver
	.p2align	2
_qlcnic_check_flash_fw_ver:             ; @qlcnic_check_flash_fw_ver
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x19, x0
	mov	x8, #-1
	str	x8, [sp]
	ldr	x8, [x0, #8]
	ldr	x8, [x8]
Lloh0:
	adrp	x9, _QLCNIC_P3P_C0@GOTPAGE
Lloh1:
	ldr	x9, [x9, _QLCNIC_P3P_C0@GOTPAGEOFF]
Lloh2:
	adrp	x10, _QLCNIC_C0_FW_IMAGE_REGION@GOTPAGE
Lloh3:
	ldr	x10, [x10, _QLCNIC_C0_FW_IMAGE_REGION@GOTPAGEOFF]
Lloh4:
	ldr	x9, [x9]
Lloh5:
	adrp	x11, _QLCNIC_B0_FW_IMAGE_REGION@GOTPAGE
Lloh6:
	ldr	x11, [x11, _QLCNIC_B0_FW_IMAGE_REGION@GOTPAGEOFF]
	cmp	x8, x9
	csel	x8, x10, x11, eq
	ldr	w1, [x8]
	add	x2, sp, #8
	bl	_qlcnic_get_flt_entry
Lloh7:
	adrp	x8, _QLCNIC_FW_VERSION_OFFSET@GOTPAGE
Lloh8:
	ldr	x8, [x8, _QLCNIC_FW_VERSION_OFFSET@GOTPAGEOFF]
Lloh9:
	ldr	x8, [x8]
	ldr	x9, [sp, #8]
	add	x9, x9, #4
	cmp	w0, #0
	csel	x1, x9, x8, eq
	mov	x2, sp
	mov	x0, x19
	bl	_qlcnic_rom_fast_read
	ldr	x0, [sp]
	bl	_QLCNIC_DECODE_VERSION
	str	x0, [sp]
Lloh10:
	adrp	x8, _QLCNIC_MIN_FW_VERSION@GOTPAGE
Lloh11:
	ldr	x8, [x8, _QLCNIC_MIN_FW_VERSION@GOTPAGEOFF]
Lloh12:
	ldr	x20, [x8]
	cmp	x0, x20
	b.ge	LBB0_2
; %bb.1:
	ldr	x19, [x19]
	bl	__major
	mov	x21, x0
	ldr	x0, [sp]
	bl	__minor
	mov	x22, x0
	ldr	x0, [sp]
	bl	__build
	mov	x23, x0
	mov	x0, x20
	bl	__major
	mov	x24, x0
	mov	x0, x20
	bl	__minor
	mov	x25, x0
	mov	x0, x20
	bl	__build
	mov	x7, x0
Lloh13:
	adrp	x1, l_.str@PAGE
Lloh14:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x21
	mov	x3, x22
	mov	x4, x23
	mov	x5, x24
	mov	x6, x25
	bl	_dev_err
Lloh15:
	adrp	x8, _EINVAL@GOTPAGE
Lloh16:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh17:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_3
LBB0_2:
	mov	w0, #0
LBB0_3:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh4
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh13, Lloh14
	.cfi_endproc
                                        ; -- End function
	.comm	_QLCNIC_P3P_C0,8,3              ; @QLCNIC_P3P_C0
	.comm	_QLCNIC_C0_FW_IMAGE_REGION,4,2  ; @QLCNIC_C0_FW_IMAGE_REGION
	.comm	_QLCNIC_B0_FW_IMAGE_REGION,4,2  ; @QLCNIC_B0_FW_IMAGE_REGION
	.comm	_QLCNIC_FW_VERSION_OFFSET,8,3   ; @QLCNIC_FW_VERSION_OFFSET
	.comm	_QLCNIC_MIN_FW_VERSION,8,3      ; @QLCNIC_MIN_FW_VERSION
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"firmware version %d.%d.%d unsupported.Min supported version %d.%d.%d\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
.subsections_via_symbols
