	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function symbol_dl_firmware
_symbol_dl_firmware:                    ## @symbol_dl_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
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %rbx
	movq	(%rdi), %r14
	movl	$1, %esi
	callq	_orinoco_cached_fw_get
	testq	%rax, %rax
	je	LBB0_1
## %bb.5:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_orinoco_cached_fw_get
	movq	%rax, -40(%rbp)
LBB0_6:
	movq	8(%rax), %rdx
	movq	(%rax), %rcx
	addq	%rdx, %rcx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	xorl	%r8d, %r8d
	callq	_symbol_dl_image
	movl	%eax, %r12d
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_orinoco_cached_fw_get
	testq	%rax, %rax
	je	LBB0_7
## %bb.8:
	testl	%r12d, %r12d
	je	LBB0_10
LBB0_9:
	leaq	L_.str.1(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_19
LBB0_1:
	movl	4(%r15), %esi
	movq	(%rbx), %rdx
	leaq	-40(%rbp), %rdi
	callq	_request_firmware
	testq	%rax, %rax
	je	LBB0_2
## %bb.3:
	movl	4(%r15), %edx
	jmp	LBB0_4
LBB0_7:
	movq	-40(%rbp), %rdi
	callq	_release_firmware
	testl	%r12d, %r12d
	jne	LBB0_9
LBB0_10:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_orinoco_cached_fw_get
	testq	%rax, %rax
	je	LBB0_11
## %bb.14:
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_orinoco_cached_fw_get
	movq	%rax, -40(%rbp)
LBB0_15:
	movq	8(%rax), %rdx
	movq	(%rax), %rcx
	addq	%rdx, %rcx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	movl	$1, %r8d
	callq	_symbol_dl_image
	movl	%eax, %r15d
	xorl	%r12d, %r12d
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_orinoco_cached_fw_get
	testq	%rax, %rax
	jne	LBB0_17
## %bb.16:
	movq	-40(%rbp), %rdi
	callq	_release_firmware
LBB0_17:
	testl	%r15d, %r15d
	je	LBB0_19
## %bb.18:
	leaq	L_.str.2(%rip), %rsi
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	movl	%r15d, %r12d
	jmp	LBB0_19
LBB0_2:
	movq	-40(%rbp), %rax
	jmp	LBB0_6
LBB0_11:
	movl	(%r15), %esi
	movq	(%rbx), %rdx
	leaq	-40(%rbp), %rdi
	callq	_request_firmware
	testq	%rax, %rax
	je	LBB0_12
## %bb.13:
	movl	(%r15), %edx
LBB0_4:
	leaq	L_.str(%rip), %rsi
	xorl	%r12d, %r12d
	movq	%r14, %rdi
	xorl	%eax, %eax
	callq	_dev_err
	movq	_ENOENT@GOTPCREL(%rip), %rax
	subl	(%rax), %r12d
LBB0_19:
	movl	%r12d, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movq	-40(%rbp), %rax
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Cannot find firmware: %s\n"

	.comm	_ENOENT,4,2                     ## @ENOENT
L_.str.1:                               ## @.str.1
	.asciz	"Primary firmware download failed\n"

L_.str.2:                               ## @.str.2
	.asciz	"Secondary firmware download failed\n"

	.no_dead_strip	_symbol_dl_firmware
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function symbol_dl_firmware
_symbol_dl_firmware:                    ; @symbol_dl_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	x21, x1
	mov	x20, x0
	ldr	x19, [x0]
	mov	w1, #1
	bl	_orinoco_cached_fw_get
	cbz	x0, LBB0_5
; %bb.1:
	mov	x0, x20
	mov	w1, #1
	bl	_orinoco_cached_fw_get
	str	x0, [sp, #8]
LBB0_2:
	ldp	x8, x2, [x0]
	add	x3, x8, x2
	mov	x0, x20
	mov	x1, x21
	mov	w4, #0
	bl	_symbol_dl_image
	mov	x22, x0
	mov	x0, x20
	mov	w1, #1
	bl	_orinoco_cached_fw_get
	cbz	x0, LBB0_7
; %bb.3:
	cbz	w22, LBB0_8
LBB0_4:
Lloh0:
	adrp	x1, l_.str.1@PAGE
Lloh1:
	add	x1, x1, l_.str.1@PAGEOFF
	b	LBB0_14
LBB0_5:
	ldr	w1, [x21, #4]
	ldr	x2, [x20]
	add	x0, sp, #8
	bl	_request_firmware
	cbz	x0, LBB0_15
; %bb.6:
	ldr	w8, [x21, #4]
	b	LBB0_18
LBB0_7:
	ldr	x0, [sp, #8]
	bl	_release_firmware
	cbnz	w22, LBB0_4
LBB0_8:
	mov	x0, x20
	mov	w1, #0
	bl	_orinoco_cached_fw_get
	cbz	x0, LBB0_16
; %bb.9:
	mov	x0, x20
	mov	w1, #0
	bl	_orinoco_cached_fw_get
	str	x0, [sp, #8]
LBB0_10:
	ldp	x8, x2, [x0]
	add	x3, x8, x2
	mov	x0, x20
	mov	x1, x21
	mov	w4, #1
	bl	_symbol_dl_image
	mov	x22, x0
	mov	x0, x20
	mov	w1, #0
	bl	_orinoco_cached_fw_get
	cbnz	x0, LBB0_12
; %bb.11:
	ldr	x0, [sp, #8]
	bl	_release_firmware
LBB0_12:
	cbz	w22, LBB0_19
; %bb.13:
Lloh2:
	adrp	x1, l_.str.2@PAGE
Lloh3:
	add	x1, x1, l_.str.2@PAGEOFF
LBB0_14:
	mov	x0, x19
	bl	_dev_err
	b	LBB0_19
LBB0_15:
	ldr	x0, [sp, #8]
	b	LBB0_2
LBB0_16:
	ldr	w1, [x21]
	ldr	x2, [x20]
	add	x0, sp, #8
	bl	_request_firmware
	cbz	x0, LBB0_20
; %bb.17:
	ldr	w8, [x21]
LBB0_18:
	str	x8, [sp]
Lloh4:
	adrp	x1, l_.str@PAGE
Lloh5:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_dev_err
Lloh6:
	adrp	x8, _ENOENT@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh8:
	ldr	w8, [x8]
	neg	w22, w8
LBB0_19:
	mov	x0, x22
	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_20:
	ldr	x0, [sp, #8]
	b	LBB0_10
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Cannot find firmware: %s\n"

	.comm	_ENOENT,4,2                     ; @ENOENT
l_.str.1:                               ; @.str.1
	.asciz	"Primary firmware download failed\n"

l_.str.2:                               ; @.str.2
	.asciz	"Secondary firmware download failed\n"

	.no_dead_strip	_symbol_dl_firmware
.subsections_via_symbols
