	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_carl9170_parse_firmware        ## -- Begin function carl9170_parse_firmware
	.p2align	4, 0x90
_carl9170_parse_firmware:               ## @carl9170_parse_firmware
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movq	16(%rdi), %r12
	xorl	%edi, %edi
	testq	%r12, %r12
	sete	%dil
	callq	_WARN_ON
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	jmp	LBB0_10
LBB0_2:
	movq	(%r12), %rdx
	movq	8(%r12), %rsi
	movq	%r14, %rdi
	callq	_carl9170_find_fw_desc
	testq	%rax, %rax
	je	LBB0_3
## %bb.4:
	movq	%rax, %r15
	movq	8(%r12), %rdx
	subq	%rax, %rdx
	addq	(%r12), %rdx
	movq	%r14, %rdi
	movq	%rax, %rsi
	callq	_carl9170_fw_verify_descs
	testl	%eax, %eax
	je	LBB0_6
## %bb.5:
	movl	%eax, %ebx
	movq	(%r14), %rdi
	leaq	L_.str.1(%rip), %rsi
	jmp	LBB0_9
LBB0_3:
	movq	(%r14), %rdi
	leaq	L_.str(%rip), %rsi
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ENODATA@GOTPCREL(%rip), %rax
	subl	(%rax), %ebx
	jmp	LBB0_10
LBB0_6:
	movq	%r15, 8(%r14)
	movq	%r14, %rdi
	callq	_carl9170_fw_info
	movq	(%r12), %rdx
	movq	8(%r12), %rsi
	movq	%r14, %rdi
	callq	_carl9170_fw
	testl	%eax, %eax
	je	LBB0_7
## %bb.8:
	movl	%eax, %ebx
	movq	(%r14), %rdi
	leaq	L_.str.2(%rip), %rsi
LBB0_9:
	movl	%ebx, %edx
	xorl	%eax, %eax
	callq	_dev_err
LBB0_10:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_7:
	xorl	%ebx, %ebx
	jmp	LBB0_10
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unsupported firmware.\n"

	.comm	_ENODATA,4,2                    ## @ENODATA
L_.str.1:                               ## @.str.1
	.asciz	"damaged firmware (%d).\n"

L_.str.2:                               ## @.str.2
	.asciz	"failed to parse firmware (%d).\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_carl9170_parse_firmware        ; -- Begin function carl9170_parse_firmware
	.p2align	2
_carl9170_parse_firmware:               ; @carl9170_parse_firmware
	.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
	mov	x19, x0
	ldr	x22, [x0, #16]
	cmp	x22, #0
	cset	w0, eq
	bl	_WARN_ON
	cbz	x0, LBB0_4
; %bb.1:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
LBB0_2:
	ldr	w8, [x8]
	neg	w20, w8
LBB0_3:
	mov	x0, x20
	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
LBB0_4:
	ldp	x2, x1, [x22]
	mov	x0, x19
	bl	_carl9170_find_fw_desc
	cbz	x0, LBB0_7
; %bb.5:
	mov	x21, x0
	ldp	x9, x8, [x22]
	sub	x8, x8, x0
	add	x2, x8, x9
	mov	x0, x19
	mov	x1, x21
	bl	_carl9170_fw_verify_descs
	cbz	w0, LBB0_8
; %bb.6:
	mov	x20, x0
	ldr	x0, [x19]
	str	x20, [sp]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_err
	b	LBB0_3
LBB0_7:
	ldr	x0, [x19]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
Lloh6:
	adrp	x8, _ENODATA@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENODATA@GOTPAGEOFF]
	b	LBB0_2
LBB0_8:
	str	x21, [x19, #8]
	mov	x0, x19
	bl	_carl9170_fw_info
	ldp	x2, x1, [x22]
	mov	x0, x19
	bl	_carl9170_fw
	mov	x20, x0
	cbz	w0, LBB0_3
; %bb.9:
	ldr	x0, [x19]
	str	x20, [sp]
Lloh8:
	adrp	x1, l_.str.2@PAGE
Lloh9:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_err
                                        ; kill: def $w20 killed $w20 killed $x20 def $x20
	b	LBB0_3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unsupported firmware.\n"

	.comm	_ENODATA,4,2                    ; @ENODATA
l_.str.1:                               ; @.str.1
	.asciz	"damaged firmware (%d).\n"

l_.str.2:                               ; @.str.2
	.asciz	"failed to parse firmware (%d).\n"

.subsections_via_symbols
