	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipw_load
_ipw_load:                              ## @ipw_load
	.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, %r15
	movq	$0, -56(%rbp)
	movq	24(%rdi), %rax
	movl	(%rax), %eax
	cmpl	$130, %eax
	je	LBB0_1
## %bb.2:
	cmpl	$129, %eax
	jne	LBB0_32
## %bb.3:
	leaq	L_.str.1(%rip), %rdx
	jmp	LBB0_4
LBB0_1:
	leaq	L_.str(%rip), %rdx
LBB0_4:
	leaq	-56(%rbp), %rsi
	movq	%r15, %rdi
	callq	_ipw_get_fw
	testl	%eax, %eax
	js	LBB0_5
## %bb.6:
	movq	-56(%rbp), %rax
	movq	(%rax), %r12
	movq	(%r12), %rax
	movq	%rax, -80(%rbp)                 ## 8-byte Spill
	movl	16(%r12), %edi
	callq	_le32_to_cpu
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	(%r12), %rax
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movl	16(%r12), %edi
	callq	_le32_to_cpu
	movq	%rax, %r13
	movl	12(%r12), %edi
	callq	_le32_to_cpu
	movq	%rax, %r14
	movq	8(%r15), %rsi
	movq	%r15, %rdi
	testq	%rsi, %rsi
	je	LBB0_7
## %bb.8:
	callq	_ipw_rx_queue_reset
	movq	8(%r15), %rax
	testq	%rax, %rax
	je	LBB0_38
LBB0_10:
	addq	%r13, %r14
	addq	%r14, -72(%rbp)                 ## 8-byte Folded Spill
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	addq	-80(%rbp), %rax                 ## 8-byte Folded Reload
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movl	$-3, %r14d
	movq	_IPW_INTA_MASK_ALL@GOTPCREL(%rip), %rbx
	movq	_IPW_INTA_RW@GOTPCREL(%rip), %r13
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	_IPW_INTA_MASK_R@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	(%rbx), %edx
	notl	%edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movq	_STATUS_INT_ENABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	notl	%eax
	andl	%eax, 16(%r15)
	movl	(%r13), %esi
	movl	(%rbx), %edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movq	%r15, %rdi
	callq	_ipw_stop_nic
	movq	%r15, %rdi
	callq	_ipw_reset_nic
	testl	%eax, %eax
	js	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	_IPW_NIC_SRAM_LOWER_BOUND@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	movq	_IPW_NIC_SRAM_UPPER_BOUND@GOTPCREL(%rip), %rax
	movq	(%rax), %rdx
	subq	%rsi, %rdx
	movq	%r15, %rdi
	callq	_ipw_zero_memory
	movl	16(%r12), %edi
	callq	_le32_to_cpu
	movq	%r15, %rdi
	movq	-80(%rbp), %rsi                 ## 8-byte Reload
	movq	%rax, %rdx
	callq	_ipw_load_firmware
	testl	%eax, %eax
	js	LBB0_14
## %bb.16:                              ##   in Loop: Header=BB0_11 Depth=1
	movl	%r14d, -60(%rbp)                ## 4-byte Spill
	movq	%r12, %r14
	movq	%r15, %rdi
	callq	_ipw_start_nic
	movq	_IPW_INTA_RW@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	_IPW_INTA_BIT_FW_INITIALIZATION_DONE@GOTPCREL(%rip), %r12
	movl	(%r12), %edx
	movq	%r15, %rdi
	movl	$500, %ecx                      ## imm = 0x1F4
	callq	_ipw_poll_bit
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_17
## %bb.19:                              ##   in Loop: Header=BB0_11 Depth=1
	leaq	L_.str.6(%rip), %rdi
	movl	%r13d, %esi
	callq	_IPW_DEBUG_INFO
	movl	(%rbx), %esi
	movl	(%r12), %edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movq	%r14, %r12
	movl	12(%r14), %edi
	callq	_le32_to_cpu
	movq	%r15, %rdi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
	movq	%rax, %rdx
	callq	_ipw_load_ucode
	testl	%eax, %eax
	js	LBB0_20
