	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ice_pf_reset
_ice_pf_reset:                          ## @ice_pf_reset
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movq	_GLGEN_RSTAT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_rd32
	movq	_GLGEN_RSTAT_DEVSTATE_M@GOTPCREL(%rip), %rcx
	testq	%rax, (%rcx)
	jne	LBB0_2
## %bb.1:
	movq	_GLNVM_ULD@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_rd32
	movq	_ICE_RESET_DONE_MASK@GOTPCREL(%rip), %rcx
	notq	%rax
	testq	%rax, (%rcx)
	je	LBB0_3
LBB0_2:
	movq	%r13, %rdi
	callq	_ice_check_reset
	xorl	%r14d, %r14d
	testq	%rax, %rax
	je	LBB0_10
LBB0_9:
	movq	_ICE_ERR_RESET_FAILED@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
LBB0_10:
	movl	%r14d, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	_PFGEN_CTRL@GOTPCREL(%rip), %rbx
	movl	(%rbx), %esi
	movq	%r13, %rdi
	callq	_rd32
	movl	(%rbx), %esi
	movq	_PFGEN_CTRL_PFSWR_M@GOTPCREL(%rip), %r12
	orq	(%r12), %rax
	movq	%r13, %rdi
	movq	%rax, %rdx
	callq	_wr32
	movq	_ICE_PF_RESET_WAIT_COUNT@GOTPCREL(%rip), %r15
	movq	(%r15), %rax
	xorl	%r14d, %r14d
	xorl	%ebx, %ebx
	testq	%rax, %rax
	jle	LBB0_7
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movq	_PFGEN_CTRL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%r13, %rdi
	callq	_rd32
	testq	%rax, (%r12)
	je	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=1
	movl	$1, %edi
	callq	_mdelay
	incq	%rbx
	movq	(%r15), %rax
	cmpq	%rax, %rbx
	jl	LBB0_4
	jmp	LBB0_7
LBB0_5:
	movq	(%r15), %rax
LBB0_7:
	cmpq	%rax, %rbx
	jne	LBB0_10
## %bb.8:
	movq	_ICE_DBG_INIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r13, %rdi
	callq	_ice_debug
	jmp	LBB0_9
	.cfi_endproc
                                        ## -- End function
	.comm	_GLGEN_RSTAT,4,2                ## @GLGEN_RSTAT
	.comm	_GLGEN_RSTAT_DEVSTATE_M,8,3     ## @GLGEN_RSTAT_DEVSTATE_M
	.comm	_GLNVM_ULD,4,2                  ## @GLNVM_ULD
	.comm	_ICE_RESET_DONE_MASK,8,3        ## @ICE_RESET_DONE_MASK
	.comm	_ICE_ERR_RESET_FAILED,4,2       ## @ICE_ERR_RESET_FAILED
	.comm	_PFGEN_CTRL,4,2                 ## @PFGEN_CTRL
	.comm	_PFGEN_CTRL_PFSWR_M,8,3         ## @PFGEN_CTRL_PFSWR_M
	.comm	_ICE_PF_RESET_WAIT_COUNT,8,3    ## @ICE_PF_RESET_WAIT_COUNT
	.comm	_ICE_DBG_INIT,4,2               ## @ICE_DBG_INIT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"PF reset polling failed to complete.\n"

	.no_dead_strip	_ice_pf_reset
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ice_pf_reset
_ice_pf_reset:                          ; @ice_pf_reset
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x0
Lloh0:
	adrp	x8, _GLGEN_RSTAT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _GLGEN_RSTAT@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	bl	_rd32
Lloh3:
	adrp	x8, _GLGEN_RSTAT_DEVSTATE_M@GOTPAGE
Lloh4:
	ldr	x8, [x8, _GLGEN_RSTAT_DEVSTATE_M@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	tst	x8, x0
	b.ne	LBB0_2
; %bb.1:
Lloh6:
	adrp	x8, _GLNVM_ULD@GOTPAGE
Lloh7:
	ldr	x8, [x8, _GLNVM_ULD@GOTPAGEOFF]
Lloh8:
	ldr	w1, [x8]
	mov	x0, x19
	bl	_rd32
Lloh9:
	adrp	x8, _ICE_RESET_DONE_MASK@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ICE_RESET_DONE_MASK@GOTPAGEOFF]
