	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gm20b_gr_init_gpc_mmu
_gm20b_gr_init_gpc_mmu:                 ## @gm20b_gr_init_gpc_mmu
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	(%rdi), %rbx
	cmpl	$0, (%rbx)
	jne	LBB0_3
## %bb.1:
	movq	%rbx, %rdi
	movl	$1051876, %esi                  ## imm = 0x100CE4
	movl	$-1, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$1051876, %esi                  ## imm = 0x100CE4
	callq	_nvkm_rd32
	cmpl	$-1, %eax
	je	LBB0_3
## %bb.2:
	leaq	L_.str(%rip), %rsi
	movq	%rbx, %rdi
	callq	_nvdev_warn
LBB0_3:
	movq	%rbx, %rdi
	movl	$1051776, %esi                  ## imm = 0x100C80
	callq	_nvkm_rd32
	andl	$-268429185, %eax               ## imm = 0xF000187F
	movq	%rbx, %rdi
	movl	$4294784, %esi                  ## imm = 0x418880
	movl	%eax, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$4294800, %esi                  ## imm = 0x418890
	xorl	%edx, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$4294804, %esi                  ## imm = 0x418894
	xorl	%edx, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$1051844, %esi                  ## imm = 0x100CC4
	callq	_nvkm_rd32
	movq	%rbx, %rdi
	movl	$4294832, %esi                  ## imm = 0x4188B0
	movl	%eax, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$1051848, %esi                  ## imm = 0x100CC8
	callq	_nvkm_rd32
	movq	%rbx, %rdi
	movl	$4294836, %esi                  ## imm = 0x4188B4
	movl	%eax, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$1051852, %esi                  ## imm = 0x100CCC
	callq	_nvkm_rd32
	movq	%rbx, %rdi
	movl	$4294840, %esi                  ## imm = 0x4188B8
	movl	%eax, %edx
	callq	_nvkm_wr32
	movq	%rbx, %rdi
	movl	$1050624, %esi                  ## imm = 0x100800
	callq	_nvkm_rd32
	movq	%rbx, %rdi
	movl	$4294828, %esi                  ## imm = 0x4188AC
	movl	%eax, %edx
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_nvkm_wr32                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"cannot bypass secure boot - expect failure soon!\n"

	.no_dead_strip	_gm20b_gr_init_gpc_mmu
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gm20b_gr_init_gpc_mmu
_gm20b_gr_init_gpc_mmu:                 ; @gm20b_gr_init_gpc_mmu
	.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	w20, #3300
	movk	w20, #16, lsl #16
	ldr	x19, [x0]
	ldr	w8, [x19]
	cbnz	w8, LBB0_3
; %bb.1:
	mov	x0, x19
	mov	w1, #3300
	movk	w1, #16, lsl #16
	mov	w2, #-1
	bl	_nvkm_wr32
	mov	x0, x19
	mov	w1, #3300
	movk	w1, #16, lsl #16
	bl	_nvkm_rd32
	cmn	w0, #1
	b.eq	LBB0_3
; %bb.2:
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	mov	x0, x19
	bl	_nvdev_warn
LBB0_3:
	sub	w1, w20, #100
	mov	x0, x19
	bl	_nvkm_rd32
	mov	w8, #6271
	movk	w8, #61440, lsl #16
	and	w2, w0, w8
	mov	w21, #34944
	movk	w21, #65, lsl #16
	mov	x0, x19
	mov	w1, #34944
	movk	w1, #65, lsl #16
	bl	_nvkm_wr32
	orr	w1, w21, #0x10
	mov	x0, x19
	mov	w2, #0
	bl	_nvkm_wr32
	mov	w8, #20
	orr	w1, w21, w8
	mov	x0, x19
	mov	w2, #0
	bl	_nvkm_wr32
	sub	w1, w20, #32
	mov	x0, x19
	bl	_nvkm_rd32
	mov	x2, x0
	orr	w1, w21, #0x30
	mov	x0, x19
	bl	_nvkm_wr32
	sub	w1, w20, #28
	mov	x0, x19
	bl	_nvkm_rd32
	mov	x2, x0
	mov	w8, #52
	orr	w1, w21, w8
	mov	x0, x19
	bl	_nvkm_wr32
	sub	w1, w20, #24
	mov	x0, x19
	bl	_nvkm_rd32
	mov	x2, x0
	orr	w1, w21, #0x38
	mov	x0, x19
	bl	_nvkm_wr32
	sub	w1, w20, #1252
	mov	x0, x19
	bl	_nvkm_rd32
	mov	x2, x0
	mov	w8, #44
	orr	w1, w21, w8
	mov	x0, x19
	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
	b	_nvkm_wr32
	.loh AdrpAdd	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"cannot bypass secure boot - expect failure soon!\n"

	.no_dead_strip	_gm20b_gr_init_gpc_mmu
.subsections_via_symbols
