	.file	"extr_ramgk104.c_gk104_ram_calc_sddr3.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	gk104_ram_calc_sddr3, @function
gk104_ram_calc_sddr3:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	mov	esi, 1112072
	mov	ecx, 1073741824
	mov	edx, 1073741824
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	lea	rbp, 48[rdi]
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 24
	.cfi_def_cfa_offset 80
	mov	r13d, DWORD PTR [rdi]
	mov	eax, DWORD PTR 4[rdi]
	mov	r14d, DWORD PTR 12[rdi]
	mov	rbx, QWORD PTR 40[rdi]
	sal	eax, 8
	sal	r13d, 16
	or	r13d, eax
	mov	eax, r14d
	or	r13d, DWORD PTR 8[rdi]
	mov	rdi, rbp
	sal	eax, 16
	mov	r15d, DWORD PTR 140[rbx]
	mov	DWORD PTR 4[rsp], eax
	mov	eax, DWORD PTR 136[rbx]
	mov	DWORD PTR 8[rsp], eax
	call	ram_mask@PLT
	mov	rdi, rbp
	call	ram_block@PLT
	mov	rax, QWORD PTR 32[r12]
	mov	esi, DWORD PTR NVKM_ENGINE_DISP[rip]
	mov	edi, DWORD PTR [rax]
	call	nvkm_device_engine@PLT
	test	rax, rax
	jne	.L71
.L2:
	test	r15d, r15d
	je	.L72
.L4:
	xor	ecx, ecx
	mov	edx, 2048
	mov	esi, 1110528
	mov	rdi, rbp
	call	ram_mask@PLT
	cmp	QWORD PTR 72[rbx], 0
	jne	.L73
.L6:
	mov	edx, 1
	mov	esi, 1110804
	mov	rdi, rbp
	call	ram_wr32@PLT
	cmp	QWORD PTR 48[rbx], 0
	jne	.L74
.L7:
	xor	edx, edx
	mov	esi, 1110544
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	edx, 1
	mov	esi, 1110800
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	ecx, -2147483648
	mov	edx, -2147483648
	mov	rdi, rbp
	mov	esi, 1110528
	call	ram_mask@PLT
	mov	edx, 1
	mov	esi, 1110800
	mov	rdi, rbp
	call	ram_wr32@PLT
	xor	ecx, ecx
	mov	edx, -2147483648
	mov	rdi, rbp
	mov	esi, 1110528
	call	ram_mask@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	mov	edx, 96
	mov	esi, 1110160
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	edx, -1073741698
	mov	esi, 1110160
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	eax, DWORD PTR [rbx]
	mov	ecx, -2146891808
	cmp	eax, 3
	ja	.L8
	lea	rdx, CSWTCH.21[rip]
	mov	ecx, DWORD PTR [rdx+rax*4]
.L8:
	mov	eax, DWORD PTR 4[rbx]
	cmp	eax, 2
	je	.L9
	jg	.L10
	test	eax, eax
	je	.L11
	cmp	eax, 1
	jne	.L13
	and	ecx, -524289
	.p2align 4,,10
	.p2align 3
.L13:
	cmp	QWORD PTR 120[rbx], 1
	sbb	eax, eax
	and	eax, -50331648
	sub	eax, 2096560160
	cmp	QWORD PTR 112[rbx], 0
	je	.L15
	or	ah, 32
.L15:
	cmp	QWORD PTR 104[rbx], 0
	je	.L16
	or	ah, 64
.L16:
	mov	edx, eax
	or	edx, 335544320
	cmp	QWORD PTR 96[rbx], 0
	je	.L18
	or	eax, 3
	mov	edx, eax
.L18:
	mov	esi, 1112100
	mov	rdi, rbp
	call	ram_mask@PLT
	xor	ecx, ecx
	mov	edx, 65536
	mov	rdi, rbp
	mov	esi, 1253440
	call	ram_mask@PLT
	mov	ecx, 65552
	xor	edx, edx
	mov	rdi, rbp
	mov	esi, 1274868
	call	ram_mask@PLT
	mov	esi, 1274860
	mov	rdi, rbp
	call	ram_rd32@PLT
	mov	edx, DWORD PTR 4[rbx]
	mov	esi, 1274860
	mov	rdi, rbp
	and	eax, -196609
	sal	edx, 16
	or	edx, eax
	call	ram_wr32@PLT
	xor	ecx, ecx
	mov	edx, 3
	mov	rdi, rbp
	mov	esi, 1274868
	call	ram_mask@PLT
	xor	ecx, ecx
	mov	esi, 1274868
	mov	rdi, rbp
	mov	edx, 16
	call	ram_mask@PLT
	mov	esi, 1253412
	mov	rdi, rbp
	call	ram_rd32@PLT
	cmp	eax, r13d
	je	.L19
