	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cgx_lmac_verify_fwi_version
_cgx_lmac_verify_fwi_version:           ## @cgx_lmac_verify_fwi_version
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%eax, %eax
	cmpl	$0, (%rdi)
	je	LBB0_5
## %bb.1:
	movq	%rdi, %rsi
	movq	8(%rdi), %r14
	leaq	-28(%rbp), %rdi
	callq	_cgx_fwi_read_version
	testl	%eax, %eax
	jne	LBB0_5
## %bb.2:
	movq	_RESP_MAJOR_VER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	-28(%rbp), %esi
	callq	_FIELD_GET
	movl	%eax, %ebx
	movq	_RESP_MINOR_VER@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	-28(%rbp), %esi
	callq	_FIELD_GET
	movl	%eax, %r15d
	leaq	L_.str(%rip), %rsi
	movq	%r14, %rdi
	movl	%ebx, %edx
	movl	%eax, %ecx
	callq	_dev_dbg
	movq	_CGX_FIRMWARE_MAJOR_VER@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jne	LBB0_4
## %bb.3:
	movq	_CGX_FIRMWARE_MINOR_VER@GOTPCREL(%rip), %rcx
	movl	$0, %eax
	cmpl	(%rcx), %r15d
	je	LBB0_5
LBB0_4:
	movq	_EIO@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
LBB0_5:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_RESP_MAJOR_VER,4,2             ## @RESP_MAJOR_VER
	.comm	_RESP_MINOR_VER,4,2             ## @RESP_MINOR_VER
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Firmware command interface version = %d.%d\n"

	.comm	_CGX_FIRMWARE_MAJOR_VER,4,2     ## @CGX_FIRMWARE_MAJOR_VER
	.comm	_CGX_FIRMWARE_MINOR_VER,4,2     ## @CGX_FIRMWARE_MINOR_VER
	.comm	_EIO,4,2                        ## @EIO
	.no_dead_strip	_cgx_lmac_verify_fwi_version
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cgx_lmac_verify_fwi_version
_cgx_lmac_verify_fwi_version:           ; @cgx_lmac_verify_fwi_version
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	ldr	w8, [x0]
	cbz	w8, LBB0_4
; %bb.1:
	mov	x1, x0
	ldr	x19, [x0, #8]
	add	x0, sp, #12
	bl	_cgx_fwi_read_version
	cbnz	w0, LBB0_5
; %bb.2:
Lloh0:
	adrp	x8, _RESP_MAJOR_VER@GOTPAGE
Lloh1:
	ldr	x8, [x8, _RESP_MAJOR_VER@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	ldr	w1, [sp, #12]
	bl	_FIELD_GET
	mov	x20, x0
Lloh3:
	adrp	x8, _RESP_MINOR_VER@GOTPAGE
Lloh4:
	ldr	x8, [x8, _RESP_MINOR_VER@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	ldr	w1, [sp, #12]
	bl	_FIELD_GET
	mov	x21, x0
Lloh6:
	adrp	x1, l_.str@PAGE
Lloh7:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	mov	x2, x20
	mov	x3, x21
	bl	_dev_dbg
Lloh8:
	adrp	x8, _CGX_FIRMWARE_MAJOR_VER@GOTPAGE
Lloh9:
	ldr	x8, [x8, _CGX_FIRMWARE_MAJOR_VER@GOTPAGEOFF]
Lloh10:
	ldr	w8, [x8]
Lloh11:
	adrp	x9, _CGX_FIRMWARE_MINOR_VER@GOTPAGE
Lloh12:
	ldr	x9, [x9, _CGX_FIRMWARE_MINOR_VER@GOTPAGEOFF]
Lloh13:
	ldr	w9, [x9]
	cmp	w20, w8
	ccmp	w21, w9, #0, eq
	b.eq	LBB0_4
; %bb.3:
Lloh14:
	adrp	x8, _EIO@GOTPAGE
Lloh15:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
Lloh16:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_5
LBB0_4:
	mov	w0, #0
LBB0_5:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #64
	ret
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.cfi_endproc
                                        ; -- End function
	.comm	_RESP_MAJOR_VER,4,2             ; @RESP_MAJOR_VER
	.comm	_RESP_MINOR_VER,4,2             ; @RESP_MINOR_VER
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Firmware command interface version = %d.%d\n"

	.comm	_CGX_FIRMWARE_MAJOR_VER,4,2     ; @CGX_FIRMWARE_MAJOR_VER
	.comm	_CGX_FIRMWARE_MINOR_VER,4,2     ; @CGX_FIRMWARE_MINOR_VER
	.comm	_EIO,4,2                        ; @EIO
	.no_dead_strip	_cgx_lmac_verify_fwi_version
.subsections_via_symbols