## %bb.21:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	%r15, %rdi
	callq	_ipw_stop_nic
	movl	8(%r12), %edi
	callq	_le32_to_cpu
	movq	%r15, %rdi
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	movq	%rax, %rdx
	callq	_ipw_load_firmware
	testl	%eax, %eax
	js	LBB0_22
## %bb.23:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	_IPW_EEPROM_LOAD_DISABLE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r15, %rdi
	xorl	%edx, %edx
	callq	_ipw_write32
	movq	%r15, %rdi
	callq	_ipw_queue_reset
	testl	%eax, %eax
	js	LBB0_24
## %bb.25:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	_IPW_INTA_MASK_R@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_IPW_INTA_MASK_ALL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %edx
	notl	%edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movq	_IPW_INTA_RW@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movl	(%rbx), %edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movq	%r15, %rdi
	callq	_ipw_start_nic
	movl	(%r13), %esi
	movq	%r15, %rdi
	callq	_ipw_read32
	movq	_IPW_INTA_BIT_PARITY_ERROR@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_29
## %bb.26:                              ##   in Loop: Header=BB0_11 Depth=1
	movl	-60(%rbp), %r14d                ## 4-byte Reload
	testl	%r14d, %r14d
	je	LBB0_28
## %bb.27:                              ##   in Loop: Header=BB0_11 Depth=1
	leaq	L_.str.10(%rip), %rdi
	callq	_IPW_WARNING
	incl	%r14d
	jmp	LBB0_11
LBB0_32:
	movq	_EINVAL@GOTPCREL(%rip), %rax
	xorl	%r13d, %r13d
	jmp	LBB0_33
LBB0_5:
	movl	%eax, %r13d
	jmp	LBB0_34
LBB0_7:
	callq	_ipw_rx_queue_alloc
	movq	%rax, 8(%r15)
	testq	%rax, %rax
	jne	LBB0_10
LBB0_38:
	leaq	L_.str.2(%rip), %rdi
	xorl	%r13d, %r13d
	xorl	%eax, %eax
	callq	_IPW_ERROR
	movq	_ENOMEM@GOTPCREL(%rip), %rax
LBB0_33:
	subl	(%rax), %r13d
LBB0_34:
	movq	8(%r15), %rsi
	testq	%rsi, %rsi
	je	LBB0_36
## %bb.35:
	movq	%r15, %rdi
	callq	_ipw_rx_queue_free
	movq	$0, 8(%r15)
LBB0_36:
	movq	%r15, %rdi
	callq	_ipw_tx_queue_free
LBB0_37:
	movq	-56(%rbp), %rdi
	callq	_release_firmware
	movl	%r13d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movl	%eax, %r13d
	leaq	L_.str.3(%rip), %rdi
	jmp	LBB0_18
LBB0_14:
	movl	%eax, %r13d
	leaq	L_.str.4(%rip), %rdi
	jmp	LBB0_15
LBB0_17:
	leaq	L_.str.5(%rip), %rdi
	jmp	LBB0_18
LBB0_20:
	movl	%eax, %r13d
	leaq	L_.str.7(%rip), %rdi
	jmp	LBB0_15
LBB0_22:
	movl	%eax, %r13d
	leaq	L_.str.8(%rip), %rdi
LBB0_15:
	movl	%r13d, %esi
	xorl	%eax, %eax
	callq	_IPW_ERROR
	jmp	LBB0_34
LBB0_24:
	movl	%eax, %r13d
	leaq	L_.str.9(%rip), %rdi
	jmp	LBB0_18
LBB0_29:
	movl	(%r13), %esi
	movq	_IPW_INTA_BIT_FW_INITIALIZATION_DONE@GOTPCREL(%rip), %r14
	movl	(%r14), %edx
	movq	%r15, %rdi
	movl	$500, %ecx                      ## imm = 0x1F4
	callq	_ipw_poll_bit
	movq	%r13, %rbx
	movl	%eax, %r13d
	testl	%eax, %eax
	js	LBB0_30