.L21:
	xor	ecx, ecx
	mov	edx, 1
	mov	esi, 1253376
	mov	rdi, rbp
	call	ram_mask@PLT
	xor	ecx, ecx
	mov	edx, 1
	mov	rdi, rbp
	mov	esi, 1253408
	call	ram_mask@PLT
	xor	edx, edx
	mov	esi, 1274656
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	ecx, DWORD PTR 4[rsp]
	mov	edx, -65536
	mov	rdi, rbp
	mov	esi, 1253424
	call	ram_mask@PLT
	mov	ecx, r14d
	mov	edx, 65535
	mov	rdi, rbp
	mov	esi, 1253428
	call	ram_mask@PLT
	mov	edx, r13d
	mov	esi, 1253412
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	ecx, 524288
	mov	edx, 524288
	mov	rdi, rbp
	mov	esi, 1253416
	call	ram_mask@PLT
	mov	ecx, 1
	mov	edx, 1
	mov	rdi, rbp
	mov	esi, 1253408
	call	ram_mask@PLT
	mov	ecx, 131072
	mov	edx, 131072
	mov	rdi, rbp
	mov	esi, 1274768
	mov	r8d, 64000
	call	ram_wait@PLT
	xor	ecx, ecx
	mov	edx, 524288
	mov	rdi, rbp
	mov	esi, 1253416
	call	ram_mask@PLT
.L20:
	mov	ecx, 16
	mov	edx, 16
	mov	esi, 1274868
	mov	rdi, rbp
	call	ram_mask@PLT
	mov	ecx, 1
	mov	edx, 3
	mov	rdi, rbp
	mov	esi, 1274868
	call	ram_mask@PLT
	xor	ecx, ecx
	mov	esi, 1274868
	mov	rdi, rbp
	mov	edx, 65536
	call	ram_mask@PLT
	mov	esi, DWORD PTR gpioMV[rip]
	mov	rdi, rbp
	call	ram_have@PLT
	test	rax, rax
	jne	.L75
.L23:
	cmp	QWORD PTR 112[rbx], 0
	jne	.L25
	cmp	QWORD PTR 104[rbx], 0
	jne	.L25
.L26:
	cmp	DWORD PTR 16[r12], 2
	je	.L27
	cmp	QWORD PTR 128[rbx], 0
	jne	.L76
.L27:
	mov	eax, DWORD PTR 8[rbx]
	mov	esi, 1111644
	mov	rdi, rbp
	mov	edx, eax
	sal	edx, 4
	add	edx, eax
	call	ram_wr32@PLT
	imul	edx, DWORD PTR 12[rbx], 16843009
	mov	esi, 1111736
	mov	rdi, rbp
	call	ram_wr32@PLT
	imul	edx, DWORD PTR 12[rbx], 16843009
	mov	esi, 1111740
	mov	rdi, rbp
	call	ram_wr32@PLT
	cmp	QWORD PTR 120[rbx], 1
	sbb	eax, eax
	and	eax, 50331648
	cmp	QWORD PTR 112[rbx], 0
	jne	.L29
	or	ah, 32
.L29:
	cmp	QWORD PTR 104[rbx], 0
	jne	.L30
	or	ah, 64
.L30:
	mov	ecx, eax
	or	ecx, 335544320
	cmp	QWORD PTR 96[rbx], 0
	jne	.L32
	or	eax, 3
	mov	ecx, eax