Lloh11:
	ldr	x8, [x8]
	bics	xzr, x8, x0
	b.eq	LBB0_4
LBB0_2:
	mov	x0, x19
	bl	_ice_check_reset
Lloh12:
	adrp	x8, _ICE_ERR_RESET_FAILED@GOTPAGE
Lloh13:
	ldr	x8, [x8, _ICE_ERR_RESET_FAILED@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	cmp	x0, #0
	csel	w0, wzr, w8, eq
LBB0_3:
	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
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_4:
Lloh15:
	adrp	x20, _PFGEN_CTRL@GOTPAGE
Lloh16:
	ldr	x20, [x20, _PFGEN_CTRL@GOTPAGEOFF]
	ldr	w1, [x20]
	mov	x0, x19
	bl	_rd32
	ldr	w1, [x20]
Lloh17:
	adrp	x21, _PFGEN_CTRL_PFSWR_M@GOTPAGE
Lloh18:
	ldr	x21, [x21, _PFGEN_CTRL_PFSWR_M@GOTPAGEOFF]
	ldr	x8, [x21]
	orr	x2, x8, x0
	mov	x0, x19
	bl	_wr32
Lloh19:
	adrp	x23, _ICE_PF_RESET_WAIT_COUNT@GOTPAGE
Lloh20:
	ldr	x23, [x23, _ICE_PF_RESET_WAIT_COUNT@GOTPAGEOFF]
	ldr	x8, [x23]
	cmp	x8, #1
	b.lt	LBB0_8
; %bb.5:
	mov	x22, #0
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x20]
	mov	x0, x19
	bl	_rd32
	ldr	x8, [x21]
	tst	x8, x0
	b.eq	LBB0_11
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	w0, #1
	bl	_mdelay
	add	x22, x22, #1
	ldr	x8, [x23]
	cmp	x22, x8
	b.lt	LBB0_6
	b	LBB0_9
LBB0_8:
	mov	x22, #0
LBB0_9:
	cmp	x22, x8
	b.ne	LBB0_12
LBB0_10:
Lloh21:
	adrp	x8, _ICE_DBG_INIT@GOTPAGE
Lloh22:
	ldr	x8, [x8, _ICE_DBG_INIT@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
Lloh24:
	adrp	x2, l_.str@PAGE
Lloh25:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_ice_debug
Lloh26:
	adrp	x8, _ICE_ERR_RESET_FAILED@GOTPAGE
Lloh27:
	ldr	x8, [x8, _ICE_ERR_RESET_FAILED@GOTPAGEOFF]
Lloh28:
	ldr	w0, [x8]
	b	LBB0_3
LBB0_11:
	ldr	x8, [x23]
	cmp	x22, x8
	b.eq	LBB0_10
LBB0_12:
	mov	w0, #0
	b	LBB0_3
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.cfi_endproc
                                        ; -- End function
	.comm	_GLGEN_RSTAT,4,2                ; @GLGEN_RSTAT
	.comm	_GLGEN_RSTAT_DEVSTATE_M,8,3     ; @GLGEN_RSTAT_DEVSTATE_M
	.comm	_GLNVM_ULD,4,2                  ; @GLNVM_ULD
	.comm	_ICE_RESET_DONE_MASK,8,3        ; @ICE_RESET_DONE_MASK
	.comm	_ICE_ERR_RESET_FAILED,4,2       ; @ICE_ERR_RESET_FAILED
	.comm	_PFGEN_CTRL,4,2                 ; @PFGEN_CTRL
	.comm	_PFGEN_CTRL_PFSWR_M,8,3         ; @PFGEN_CTRL_PFSWR_M
	.comm	_ICE_PF_RESET_WAIT_COUNT,8,3    ; @ICE_PF_RESET_WAIT_COUNT
	.comm	_ICE_DBG_INIT,4,2               ; @ICE_DBG_INIT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"PF reset polling failed to complete.\n"

	.no_dead_strip	_ice_pf_reset
.subsections_via_symbols
