	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function nv_crtc_restore
_nv_crtc_restore:                       ## @nv_crtc_restore
	.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, %rbx
	callq	_nouveau_crtc
	movq	%rax, %r14
	movq	(%rbx), %r13
	movslq	(%rax), %r15
	movq	%r13, %rdi
	callq	_nv04_display
	movq	(%rax), %rax
	movq	(%rax,%r15,8), %rax
	movq	_NV_CIO_CRE_21@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movl	(%rax,%rcx,4), %eax
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	(%rbx), %rdi
	callq	_nv_two_heads
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movq	(%rbx), %rdi
	movl	%r15d, %esi
	callq	_NVSetOwner
LBB0_2:
	movq	(%rbx), %r12
	movq	%r13, %rdi
	callq	_nv04_display
	movq	%r12, %rdi
	movl	%r15d, %esi
	movq	%rax, %rdx
	callq	_nouveau_hw_load_state
	movq	(%rbx), %rdi
	movl	%r15d, %esi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	callq	_nv_lock_vga_crtc_shadow
	movq	_NV_DPMS_CLEARED@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%r14)
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NV_CIO_CRE_21,8,3              ## @NV_CIO_CRE_21
	.comm	_NV_DPMS_CLEARED,4,2            ## @NV_DPMS_CLEARED
	.no_dead_strip	_nv_crtc_restore
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function nv_crtc_restore
_nv_crtc_restore:                       ; @nv_crtc_restore
	.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	x20, x0
	bl	_nouveau_crtc
	mov	x19, x0
	ldr	x23, [x20]
	ldrsw	x21, [x0]
	mov	x0, x23
	bl	_nv04_display
	ldr	x8, [x0]
	ldr	x8, [x8, x21, lsl #3]
Lloh0:
	adrp	x9, _NV_CIO_CRE_21@GOTPAGE
Lloh1:
	ldr	x9, [x9, _NV_CIO_CRE_21@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	ldr	w22, [x8, x9, lsl #2]
	ldr	x0, [x20]
	bl	_nv_two_heads
	cbz	x0, LBB0_2
; %bb.1:
	ldr	x0, [x20]
	mov	x1, x21
	bl	_NVSetOwner
LBB0_2:
	ldr	x24, [x20]
	mov	x0, x23
	bl	_nv04_display
	mov	x2, x0
	mov	x0, x24
	mov	x1, x21
	bl	_nouveau_hw_load_state
	ldr	x0, [x20]
	mov	x1, x21
	mov	x2, x22
	bl	_nv_lock_vga_crtc_shadow
Lloh3:
	adrp	x8, _NV_DPMS_CLEARED@GOTPAGE
Lloh4:
	ldr	x8, [x8, _NV_DPMS_CLEARED@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [x19, #4]
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_NV_CIO_CRE_21,8,3              ; @NV_CIO_CRE_21
	.comm	_NV_DPMS_CLEARED,4,2            ; @NV_DPMS_CLEARED
	.no_dead_strip	_nv_crtc_restore
.subsections_via_symbols