.L32:
	mov	edx, 65536
	mov	esi, 1112100
	mov	rdi, rbp
	call	ram_mask@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	xor	ecx, ecx
	cmp	QWORD PTR 88[rbx], 0
	mov	rdi, rbp
	setne	cl
	mov	edx, 1048576
	mov	esi, 1112108
	sal	ecx, 20
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110600
	mov	ecx, DWORD PTR 40[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110672
	mov	ecx, DWORD PTR [rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110676
	mov	ecx, DWORD PTR 4[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110680
	mov	ecx, DWORD PTR 8[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110684
	mov	ecx, DWORD PTR 12[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110688
	mov	ecx, DWORD PTR 16[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110692
	mov	ecx, DWORD PTR 20[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110696
	mov	ecx, DWORD PTR 24[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110700
	mov	ecx, DWORD PTR 28[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110732
	mov	ecx, DWORD PTR 32[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, -1
	mov	rdi, rbp
	mov	esi, 1110760
	mov	ecx, DWORD PTR 36[rax]
	call	ram_mask@PLT
	cmp	DWORD PTR 80[rbx], 1
	mov	eax, DWORD PTR 56[rbx]
	sbb	ecx, ecx
	and	ecx, 538968064
	mov	edx, ecx
	or	edx, 310378496
	test	eax, eax
	cmove	ecx, edx
	cmp	QWORD PTR 72[rbx], 0
	je	.L36
	cmp	QWORD PTR 64[rbx], 0
	mov	edx, 871366656
	jne	.L77
.L37:
	or	ecx, 67108864
.L39:
	mov	esi, 1112072
	mov	rdi, rbp
	call	ram_mask@PLT
	imul	edx, DWORD PTR 24[rbx], 286331153
	mov	esi, 1112176
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	ecx, DWORD PTR 28[rbx]
	mov	edx, 1008
	mov	rdi, rbp
	mov	esi, 1110608
	sal	ecx, 4
	call	ram_mask@PLT
	mov	rax, QWORD PTR 16[rbx]
	mov	edx, 2130706432
	mov	rdi, rbp
	mov	esi, 1110604
	movsx	ecx, BYTE PTR 43[rax]
	and	ecx, 127
	cmp	DWORD PTR 32[rbx], ecx
	cmovge	ecx, DWORD PTR 32[rbx]
	sal	ecx, 24
	call	ram_mask@PLT
	mov	ecx, DWORD PTR 36[rbx]
	mov	edx, 2031616
	mov	rdi, rbp
	mov	esi, 1110564
	sal	ecx, 16
	call	ram_mask@PLT
	mov	edx, 1073741951
	mov	esi, 1110160
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	mov	edx, 1
	mov	esi, 1110804
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	edx, 1
	mov	esi, 1110800
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	edx, -2147483648
	mov	esi, 1110544
	mov	rdi, rbp
	call	ram_wr32@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	cmp	QWORD PTR 48[rbx], 0
	je	.L78
.L40:
	mov	rax, QWORD PTR 24[r12]
	mov	edx, 4095
	mov	rdi, rbp
	mov	ecx, DWORD PTR 8[rax]
	mov	rax, QWORD PTR mr[rip]
	mov	esi, DWORD PTR 8[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 24[r12]
	mov	edx, -1
	mov	rdi, rbp
	mov	ecx, DWORD PTR 4[rax]
	mov	rax, QWORD PTR mr[rip]
	mov	esi, DWORD PTR 4[rax]
	call	ram_mask@PLT
	mov	rax, QWORD PTR 24[r12]
	mov	rdi, rbp
	mov	edx, DWORD PTR [rax]
	mov	rax, QWORD PTR mr[rip]
	mov	esi, DWORD PTR [rax]
	call	ram_wr32@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	cmp	QWORD PTR 48[rbx], 0
	je	.L79
.L41:
	test	r15d, r15d
	jne	.L80
.L43:
	cmp	DWORD PTR 16[r12], 2
	je	.L45
	mov	ecx, 16777216
	mov	edx, 16777216
	mov	esi, 1112112
	mov	rdi, rbp
	call	ram_mask@PLT
	xor	ecx, ecx
	mov	edx, 16777216
	mov	rdi, rbp
	mov	esi, 1112112
	call	ram_mask@PLT
.L45:
	mov	ecx, -2147483648
	mov	edx, -2147483648
	mov	esi, 1110528
	mov	rdi, rbp
	call	ram_mask@PLT
	mov	edx, 1
	mov	esi, 1110808
	mov	rdi, rbp
	call	ram_wr32@PLT
	xor	ecx, ecx
	mov	edx, -2147483648
	mov	rdi, rbp
	mov	esi, 1110528
	call	ram_mask@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	mov	rdi, rbp
	call	ram_unblock@PLT
	mov	rax, QWORD PTR 32[r12]
	mov	esi, DWORD PTR NVKM_ENGINE_DISP[rip]
	mov	edi, DWORD PTR [rax]
	call	nvkm_device_engine@PLT
	test	rax, rax
	jne	.L81
.L46:
	xor	ecx, ecx
	cmp	QWORD PTR 40[rbx], 0
	mov	rdi, rbp
	mov	edx, 2048
	setne	cl
	mov	esi, 1110528
	sal	ecx, 11
	call	ram_mask@PLT
	add	rsp, 24
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	xor	eax, eax
	pop	rbx
	.cfi_def_cfa_offset 48
	pop	rbp
	.cfi_def_cfa_offset 40
	pop	r12
	.cfi_def_cfa_offset 32
	pop	r13
	.cfi_def_cfa_offset 24
	pop	r14
	.cfi_def_cfa_offset 16
	pop	r15
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L25:
	.cfi_restore_state
	mov	rdi, rbp
	mov	ecx, 65536
	mov	edx, 65536
	mov	esi, 1253440
	call	ram_mask@PLT
	mov	esi, 20000
	mov	rdi, rbp
	call	ram_nsec@PLT
	jmp	.L26
	.p2align 4,,10
	.p2align 3
.L10:
	mov	edx, ecx
	and	edx, -33
	cmp	eax, 3
	cmove	ecx, edx
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L36:
	or	ecx, 134217732
	mov	edx, 2012217376
	jmp	.L39
	.p2align 4,,10
	.p2align 3
.L77:
	mov	edx, 1005584420
	test	eax, eax
	je	.L37
	or	ecx, 32
	mov	edx, 1005584388
	jmp	.L37
	.p2align 4,,10
	.p2align 3
.L76:
	mov	ecx, -2147483648
	mov	edx, -2147483648
	mov	esi, 1111664
	mov	rdi, rbp
	call	ram_mask@PLT
	jmp	.L27
	.p2align 4,,10
	.p2align 3
.L19:
	mov	esi, 1253428
	mov	rdi, rbp
	call	ram_rd32@PLT
	movzx	eax, ax
	cmp	r14d, eax
	jne	.L21
	jmp	.L20
	.p2align 4,,10
	.p2align 3
.L75:
	mov	eax, DWORD PTR 8[rsp]
	xor	edx, edx
	mov	esi, DWORD PTR gpioMV[rip]
	mov	rdi, rbp
	test	eax, eax
	mov	rax, QWORD PTR 56[r12]
	sete	dl
	mov	ecx, DWORD PTR [rax+rdx*4]
	mov	edx, 12288
	call	ram_mask@PLT
	mov	esi, DWORD PTR gpioMV[rip]
	mov	rdi, rbp
	mov	r13d, eax
	call	ram_rd32@PLT
	cmp	eax, r13d
	je	.L23
	mov	esi, DWORD PTR gpiotrig[rip]
	mov	rdi, rbp
	mov	edx, 1
	call	ram_wr32@PLT
	mov	esi, 64000
	mov	rdi, rbp
	call	ram_nsec@PLT
	jmp	.L23
	.p2align 4,,10
	.p2align 3
.L80:
	mov	esi, DWORD PTR gpio2E[rip]
	mov	rdi, rbp
	call	ram_have@PLT
	test	rax, rax
	je	.L43
	mov	rax, QWORD PTR 48[r12]
	mov	esi, DWORD PTR gpio2E[rip]
	mov	rdi, rbp
	mov	edx, 12288
	mov	ecx, DWORD PTR [rax]
	call	ram_mask@PLT
	mov	esi, DWORD PTR gpio2E[rip]
	mov	rdi, rbp
	mov	r13d, eax
	call	ram_rd32@PLT
	cmp	eax, r13d
	je	.L43
	mov	esi, DWORD PTR gpiotrig[rip]
	mov	rdi, rbp
	mov	edx, 1
	call	ram_wr32@PLT
	mov	esi, 20000
	mov	rdi, rbp
	call	ram_nsec@PLT
	jmp	.L43
	.p2align 4,,10
	.p2align 3
.L81:
	mov	edx, 252645120
	mov	esi, 6471680
	mov	rdi, rbp
	call	ram_wr32@PLT
	jmp	.L46
	.p2align 4,,10
	.p2align 3
.L79:
	mov	rdi, rbp
	call	nvkm_sddr3_dll_reset@PLT
	mov	esi, 1000
	mov	rdi, rbp
	call	ram_nsec@PLT
	jmp	.L41
	.p2align 4,,10
	.p2align 3
.L78:
	mov	rax, QWORD PTR mr[rip]
	mov	rdi, rbp
	xor	ecx, ecx
	mov	edx, 1
	mov	esi, DWORD PTR 4[rax]
	call	ram_mask@PLT
	mov	rdi, rbp
	call	nvkm_sddr3_dll_reset@PLT
	jmp	.L40
	.p2align 4,,10
	.p2align 3
.L74:
	mov	rdi, rbp
	call	nvkm_sddr3_dll_disable@PLT
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L73:
	mov	ecx, 67108864
	mov	edx, 67108864
	mov	esi, 1112072
	mov	rdi, rbp
	call	ram_mask@PLT
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L72:
	mov	esi, DWORD PTR gpio2E[rip]
	mov	rdi, rbp
	call	ram_have@PLT
	test	rax, rax
	je	.L4
	mov	rax, QWORD PTR 48[r12]
	mov	esi, DWORD PTR gpio2E[rip]
	mov	rdi, rbp
	mov	edx, 12288
	mov	ecx, DWORD PTR 4[rax]
	call	ram_mask@PLT
	mov	esi, DWORD PTR gpio2E[rip]
	mov	rdi, rbp
	mov	DWORD PTR 12[rsp], eax
	call	ram_rd32@PLT
	cmp	eax, DWORD PTR 12[rsp]
	je	.L4
	mov	esi, DWORD PTR gpiotrig[rip]
	mov	rdi, rbp
	mov	edx, 1
	call	ram_wr32@PLT
	mov	esi, 20000
	mov	rdi, rbp
	call	ram_nsec@PLT
	jmp	.L4
	.p2align 4,,10
	.p2align 3
.L71:
	mov	edx, 252641280
	mov	esi, 6471680
	mov	rdi, rbp
	call	ram_wr32@PLT
	jmp	.L2
	.p2align 4,,10
	.p2align 3
.L11:
	and	ch, -3
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L9:
	and	cl, 127
	jmp	.L13
	.cfi_endproc
.LFE0:
	.size	gk104_ram_calc_sddr3, .-gk104_ram_calc_sddr3
	.section	.rodata
	.align 16
	.type	CSWTCH.21, @object
	.size	CSWTCH.21, 16
CSWTCH.21:
	.long	-2146892832
	.long	591840
	.long	-2146892064
	.long	-2146891872
	.comm	mr,8,8
	.comm	gpiotrig,4,4
	.comm	gpioMV,4,4
	.comm	gpio2E,4,4
	.comm	NVKM_ENGINE_DISP,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",@progbits
	.section	.note.gnu.property,"a"
	.align 8
	.long	 1f - 0f
	.long	 4f - 1f
	.long	 5
0:
	.string	 "GNU"
1:
	.align 8
	.long	 0xc0000002
	.long	 3f - 2f
2:
	.long	 0x3
3:
	.align 8
4:

	.arch armv5t
	.eabi_attribute 20, 1
	.eabi_attribute 21, 1
	.eabi_attribute 23, 3
	.eabi_attribute 24, 1
	.eabi_attribute 25, 1
	.eabi_attribute 26, 2
	.eabi_attribute 30, 2
	.eabi_attribute 34, 0
	.eabi_attribute 18, 4
	.file	"extr_ramgk104.c_gk104_ram_calc_sddr3.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	gk104_ram_calc_sddr3, %function
gk104_ram_calc_sddr3:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r4, r0
	mov	r3, #1073741824
	mov	r6, r0
	ldr	r7, [r0, #4]
	ldr	r2, [r4], #32
	ldr	ip, [r0, #8]
	ldr	r5, [r0, #28]
	lsl	r7, r7, #8
	orr	r7, r7, r2, lsl #16
	orr	r7, r7, ip
	ldr	ip, [r5, #84]
	mov	r2, r3
	sub	sp, sp, #20
	ldr	r1, .L107
	mov	r0, r4
	str	ip, [sp, #8]
	ldr	r8, [r6, #12]
	ldr	r10, [r5, #88]
	bl	ram_mask
	mov	r0, r4
	bl	ram_block
	ldr	r9, .L107+4
	ldr	r3, [r6, #24]
	ldr	r1, [r9]
	ldr	r0, [r3]
	bl	nvkm_device_engine
	cmp	r0, #0
	lsl	fp, r8, #16
	bne	.L97
.L2:
	cmp	r10, #0
	beq	.L98
.L4:
	mov	r3, #0
	mov	r2, #2048
	mov	r0, r4
	ldr	r1, .L107+8
	bl	ram_mask
	ldr	r3, [r5, #52]
	cmp	r3, #0
	bne	.L99
.L6:
	mov	r2, #1
	mov	r0, r4
	ldr	r1, .L107+12
	bl	ram_wr32
	ldr	r3, [r5, #40]
	cmp	r3, #0
	bne	.L100
.L7:
	mov	r2, #0
	ldr	r1, .L107+16
	mov	r0, r4
	bl	ram_wr32
	mov	r2, #1
	ldr	r1, .L107+20
	mov	r0, r4
	bl	ram_wr32
	mov	r3, #-2147483648
	ldr	r1, .L107+8
	mov	r2, r3
	mov	r0, r4
	bl	ram_mask
	mov	r2, #1
	ldr	r1, .L107+20
	mov	r0, r4
	bl	ram_wr32
	mov	r3, #0
	mov	r2, #-2147483648
	ldr	r1, .L107+8
	mov	r0, r4
	bl	ram_mask
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	mov	r2, #96
	ldr	r1, .L107+24
	mov	r0, r4
	bl	ram_wr32
	ldr	r2, .L107+28
	mov	r0, r4
	ldr	r1, .L107+24
	bl	ram_wr32
	ldr	r3, [r5]
	cmp	r3, #3
	ldrls	r2, .L107+32
	ldrhi	r3, .L107+36
	ldrls	r3, [r2, r3, lsl #2]
	ldr	r2, [r5, #4]
	cmp	r2, #3
	ldrls	pc, [pc, r2, asl #2]
	b	.L9
.L11:
	.word	.L14
	.word	.L13
	.word	.L12
	.word	.L10
.L14:
	bic	r3, r3, #512
.L9:
	ldr	ip, [r5, #76]
	ldr	r0, .L107+40
	cmp	ip, #0
	ldr	r2, .L107+36
	movne	r2, r0
	ldr	r1, [r5, #72]
	mov	r0, r4
	cmp	r1, #0
	ldr	r1, [r5, #68]
	orrne	r2, r2, #8192
	cmp	r1, #0
	ldr	r1, [r5, #64]
	orrne	r2, r2, #16384
	cmp	r1, #0
	orrne	r2, r2, #3
	orreq	r2, r2, #335544320
	ldr	r1, .L107+44
	bl	ram_mask
	mov	r3, #0
	mov	r2, #65536
	ldr	r1, .L107+48
	mov	r0, r4
	bl	ram_mask
	ldr	r3, .L107+52
	mov	r2, #0
	ldr	r1, .L107+56
	mov	r0, r4
	bl	ram_mask
	ldr	r1, .L107+60
	mov	r0, r4
	bl	ram_rd32
	ldr	r2, [r5, #4]
	bic	r0, r0, #196608
	orr	r2, r0, r2, lsl #16
	ldr	r1, .L107+60
	mov	r0, r4
	bl	ram_wr32
	mov	r3, #0
	mov	r2, #3
	ldr	r1, .L107+56
	mov	r0, r4
	bl	ram_mask
	mov	r3, #0
	mov	r2, #16
	ldr	r1, .L107+56
	mov	r0, r4
	bl	ram_mask
	mov	r0, r4
	ldr	r1, .L107+64
	bl	ram_rd32
	cmp	r0, r7
	beq	.L20
.L22:
	mov	r3, #0
	mov	r2, #1
	ldr	r1, .L107+68
	mov	r0, r4
	bl	ram_mask
	mov	r3, #0
	mov	r2, #1
	ldr	r1, .L107+72
	mov	r0, r4
	bl	ram_mask
	mov	r2, #0
	ldr	r1, .L107+76
	mov	r0, r4
	bl	ram_wr32
	mov	r3, fp
	ldr	r2, .L107+80
	ldr	r1, .L107+84
	mov	r0, r4
	bl	ram_mask
	mov	r3, r8
	ldr	r2, .L107+88
	ldr	r1, .L107+92
	mov	r0, r4
	bl	ram_mask
	mov	r2, r7
	ldr	r1, .L107+64
	mov	r0, r4
	bl	ram_wr32
	mov	r3, #524288
	ldr	r1, .L107+96
	mov	r2, r3
	mov	r0, r4
	bl	ram_mask
	mov	r3, #1
	ldr	r1, .L107+72
	mov	r2, r3
	mov	r0, r4
	bl	ram_mask
	mov	r3, #131072
	mov	r2, #64000
	ldr	r1, .L107+100
	str	r2, [sp]
	mov	r0, r4
	mov	r2, r3
	bl	ram_wait
	mov	r3, #0
	mov	r2, #524288
	mov	r0, r4
	ldr	r1, .L107+96
	bl	ram_mask
.L21:
	mov	r3, #16
	ldr	r1, .L107+56
	mov	r2, r3
	mov	r0, r4
	bl	ram_mask
	ldr	r7, .L107+104
	mov	r3, #1
	mov	r2, #3
	ldr	r1, .L107+56
	mov	r0, r4
	bl	ram_mask
	mov	r3, #0
	mov	r2, #65536
	ldr	r1, .L107+56
	mov	r0, r4
	bl	ram_mask
	mov	r0, r4
	ldr	r1, [r7]
	bl	ram_have
	cmp	r0, #0
	bne	.L101
.L24:
	ldr	r3, [r5, #72]
	cmp	r3, #0
	bne	.L26
	ldr	r3, [r5, #68]
	cmp	r3, #0
	bne	.L26
.L27:
	ldr	r3, [r6, #16]
	cmp	r3, #2
	beq	.L28
	ldr	r3, [r5, #80]
	cmp	r3, #0
	bne	.L102
.L28:
	ldr	r2, [r5, #8]
	ldr	r1, .L107+108
	add	r2, r2, r2, lsl #4
	mov	r0, r4
	bl	ram_wr32
	ldr	r2, [r5, #12]
	ldr	r1, .L107+112
	add	r2, r2, r2, lsl #8
	add	r2, r2, r2, lsl #16
	mov	r0, r4
	bl	ram_wr32
	ldr	r2, [r5, #12]
	ldr	r1, .L107+116
	add	r2, r2, r2, lsl #8
	add	r2, r2, r2, lsl #16
	mov	r0, r4
	bl	ram_wr32
	ldr	r3, [r5, #76]
	ldr	r2, [r5, #72]
	cmp	r3, #0
	moveq	r3, #50331648
	movne	r3, #0
	cmp	r2, #0
	ldr	r2, [r5, #68]
	orreq	r3, r3, #8192
	cmp	r2, #0
	ldr	r2, [r5, #64]
	orreq	r3, r3, #16384
	cmp	r2, #0
	orreq	r3, r3, #3
	orrne	r3, r3, #335544320
	mov	r2, #65536
	ldr	r1, .L107+44
	mov	r0, r4
	bl	ram_mask
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	mov	r2, #1048576
	ldr	r3, [r5, #60]
	ldr	r1, .L107+120
	cmp	r3, #0
	movne	r3, r2
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #40]
	ldr	r1, .L107+124
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3]
	ldr	r1, .L107+128
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #4]
	ldr	r1, .L107+132
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #8]
	ldr	r1, .L107+136
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #12]
	ldr	r1, .L107+140
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #16]
	ldr	r1, .L107+144
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #20]
	ldr	r1, .L107+148
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #24]
	ldr	r1, .L107+152
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #28]
	ldr	r1, .L107+156
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #32]
	ldr	r1, .L107+160
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	mvn	r2, #0
	ldr	r3, [r3, #36]
	ldr	r1, .L107+164
	mov	r0, r4
	bl	ram_mask
	ldr	r1, [r5, #56]
	ldr	r2, [r5, #44]
	cmp	r1, #0
	ldr	r3, .L107+168
	ldr	r1, [r5, #52]
	movne	r3, #0
	cmp	r2, #0
	orreq	r3, r3, #310378496
	cmp	r1, #0
	beq	.L37
	ldr	r1, [r5, #48]
	cmp	r1, #0
	ldreq	r2, .L107+172
	bne	.L103
.L38:
	orr	r3, r3, #67108864
.L40:
	ldr	r1, .L107
	mov	r0, r4
	bl	ram_mask
	ldr	r2, [r5, #20]
	ldr	r1, .L107+176
	add	r2, r2, r2, lsl #4
	add	r2, r2, r2, lsl #8
	add	r2, r2, r2, lsl #16
	mov	r0, r4
	bl	ram_wr32
	ldr	r3, [r5, #24]
	mov	r2, #1008
	ldr	r1, .L107+180
	lsl	r3, r3, #4
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r5, #16]
	ldr	r1, [r5, #28]
	ldrsb	r3, [r3, #43]
	mov	r2, #2130706432
	and	r3, r3, #127
	cmp	r3, r1
	movlt	r3, r1
	mov	r0, r4
	ldr	r1, .L107+184
	lsl	r3, r3, #24
	bl	ram_mask
	ldr	r3, [r5, #32]
	mov	r2, #2031616
	lsl	r3, r3, #16
	ldr	r1, .L107+188
	mov	r0, r4
	bl	ram_mask
	ldr	r2, .L107+192
	ldr	r1, .L107+24
	mov	r0, r4
	bl	ram_wr32
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	mov	r2, #1
	ldr	r1, .L107+12
	mov	r0, r4
	bl	ram_wr32
	mov	r2, #1
	ldr	r1, .L107+20
	mov	r0, r4
	bl	ram_wr32
	mov	r2, #-2147483648
	ldr	r1, .L107+16
	mov	r0, r4
	bl	ram_wr32
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	ldr	r3, [r5, #40]
	ldr	r7, .L107+196
	cmp	r3, #0
	beq	.L94
.L41:
	ldr	r2, [r7]
	ldr	r3, [r6, #20]
	ldr	r1, [r2, #8]
	ldr	r3, [r3, #8]
	ldr	r2, .L107+200
	mov	r0, r4
	bl	ram_mask
	ldr	r2, [r7]
	ldr	r3, [r6, #20]
	ldr	r1, [r2, #4]
	ldr	r3, [r3, #4]
	mvn	r2, #0
	mov	r0, r4
	bl	ram_mask
	ldr	r3, [r6, #20]
	ldr	r2, [r7]
	mov	r0, r4
	ldr	r1, [r2]
	ldr	r2, [r3]
	bl	ram_wr32
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	ldr	r3, [r5, #40]
	cmp	r3, #0
	beq	.L104
	cmp	r10, #0
	bne	.L105
.L44:
	ldr	r3, [r6, #16]
	cmp	r3, #2
	beq	.L46
	mov	r3, #16777216
	ldr	r1, .L107+204
	mov	r2, r3
	mov	r0, r4
	bl	ram_mask
	mov	r3, #0
	mov	r2, #16777216
	mov	r0, r4
	ldr	r1, .L107+204
	bl	ram_mask
.L46:
	mov	r3, #-2147483648
	ldr	r1, .L107+8
	mov	r2, r3
	mov	r0, r4
	bl	ram_mask
	mov	r2, #1
	ldr	r1, .L107+208
	mov	r0, r4
	bl	ram_wr32
	mov	r3, #0
	mov	r2, #-2147483648
	ldr	r1, .L107+8
	mov	r0, r4
	bl	ram_mask
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	mov	r0, r4
	bl	ram_unblock
	ldr	r3, [r6, #24]
	ldr	r1, [r9]
	ldr	r0, [r3]
	bl	nvkm_device_engine
	cmp	r0, #0
	bne	.L106
.L47:
	ldr	r3, [r5, #36]
	mov	r0, r4
	cmp	r3, #0
	movne	r3, #2048
	mov	r2, #2048
	ldr	r1, .L107+8
	bl	ram_mask
	mov	r0, #0
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L26:
	mov	r3, #65536
	mov	r0, r4
	mov	r2, r3
	ldr	r1, .L107+48
	bl	ram_mask
	mov	r0, r4
	ldr	r1, .L107+212
	bl	ram_nsec
	b	.L27
.L37:
	orr	r3, r3, #134217728
	ldr	r2, .L107+216
	orr	r3, r3, #4
	b	.L40
.L103:
	cmp	r2, #0
	ldrne	r2, .L107+220
	ldreq	r2, .L107+224
	orrne	r3, r3, #32
	b	.L38
.L10:
	bic	r3, r3, #32
	b	.L9
.L12:
	bic	r3, r3, #128
	b	.L9
.L13:
	bic	r3, r3, #524288
	b	.L9
.L102:
	mov	r3, #-2147483648
	mov	r0, r4
	mov	r2, r3
	ldr	r1, .L107+228
	bl	ram_mask
	b	.L28
.L20:
	mov	r0, r4
	ldr	r1, .L107+92
	bl	ram_rd32
	lsl	r0, r0, #16
	lsr	r0, r0, #16
	cmp	r8, r0
	bne	.L22
	b	.L21
.L101:
	ldr	r3, [sp, #8]
	ldr	r2, [r6, #36]
	clz	r3, r3
	lsr	r3, r3, #5
	ldr	r3, [r2, r3, lsl #2]
	ldr	r1, [r7]
	mov	r2, #12288
	mov	r0, r4
	bl	ram_mask
	mov	r3, r0
	ldr	r1, [r7]
	mov	r0, r4
	mov	r7, r3
	bl	ram_rd32
	cmp	r0, r7
	beq	.L24
	ldr	r3, .L107+232
	mov	r2, #1
	ldr	r1, [r3]
	mov	r0, r4
	bl	ram_wr32
	mov	r1, #64000
	mov	r0, r4
	bl	ram_nsec
	b	.L24
.L104:
	mov	r0, r4
	bl	nvkm_sddr3_dll_reset
	mov	r1, #1000
	mov	r0, r4
	bl	ram_nsec
	cmp	r10, #0
	beq	.L44
.L105:
	ldr	r7, .L107+236
	mov	r0, r4
	ldr	r1, [r7]
	bl	ram_have
	cmp	r0, #0
	beq	.L44
	ldr	r3, [r6, #32]
	ldr	r1, [r7]
	mov	r2, #12288
	ldr	r3, [r3]
	mov	r0, r4
	bl	ram_mask
	mov	r3, r0
	ldr	r1, [r7]
	mov	r0, r4
	mov	r7, r3
	bl	ram_rd32
	cmp	r0, r7
	beq	.L44
	ldr	r3, .L107+232
	mov	r2, #1
	ldr	r1, [r3]
	mov	r0, r4
	bl	ram_wr32
	mov	r0, r4
	ldr	r1, .L107+212
	bl	ram_nsec
	b	.L44
.L94:
	ldr	r1, [r7]
	mov	r2, #1
	mov	r0, r4
	ldr	r1, [r1, #4]
	bl	ram_mask
	mov	r0, r4
	bl	nvkm_sddr3_dll_reset
	b	.L41
.L106:
	mov	r0, r4
	ldr	r2, .L107+240
	ldr	r1, .L107+244
	bl	ram_wr32
	b	.L47
.L100:
	mov	r0, r4
	bl	nvkm_sddr3_dll_disable
	b	.L7
.L99:
	mov	r3, #67108864
	mov	r0, r4
	mov	r2, r3
	ldr	r1, .L107
	bl	ram_mask
	b	.L6
.L98:
	ldr	r3, .L107+236
	mov	r0, r4
	ldr	r1, [r3]
	bl	ram_have
	cmp	r0, #0
	beq	.L4
	ldr	r3, [r6, #32]
	ldr	r1, .L107+236
	mov	r2, #12288
	ldr	r3, [r3, #4]
	ldr	r1, [r1]
	mov	r0, r4
	bl	ram_mask
	mov	r3, r0
	ldr	r1, .L107+236
	mov	r0, r4
	ldr	r1, [r1]
	str	r3, [sp, #12]
	bl	ram_rd32
	ldr	r3, [sp, #12]
	cmp	r0, r3
	beq	.L4
	ldr	r3, .L107+232
	mov	r2, #1
	ldr	r1, [r3]
	mov	r0, r4
	bl	ram_wr32
	mov	r0, r4
	ldr	r1, .L107+212
	bl	ram_nsec
	b	.L4
.L97:
	mov	r0, r4
	ldr	r2, .L107+248
	ldr	r1, .L107+244
	bl	ram_wr32
	b	.L2
.L108:
	.align	2
.L107:
	.word	1112072
	.word	NVKM_ENGINE_DISP
	.word	1110528
	.word	1110804
	.word	1110544
	.word	1110800
	.word	1110160
	.word	-1073741698
	.word	.LANCHOR0
	.word	-2146891808
	.word	-2096560160
	.word	1112100
	.word	1253440
	.word	65552
	.word	1274868
	.word	1274860
	.word	1253412
	.word	1253376
	.word	1253408
	.word	1274656
	.word	-65536
	.word	1253424
	.word	65535
	.word	1253428
	.word	1253416
	.word	1274768
	.word	gpioMV
	.word	1111644
	.word	1111736
	.word	1111740
	.word	1112108
	.word	1110600
	.word	1110672
	.word	1110676
	.word	1110680
	.word	1110684
	.word	1110688
	.word	1110692
	.word	1110696
	.word	1110700
	.word	1110732
	.word	1110760
	.word	538968064
	.word	871366656
	.word	1112176
	.word	1110608
	.word	1110604
	.word	1110564
	.word	1073741951
	.word	mr
	.word	4095
	.word	1112112
	.word	1110808
	.word	20000
	.word	2012217376
	.word	1005584388
	.word	1005584420
	.word	1111664
	.word	gpiotrig
	.word	gpio2E
	.word	252645120
	.word	6471680
	.word	252641280
	.size	gk104_ram_calc_sddr3, .-gk104_ram_calc_sddr3
	.comm	mr,4,4
	.comm	gpiotrig,4,4
	.comm	gpioMV,4,4
	.comm	gpio2E,4,4
	.comm	NVKM_ENGINE_DISP,4,4
	.section	.rodata
	.align	2
	.set	.LANCHOR0,. + 0
	.type	CSWTCH.22, %object
	.size	CSWTCH.22, 16
CSWTCH.22:
	.word	-2146892832
	.word	591840
	.word	-2146892064
	.word	-2146891872
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
