	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ipw_stop_nic
_ipw_stop_nic:                          ## @ipw_stop_nic
	.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
	movq	%rdi, %rbx
	movq	_IPW_RESET_REG@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	_IPW_RESET_REG_STOP_MASTER@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	callq	_ipw_write32
	movl	(%r15), %esi
	movq	_IPW_RESET_REG_MASTER_DISABLED@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	movl	$500, %ecx                      ## imm = 0x1F4
	callq	_ipw_poll_bit
	movl	%eax, %r14d
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movl	(%r15), %esi
	movq	_CBD_RESET_REG_PRINCETON_RESET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movq	%rbx, %rdi
	callq	_ipw_set_bit
	jmp	LBB0_3
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_IPW_ERROR
LBB0_3:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_IPW_RESET_REG,4,2              ## @IPW_RESET_REG
	.comm	_IPW_RESET_REG_STOP_MASTER,4,2  ## @IPW_RESET_REG_STOP_MASTER
	.comm	_IPW_RESET_REG_MASTER_DISABLED,4,2 ## @IPW_RESET_REG_MASTER_DISABLED
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"wait for reg master disabled failed after 500ms\n"

	.comm	_CBD_RESET_REG_PRINCETON_RESET,4,2 ## @CBD_RESET_REG_PRINCETON_RESET
	.no_dead_strip	_ipw_stop_nic
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ipw_stop_nic
_ipw_stop_nic:                          ; @ipw_stop_nic
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x21, _IPW_RESET_REG@GOTPAGE
Lloh1:
	ldr	x21, [x21, _IPW_RESET_REG@GOTPAGEOFF]
	ldr	w1, [x21]
Lloh2:
	adrp	x8, _IPW_RESET_REG_STOP_MASTER@GOTPAGE
Lloh3:
	ldr	x8, [x8, _IPW_RESET_REG_STOP_MASTER@GOTPAGEOFF]
Lloh4:
	ldr	w2, [x8]
	bl	_ipw_write32
	ldr	w1, [x21]
Lloh5:
	adrp	x8, _IPW_RESET_REG_MASTER_DISABLED@GOTPAGE
Lloh6:
	ldr	x8, [x8, _IPW_RESET_REG_MASTER_DISABLED@GOTPAGEOFF]
Lloh7:
	ldr	w2, [x8]
	mov	x0, x19
	mov	w3, #500
	bl	_ipw_poll_bit
	mov	x20, x0
	tbnz	w0, #31, LBB0_2
; %bb.1:
	ldr	w1, [x21]
Lloh8:
	adrp	x8, _CBD_RESET_REG_PRINCETON_RESET@GOTPAGE
Lloh9:
	ldr	x8, [x8, _CBD_RESET_REG_PRINCETON_RESET@GOTPAGEOFF]
Lloh10:
	ldr	w2, [x8]
	mov	x0, x19
	bl	_ipw_set_bit
	b	LBB0_3
LBB0_2:
Lloh11:
	adrp	x0, l_.str@PAGE
Lloh12:
	add	x0, x0, l_.str@PAGEOFF
	bl	_IPW_ERROR
LBB0_3:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpAdd	Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_IPW_RESET_REG,4,2              ; @IPW_RESET_REG
	.comm	_IPW_RESET_REG_STOP_MASTER,4,2  ; @IPW_RESET_REG_STOP_MASTER
	.comm	_IPW_RESET_REG_MASTER_DISABLED,4,2 ; @IPW_RESET_REG_MASTER_DISABLED
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"wait for reg master disabled failed after 500ms\n"

	.comm	_CBD_RESET_REG_PRINCETON_RESET,4,2 ; @CBD_RESET_REG_PRINCETON_RESET
	.no_dead_strip	_ipw_stop_nic
.subsections_via_symbols