## %bb.31:
	leaq	L_.str.13(%rip), %rdi
	movl	%r13d, %esi
	callq	_IPW_DEBUG_INFO
	movl	(%rbx), %esi
	movl	(%r14), %edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movl	$1, (%r15)
	movq	%r15, %rdi
	callq	_ipw_read_eeprom
	movq	%r15, %rdi
	callq	_ipw_eeprom_init_sram
	movq	%r15, %rdi
	callq	_ipw_enable_interrupts
	movq	%r15, %rdi
	callq	_ipw_rx_queue_replenish
	movq	_IPW_RX_READ_INDEX@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	8(%r15), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	callq	_ipw_write32
	movl	(%rbx), %esi
	movq	_IPW_INTA_MASK_ALL@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%r15, %rdi
	callq	_ipw_write32
	xorl	%r13d, %r13d
	jmp	LBB0_37
LBB0_28:
	leaq	L_.str.11(%rip), %rdi
	xorl	%r13d, %r13d
	xorl	%eax, %eax
	callq	_IPW_ERROR
	movq	_EIO@GOTPCREL(%rip), %rax
	jmp	LBB0_33
LBB0_30:
	leaq	L_.str.12(%rip), %rdi
LBB0_18:
	xorl	%eax, %eax
	callq	_IPW_ERROR
	jmp	LBB0_34
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"ipw2200-ibss.fw"

L_.str.1:                               ## @.str.1
	.asciz	"ipw2200-bss.fw"

	.comm	_EINVAL,4,2                     ## @EINVAL
L_.str.2:                               ## @.str.2
	.asciz	"Unable to initialize Rx queue\n"

	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_IPW_INTA_MASK_R,4,2            ## @IPW_INTA_MASK_R
	.comm	_IPW_INTA_MASK_ALL,4,2          ## @IPW_INTA_MASK_ALL
	.comm	_STATUS_INT_ENABLED,4,2         ## @STATUS_INT_ENABLED
	.comm	_IPW_INTA_RW,4,2                ## @IPW_INTA_RW
L_.str.3:                               ## @.str.3
	.asciz	"Unable to reset NIC\n"

	.comm	_IPW_NIC_SRAM_LOWER_BOUND,8,3   ## @IPW_NIC_SRAM_LOWER_BOUND
	.comm	_IPW_NIC_SRAM_UPPER_BOUND,8,3   ## @IPW_NIC_SRAM_UPPER_BOUND
L_.str.4:                               ## @.str.4
	.asciz	"Unable to load boot firmware: %d\n"

	.comm	_IPW_INTA_BIT_FW_INITIALIZATION_DONE,4,2 ## @IPW_INTA_BIT_FW_INITIALIZATION_DONE
L_.str.5:                               ## @.str.5
	.asciz	"device failed to boot initial fw image\n"

L_.str.6:                               ## @.str.6
	.asciz	"initial device response after %dms\n"

L_.str.7:                               ## @.str.7
	.asciz	"Unable to load ucode: %d\n"

L_.str.8:                               ## @.str.8
	.asciz	"Unable to load firmware: %d\n"

	.comm	_IPW_EEPROM_LOAD_DISABLE,4,2    ## @IPW_EEPROM_LOAD_DISABLE
L_.str.9:                               ## @.str.9
	.asciz	"Unable to initialize queues\n"

	.comm	_IPW_INTA_BIT_PARITY_ERROR,4,2  ## @IPW_INTA_BIT_PARITY_ERROR
L_.str.10:                              ## @.str.10
	.asciz	"Parity error.  Retrying init.\n"

L_.str.11:                              ## @.str.11
	.asciz	"TODO: Handle parity error -- schedule restart?\n"

	.comm	_EIO,4,2                        ## @EIO
L_.str.12:                              ## @.str.12
	.asciz	"device failed to start within 500ms\n"

