	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amdgpu_device_ip_resume_phase2
_amdgpu_device_ip_resume_phase2:        ## @amdgpu_device_ip_resume_phase2
	.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
	movl	(%rdi), %r9d
	testl	%r9d, %r9d
	jle	LBB0_12
## %bb.1:
	movq	%rdi, %r15
	movq	8(%rdi), %rcx
	xorl	%ebx, %ebx
	movq	_AMD_IP_BLOCK_TYPE_COMMON@GOTPCREL(%rip), %r14
	movq	_AMD_IP_BLOCK_TYPE_GMC@GOTPCREL(%rip), %r12
	movq	_AMD_IP_BLOCK_TYPE_IH@GOTPCREL(%rip), %r8
	xorl	%r13d, %r13d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_11:                                ##   in Loop: Header=BB0_2 Depth=1
	incq	%r13
	movslq	%r9d, %rdx
	addq	$16, %rbx
	cmpq	%rdx, %r13
	jge	LBB0_12
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	$0, 4(%rcx,%rbx)
	je	LBB0_11
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpl	$0, (%rcx,%rbx)
	jne	LBB0_11
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rcx,%rbx), %rdx
	movq	(%rdx), %rsi
	cmpq	(%r14), %rsi
	je	LBB0_11
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpq	(%r12), %rsi
	je	LBB0_11
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	cmpq	(%r8), %rsi
	je	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_AMD_IP_BLOCK_TYPE_PSP@GOTPCREL(%rip), %rax
	cmpq	(%rax), %rsi
	je	LBB0_11
## %bb.8:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%rdx), %rax
	movq	%r15, %rdi
	callq	*(%rax)
	testl	%eax, %eax
	jne	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_2 Depth=1
	movq	8(%r15), %rcx
	movl	$1, (%rcx,%rbx)
	movl	(%r15), %r9d
	movq	_AMD_IP_BLOCK_TYPE_IH@GOTPCREL(%rip), %r8
	jmp	LBB0_11
LBB0_12:
	xorl	%eax, %eax
LBB0_13:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_9:
	movq	8(%r15), %rcx
	movq	8(%rcx,%rbx), %rcx
	movq	8(%rcx), %rcx
	movl	8(%rcx), %esi
	leaq	L_.str(%rip), %rdi
	movl	%eax, %ebx
	movl	%eax, %edx
	callq	_DRM_ERROR
	movl	%ebx, %eax
	jmp	LBB0_13
	.cfi_endproc
                                        ## -- End function
	.comm	_AMD_IP_BLOCK_TYPE_COMMON,8,3   ## @AMD_IP_BLOCK_TYPE_COMMON
	.comm	_AMD_IP_BLOCK_TYPE_GMC,8,3      ## @AMD_IP_BLOCK_TYPE_GMC
	.comm	_AMD_IP_BLOCK_TYPE_IH,8,3       ## @AMD_IP_BLOCK_TYPE_IH
	.comm	_AMD_IP_BLOCK_TYPE_PSP,8,3      ## @AMD_IP_BLOCK_TYPE_PSP
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"resume of IP block <%s> failed %d\n"

	.no_dead_strip	_amdgpu_device_ip_resume_phase2
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amdgpu_device_ip_resume_phase2
_amdgpu_device_ip_resume_phase2:        ; @amdgpu_device_ip_resume_phase2
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	ldr	w8, [x0]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.1:
	mov	x19, x0
	mov	x21, #0
	mov	x22, #0
Lloh0:
	adrp	x23, _AMD_IP_BLOCK_TYPE_COMMON@GOTPAGE
Lloh1:
	ldr	x23, [x23, _AMD_IP_BLOCK_TYPE_COMMON@GOTPAGEOFF]
Lloh2:
	adrp	x24, _AMD_IP_BLOCK_TYPE_GMC@GOTPAGE
Lloh3:
	ldr	x24, [x24, _AMD_IP_BLOCK_TYPE_GMC@GOTPAGEOFF]
	ldr	x9, [x0, #8]
Lloh4:
	adrp	x25, _AMD_IP_BLOCK_TYPE_IH@GOTPAGE
Lloh5:
	ldr	x25, [x25, _AMD_IP_BLOCK_TYPE_IH@GOTPAGEOFF]
	mov	w26, #1
Lloh6:
	adrp	x27, _AMD_IP_BLOCK_TYPE_PSP@GOTPAGE
Lloh7:
	ldr	x27, [x27, _AMD_IP_BLOCK_TYPE_PSP@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x22, x22, #1
	add	x21, x21, #16
	cmp	x22, w8, sxtw
	b.ge	LBB0_8
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	x10, x9, x21
	ldr	w10, [x10, #4]
	cbz	w10, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w10, [x9, x21]
	cbnz	w10, LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x10, x9, x21
	ldr	x10, [x10, #8]
	ldr	x11, [x10]
	ldr	x12, [x23]
	ldr	x13, [x24]
	ldr	x14, [x25]
	ldr	x15, [x27]
	cmp	x11, x12
	ccmp	x11, x13, #4, ne
	ccmp	x11, x14, #4, ne
	ccmp	x11, x15, #4, ne
	b.eq	LBB0_2
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x10, #8]
	ldr	x8, [x8]
	mov	x0, x19
	blr	x8
	cbnz	w0, LBB0_10
; %bb.7:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x9, [x19, #8]
	str	w26, [x9, x21]
	ldr	w8, [x19]
	b	LBB0_2
LBB0_8:
	mov	w20, #0
LBB0_9:
	mov	x0, x20
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_10:
	mov	x20, x0
	ldr	x8, [x19, #8]
	add	x8, x8, x21
	ldr	x8, [x8, #8]
	ldr	x8, [x8, #8]
	ldr	w1, [x8, #8]
Lloh8:
	adrp	x0, l_.str@PAGE
Lloh9:
	add	x0, x0, l_.str@PAGEOFF
	mov	x2, x20
	bl	_DRM_ERROR
	b	LBB0_9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_AMD_IP_BLOCK_TYPE_COMMON,8,3   ; @AMD_IP_BLOCK_TYPE_COMMON
	.comm	_AMD_IP_BLOCK_TYPE_GMC,8,3      ; @AMD_IP_BLOCK_TYPE_GMC
	.comm	_AMD_IP_BLOCK_TYPE_IH,8,3       ; @AMD_IP_BLOCK_TYPE_IH
	.comm	_AMD_IP_BLOCK_TYPE_PSP,8,3      ; @AMD_IP_BLOCK_TYPE_PSP
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"resume of IP block <%s> failed %d\n"

	.no_dead_strip	_amdgpu_device_ip_resume_phase2
.subsections_via_symbols