L_.str.13:                              ## @.str.13
	.asciz	"device response after %dms\n"

	.comm	_IPW_RX_READ_INDEX,4,2          ## @IPW_RX_READ_INDEX
	.comm	_fw_loaded,4,2                  ## @fw_loaded
	.no_dead_strip	_ipw_load
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipw_load
_ipw_load:                              ; @ipw_load
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x0
	str	xzr, [sp, #24]
	ldr	x8, [x0, #24]
	ldr	w8, [x8]
	cmp	w8, #130
	b.eq	LBB0_3
; %bb.1:
	cmp	w8, #129
	b.ne	LBB0_17
; %bb.2:
Lloh0:
	adrp	x2, l_.str.1@PAGE
Lloh1:
	add	x2, x2, l_.str.1@PAGEOFF
	b	LBB0_4
LBB0_3:
Lloh2:
	adrp	x2, l_.str@PAGE
Lloh3:
	add	x2, x2, l_.str@PAGEOFF
LBB0_4:
	add	x1, sp, #24
	mov	x0, x19
	bl	_ipw_get_fw
	tbnz	w0, #31, LBB0_18
; %bb.5:
	ldr	x8, [sp, #24]
	ldr	x27, [x8]
	ldr	x20, [x27]
	ldr	w0, [x27, #16]
	bl	_le32_to_cpu
	mov	x21, x0
	ldr	x24, [x27]
	ldr	w0, [x27, #16]
	bl	_le32_to_cpu
	mov	x22, x0
	ldr	w0, [x27, #12]
	bl	_le32_to_cpu
	mov	x23, x0
	ldr	x1, [x19, #8]
	cbz	x1, LBB0_19
; %bb.6:
	mov	x0, x19
	bl	_ipw_rx_queue_reset
	ldr	x0, [x19, #8]
	cbz	x0, LBB0_20
LBB0_7:
	add	x21, x20, x21
	add	x8, x23, x22
	add	x8, x24, x8
	str	x8, [sp, #16]                   ; 8-byte Folded Spill
	mov	w23, #-3
Lloh4:
	adrp	x22, _IPW_INTA_MASK_R@GOTPAGE
Lloh5:
	ldr	x22, [x22, _IPW_INTA_MASK_R@GOTPAGEOFF]
Lloh6:
	adrp	x26, _IPW_INTA_MASK_ALL@GOTPAGE
Lloh7:
	ldr	x26, [x26, _IPW_INTA_MASK_ALL@GOTPAGEOFF]
Lloh8:
	adrp	x28, _IPW_INTA_RW@GOTPAGE
Lloh9:
	ldr	x28, [x28, _IPW_INTA_RW@GOTPAGEOFF]
Lloh10:
	adrp	x24, _IPW_INTA_BIT_FW_INITIALIZATION_DONE@GOTPAGE
Lloh11:
	ldr	x24, [x24, _IPW_INTA_BIT_FW_INITIALIZATION_DONE@GOTPAGEOFF]
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x22]
	ldr	w8, [x26]
	mvn	w2, w8
	mov	x0, x19
	bl	_ipw_write32
Lloh12:
	adrp	x8, _STATUS_INT_ENABLED@GOTPAGE
Lloh13:
	ldr	x8, [x8, _STATUS_INT_ENABLED@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	ldr	w9, [x19, #16]
	bic	w8, w9, w8
	str	w8, [x19, #16]
	ldr	w1, [x28]
	ldr	w2, [x26]
	mov	x0, x19
	bl	_ipw_write32
	mov	x0, x19
	bl	_ipw_stop_nic
	mov	x0, x19
	bl	_ipw_reset_nic
	tbnz	w0, #31, LBB0_22
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=1
Lloh15:
	adrp	x8, _IPW_NIC_SRAM_LOWER_BOUND@GOTPAGE
Lloh16:
	ldr	x8, [x8, _IPW_NIC_SRAM_LOWER_BOUND@GOTPAGEOFF]
Lloh17:
	ldr	x1, [x8]
Lloh18:
	adrp	x8, _IPW_NIC_SRAM_UPPER_BOUND@GOTPAGE
Lloh19:
	ldr	x8, [x8, _IPW_NIC_SRAM_UPPER_BOUND@GOTPAGEOFF]
Lloh20:
	ldr	x8, [x8]
	sub	x2, x8, x1
	mov	x0, x19
	bl	_ipw_zero_memory
	ldr	w0, [x27, #16]
	bl	_le32_to_cpu
	mov	x2, x0
	mov	x0, x19
	mov	x1, x20
	bl	_ipw_load_firmware
	tbnz	w0, #31, LBB0_23
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x19
	bl	_ipw_start_nic
	ldr	w1, [x28]
	ldr	w2, [x24]
	mov	x0, x19
	mov	w3, #500
	bl	_ipw_poll_bit
	mov	x25, x0
	tbnz	w0, #31, LBB0_24
; %bb.11:                               ;   in Loop: Header=BB0_8 Depth=1
Lloh21:
	adrp	x0, l_.str.6@PAGE
Lloh22:
	add	x0, x0, l_.str.6@PAGEOFF
	mov	x1, x25
	bl	_IPW_DEBUG_INFO
	ldr	w1, [x28]
	ldr	w2, [x24]
	mov	x0, x19
	bl	_ipw_write32
	ldr	w0, [x27, #12]
	bl	_le32_to_cpu
	mov	x2, x0
	mov	x0, x19
	mov	x1, x21
	bl	_ipw_load_ucode
	tbnz	w0, #31, LBB0_25
; %bb.12:                               ;   in Loop: Header=BB0_8 Depth=1
	mov	x0, x19
	bl	_ipw_stop_nic
	ldr	w0, [x27, #8]
	bl	_le32_to_cpu
	mov	x2, x0
	mov	x0, x19
	ldr	x1, [sp, #16]                   ; 8-byte Folded Reload
	bl	_ipw_load_firmware
	tbnz	w0, #31, LBB0_26
; %bb.13:                               ;   in Loop: Header=BB0_8 Depth=1
Lloh23:
	adrp	x8, _IPW_EEPROM_LOAD_DISABLE@GOTPAGE
Lloh24:
	ldr	x8, [x8, _IPW_EEPROM_LOAD_DISABLE@GOTPAGEOFF]
Lloh25:
	ldr	w1, [x8]
	mov	x0, x19
	mov	w2, #0
	bl	_ipw_write32
	mov	x0, x19
	bl	_ipw_queue_reset
	tbnz	w0, #31, LBB0_28
; %bb.14:                               ;   in Loop: Header=BB0_8 Depth=1
	ldr	w1, [x22]
	ldr	w8, [x26]
	mvn	w2, w8
	mov	x0, x19
	bl	_ipw_write32
	ldr	w1, [x28]
	ldr	w2, [x26]
	mov	x0, x19
	bl	_ipw_write32
	mov	x0, x19
	bl	_ipw_start_nic
	ldr	w1, [x28]
	mov	x0, x19
	bl	_ipw_read32
Lloh26:
	adrp	x8, _IPW_INTA_BIT_PARITY_ERROR@GOTPAGE
Lloh27:
	ldr	x8, [x8, _IPW_INTA_BIT_PARITY_ERROR@GOTPAGEOFF]
Lloh28:
	ldr	w8, [x8]
	tst	w8, w0
	b.eq	LBB0_29
; %bb.15:                               ;   in Loop: Header=BB0_8 Depth=1
	cbz	w23, LBB0_31
; %bb.16:                               ;   in Loop: Header=BB0_8 Depth=1
Lloh29:
	adrp	x0, l_.str.10@PAGE
Lloh30:
	add	x0, x0, l_.str.10@PAGEOFF
	bl	_IPW_WARNING
	add	w23, w23, #1
	b	LBB0_8
LBB0_17:
Lloh31:
	adrp	x8, _EINVAL@GOTPAGE
Lloh32:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
	b	LBB0_21
LBB0_18:
	mov	x25, x0
	b	LBB0_34
LBB0_19:
	mov	x0, x19
	bl	_ipw_rx_queue_alloc
	str	x0, [x19, #8]
	cbnz	x0, LBB0_7
LBB0_20:
Lloh33:
	adrp	x0, l_.str.2@PAGE
Lloh34:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_IPW_ERROR
Lloh35:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh36:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
LBB0_21:
	ldr	w8, [x8]
	neg	w25, w8
	b	LBB0_34
LBB0_22:
	mov	x25, x0
Lloh37:
	adrp	x0, l_.str.3@PAGE
Lloh38:
	add	x0, x0, l_.str.3@PAGEOFF
	b	LBB0_33
LBB0_23:
	mov	x25, x0
	str	x25, [sp]
Lloh39:
	adrp	x0, l_.str.4@PAGE
Lloh40:
	add	x0, x0, l_.str.4@PAGEOFF
	b	LBB0_33
LBB0_24:
Lloh41:
	adrp	x0, l_.str.5@PAGE
Lloh42:
	add	x0, x0, l_.str.5@PAGEOFF
	b	LBB0_33
LBB0_25:
	mov	x25, x0
	str	x25, [sp]
Lloh43:
	adrp	x0, l_.str.7@PAGE
Lloh44:
	add	x0, x0, l_.str.7@PAGEOFF
	b	LBB0_27
LBB0_26:
	mov	x25, x0
	str	x25, [sp]
Lloh45:
	adrp	x0, l_.str.8@PAGE
Lloh46:
	add	x0, x0, l_.str.8@PAGEOFF
LBB0_27:
	bl	_IPW_ERROR
                                        ; kill: def $w25 killed $w25 killed $x25 def $x25
	b	LBB0_34
LBB0_28:
	mov	x25, x0
Lloh47:
	adrp	x0, l_.str.9@PAGE
Lloh48:
	add	x0, x0, l_.str.9@PAGEOFF
	b	LBB0_33
LBB0_29:
	ldr	w1, [x28]
Lloh49:
	adrp	x20, _IPW_INTA_BIT_FW_INITIALIZATION_DONE@GOTPAGE
Lloh50:
	ldr	x20, [x20, _IPW_INTA_BIT_FW_INITIALIZATION_DONE@GOTPAGEOFF]
	ldr	w2, [x20]
	mov	x0, x19
	mov	w3, #500
	bl	_ipw_poll_bit
	mov	x25, x0
	tbnz	w0, #31, LBB0_32
; %bb.30:
Lloh51:
	adrp	x0, l_.str.13@PAGE
Lloh52:
	add	x0, x0, l_.str.13@PAGEOFF
	mov	x1, x25
	bl	_IPW_DEBUG_INFO
	ldr	w1, [x28]
	ldr	w2, [x20]
	mov	x0, x19
	bl	_ipw_write32
	mov	w8, #1
	str	w8, [x19]
	mov	x0, x19
	bl	_ipw_read_eeprom
	mov	x0, x19
	bl	_ipw_eeprom_init_sram
	mov	x0, x19
	bl	_ipw_enable_interrupts
	mov	x0, x19
	bl	_ipw_rx_queue_replenish
Lloh53:
	adrp	x8, _IPW_RX_READ_INDEX@GOTPAGE
Lloh54:
	ldr	x8, [x8, _IPW_RX_READ_INDEX@GOTPAGEOFF]
Lloh55:
	ldr	w1, [x8]
	ldr	x8, [x19, #8]
	ldr	w2, [x8]
	mov	x0, x19
	bl	_ipw_write32
	ldr	w1, [x28]
	ldr	w2, [x26]
	mov	x0, x19
	bl	_ipw_write32
	mov	w25, #0
	b	LBB0_37
LBB0_31:
Lloh56:
	adrp	x0, l_.str.11@PAGE
Lloh57:
	add	x0, x0, l_.str.11@PAGEOFF
	bl	_IPW_ERROR
Lloh58:
	adrp	x8, _EIO@GOTPAGE
Lloh59:
	ldr	x8, [x8, _EIO@GOTPAGEOFF]
	b	LBB0_21
LBB0_32:
Lloh60:
	adrp	x0, l_.str.12@PAGE
Lloh61:
	add	x0, x0, l_.str.12@PAGEOFF
LBB0_33:
	bl	_IPW_ERROR
LBB0_34:
	ldr	x1, [x19, #8]
	cbz	x1, LBB0_36
; %bb.35:
	mov	x0, x19
	bl	_ipw_rx_queue_free
	str	xzr, [x19, #8]
LBB0_36:
	mov	x0, x19
	bl	_ipw_tx_queue_free
LBB0_37:
	ldr	x0, [sp, #24]
	bl	_release_firmware
	mov	x0, x25
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGot	Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpAdd	Lloh41, Lloh42
	.loh AdrpAdd	Lloh43, Lloh44
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpAdd	Lloh47, Lloh48
	.loh AdrpLdrGot	Lloh49, Lloh50
	.loh AdrpLdrGotLdr	Lloh53, Lloh54, Lloh55
	.loh AdrpAdd	Lloh51, Lloh52
	.loh AdrpLdrGot	Lloh58, Lloh59
	.loh AdrpAdd	Lloh56, Lloh57
	.loh AdrpAdd	Lloh60, Lloh61
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"ipw2200-ibss.fw"

l_.str.1:                               ; @.str.1
	.asciz	"ipw2200-bss.fw"

	.comm	_EINVAL,4,2                     ; @EINVAL
l_.str.2:                               ; @.str.2
	.asciz	"Unable to initialize Rx queue\n"

	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_IPW_INTA_MASK_R,4,2            ; @IPW_INTA_MASK_R
	.comm	_IPW_INTA_MASK_ALL,4,2          ; @IPW_INTA_MASK_ALL
	.comm	_STATUS_INT_ENABLED,4,2         ; @STATUS_INT_ENABLED
	.comm	_IPW_INTA_RW,4,2                ; @IPW_INTA_RW
l_.str.3:                               ; @.str.3
	.asciz	"Unable to reset NIC\n"

	.comm	_IPW_NIC_SRAM_LOWER_BOUND,8,3   ; @IPW_NIC_SRAM_LOWER_BOUND
	.comm	_IPW_NIC_SRAM_UPPER_BOUND,8,3   ; @IPW_NIC_SRAM_UPPER_BOUND
l_.str.4:                               ; @.str.4
	.asciz	"Unable to load boot firmware: %d\n"

	.comm	_IPW_INTA_BIT_FW_INITIALIZATION_DONE,4,2 ; @IPW_INTA_BIT_FW_INITIALIZATION_DONE
l_.str.5:                               ; @.str.5
	.asciz	"device failed to boot initial fw image\n"

l_.str.6:                               ; @.str.6
	.asciz	"initial device response after %dms\n"

l_.str.7:                               ; @.str.7
	.asciz	"Unable to load ucode: %d\n"

l_.str.8:                               ; @.str.8
	.asciz	"Unable to load firmware: %d\n"

	.comm	_IPW_EEPROM_LOAD_DISABLE,4,2    ; @IPW_EEPROM_LOAD_DISABLE
l_.str.9:                               ; @.str.9
	.asciz	"Unable to initialize queues\n"

	.comm	_IPW_INTA_BIT_PARITY_ERROR,4,2  ; @IPW_INTA_BIT_PARITY_ERROR
l_.str.10:                              ; @.str.10
	.asciz	"Parity error.  Retrying init.\n"

l_.str.11:                              ; @.str.11
	.asciz	"TODO: Handle parity error -- schedule restart?\n"

	.comm	_EIO,4,2                        ; @EIO
l_.str.12:                              ; @.str.12
	.asciz	"device failed to start within 500ms\n"

l_.str.13:                              ; @.str.13
	.asciz	"device response after %dms\n"

	.comm	_IPW_RX_READ_INDEX,4,2          ; @IPW_RX_READ_INDEX
	.comm	_fw_loaded,4,2                  ; @fw_loaded
	.no_dead_strip	_ipw_load
.subsections_via_symbols
