	.file	"extr_kvm_minidump_mips.c__mips_minidump_kvatop.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"_mips_minidump_kvatop called in live kernel!"
	.align 8
.LC1:
	.string	"_mips_minidump_kvatop: virtual address 0x%jx not minidumped"
	.align 8
.LC2:
	.string	"_mips_minidump_kvatop: physical address 0x%jx not in minidump"
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC3:
	.string	"invalid address (0x%jx)"
	.section	.rodata.str1.8
	.align 8
.LC4:
	.string	"_mips_minidump_kvatop: pte not valid"
	.text
	.p2align 4
	.type	_mips_minidump_kvatop, @function
_mips_minidump_kvatop:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	mov	r13, rdx
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	mov	ebx, esi
	sub	rsp, 8
	.cfi_def_cfa_offset 64
	call	ISALIVE@PLT
	test	rax, rax
	jne	.L26
	mov	r14d, DWORD PTR MIPS_PAGE_MASK[rip]
	mov	rax, QWORD PTR 8[rbp]
	mov	rdx, QWORD PTR EI_CLASS[rip]
	mov	rcx, QWORD PTR ELFCLASS64[rip]
	mov	r12d, r14d
	not	r12d
	and	r12d, ebx
	cmp	QWORD PTR [rax+rdx*8], rcx
	je	.L27
	cmp	DWORD PTR MIPS32_KSEG0_START[rip], r12d
	jle	.L28
.L9:
	cmp	DWORD PTR MIPS32_KSEG1_START[rip], r12d
	jg	.L8
	cmp	DWORD PTR MIPS32_KSEG1_END[rip], r12d
	jg	.L24
.L8:
	mov	rax, QWORD PTR 16[rbp]
	mov	edx, DWORD PTR 4[rax]
	cmp	edx, r12d
	jg	.L10
	mov	esi, r12d
	mov	ecx, DWORD PTR MIPS_PAGE_SHIFT[rip]
	sub	esi, edx
	movsx	rdx, DWORD PTR 8[rax]
	sar	esi, cl
	shr	rdx, 2
	cmp	DWORD PTR [rax], 64
	movsx	rcx, esi
	je	.L29
	cmp	rdx, rcx
	ja	.L30
.L12:
	mov	ecx, r12d
	mov	rdi, rbp
	lea	rdx, .LC3[rip]
	xor	esi, esi
	xor	eax, eax
	call	_kvm_err@PLT
	add	rsp, 8
	.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
.L28:
	.cfi_restore_state
	cmp	DWORD PTR MIPS32_KSEG0_END[rip], r12d
	jle	.L9
.L24:
	mov	r15d, DWORD PTR MIPS_KSEG0_PHYS_MASK[rip]
	and	r15d, r12d
.L6:
	mov	edx, DWORD PTR MIPS_PAGE_SIZE[rip]
	mov	esi, r15d
	mov	rdi, rbp
	call	_kvm_pt_find@PLT
	cmp	eax, -1
	je	.L31
	and	ebx, r14d
	add	eax, ebx
	mov	DWORD PTR 0[r13], eax
	mov	eax, DWORD PTR MIPS_PAGE_SIZE[rip]
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	sub	eax, ebx
	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
.L27:
	.cfi_restore_state
	cmp	DWORD PTR MIPS_XKPHYS_START[rip], r12d
	jg	.L5
	mov	r15d, DWORD PTR MIPS_XKPHYS_PHYS_MASK[rip]
	and	r15d, r12d
	cmp	DWORD PTR MIPS_XKPHYS_END[rip], r12d
	jg	.L6
.L5:
	cmp	DWORD PTR MIPS64_KSEG0_START[rip], r12d
	jle	.L32
.L7:
	cmp	DWORD PTR MIPS64_KSEG1_START[rip], r12d
	jg	.L8
	cmp	DWORD PTR MIPS64_KSEG1_END[rip], r12d
	jle	.L8
	jmp	.L24
	.p2align 4,,10
	.p2align 3
.L26:
	mov	rdi, rbp
	lea	rdx, .LC0[rip]
	xor	esi, esi
	xor	eax, eax
	call	_kvm_err@PLT
	add	rsp, 8
	.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
.L30:
	.cfi_restore_state
	mov	rdi, rbp
	call	_mips32_pte_get@PLT
	test	DWORD PTR MIPS_PTE_V[rip], eax
	jne	.L33
.L13:
	mov	esi, DWORD PTR 0[rbp]
	lea	rdx, .LC4[rip]
	mov	rdi, rbp
	xor	eax, eax
	call	_kvm_err@PLT
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L32:
	cmp	DWORD PTR MIPS64_KSEG0_END[rip], r12d
	jle	.L7
	jmp	.L24
	.p2align 4,,10
	.p2align 3
.L29:
	cmp	rdx, rcx
	jbe	.L12
	mov	rdi, rbp
	call	_mips64_pte_get@PLT
	test	DWORD PTR MIPS_PTE_V[rip], eax
	je	.L13
	mov	edi, eax
	call	MIPS64_PTE_TO_PA@PLT
	mov	r15d, eax
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L10:
	mov	esi, DWORD PTR 0[rbp]
	mov	ecx, r12d
	mov	rdi, rbp
	lea	rdx, .LC1[rip]
	xor	eax, eax
	call	_kvm_err@PLT
	add	rsp, 8
	.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
.L31:
	.cfi_restore_state
	mov	esi, DWORD PTR 0[rbp]
	mov	ecx, r15d
	lea	rdx, .LC2[rip]
	mov	rdi, rbp
	xor	eax, eax
	call	_kvm_err@PLT
	jmp	.L12
	.p2align 4,,10
	.p2align 3
.L33:
	mov	edi, eax
	call	MIPS32_PTE_TO_PA@PLT
	mov	r15d, eax
	jmp	.L6
	.cfi_endproc
.LFE0:
	.size	_mips_minidump_kvatop, .-_mips_minidump_kvatop
	.comm	MIPS_XKPHYS_START,4,4
	.comm	MIPS_XKPHYS_PHYS_MASK,4,4
	.comm	MIPS_XKPHYS_END,4,4
	.comm	MIPS_PTE_V,4,4
	.comm	MIPS_PAGE_SIZE,4,4
	.comm	MIPS_PAGE_SHIFT,4,4
	.comm	MIPS_PAGE_MASK,4,4
	.comm	MIPS_KSEG0_PHYS_MASK,4,4
	.comm	MIPS64_KSEG1_START,4,4
	.comm	MIPS64_KSEG1_END,4,4
	.comm	MIPS64_KSEG0_START,4,4
	.comm	MIPS64_KSEG0_END,4,4
	.comm	MIPS32_KSEG1_START,4,4
	.comm	MIPS32_KSEG1_END,4,4
	.comm	MIPS32_KSEG0_START,4,4
	.comm	MIPS32_KSEG0_END,4,4
	.comm	ELFCLASS64,8,8
	.comm	EI_CLASS,8,8
	.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_kvm_minidump_mips.c__mips_minidump_kvatop.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"_mips_minidump_kvatop called in live kernel!\000"
	.align	2
.LC1:
	.ascii	"_mips_minidump_kvatop: virtual address 0x%jx not mi"
	.ascii	"nidumped\000"
	.align	2
.LC2:
	.ascii	"_mips_minidump_kvatop: physical address 0x%jx not i"
	.ascii	"n minidump\000"
	.align	2
.LC3:
	.ascii	"invalid address (0x%jx)\000"
	.align	2
.LC4:
	.ascii	"_mips_minidump_kvatop: pte not valid\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	_mips_minidump_kvatop, %function
_mips_minidump_kvatop:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	mov	r7, r1
	mov	r8, r2
	mov	r5, r0
	bl	ISALIVE
	subs	r4, r0, #0
	bne	.L26
	ldr	r3, .L35
	ldr	r2, [r5, #4]
	ldr	r1, [r3]
	ldr	r3, .L35+4
	ldr	r2, [r2, r1, lsl #2]
	ldr	r1, .L35+8
	ldr	r3, [r3]
	ldr	r9, [r1]
	cmp	r2, r3
	bic	r6, r7, r9
	beq	.L27
	ldr	r3, .L35+12
	ldr	r3, [r3]
	cmp	r3, r6
	ble	.L28
.L9:
	ldr	r3, .L35+16
	ldr	r3, [r3]
	cmp	r3, r6
	bgt	.L8
	ldr	r3, .L35+20
	ldr	r3, [r3]
	cmp	r3, r6
	bgt	.L24
.L8:
	ldr	r2, [r5, #8]
	ldr	r3, [r2, #4]
	cmp	r3, r6
	bgt	.L10
	ldr	r1, .L35+24
	ldr	r0, [r2]
	ldr	r1, [r1]
	ldr	r2, [r2, #8]
	sub	r3, r6, r3
	cmp	r0, #64
	asr	r1, r3, r1
	lsr	r3, r2, #2
	beq	.L29
	cmp	r1, r3
	bcc	.L30
.L12:
	mov	r3, r6
	mov	r0, r5
	mov	r1, #0
	ldr	r2, .L35+28
	bl	_kvm_err
	mov	r0, r4
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L28:
	ldr	r3, .L35+32
	ldr	r3, [r3]
	cmp	r3, r6
	ble	.L9
.L24:
	ldr	r3, .L35+36
	ldr	fp, [r3]
	and	fp, fp, r6
.L6:
	ldr	r10, .L35+40
	mov	r1, fp
	mov	r0, r5
	ldr	r2, [r10]
	bl	_kvm_pt_find
	cmn	r0, #1
	beq	.L31
	and	r7, r7, r9
	add	r0, r7, r0
	str	r0, [r8]
	ldr	r4, [r10]
	sub	r4, r4, r7
	mov	r0, r4
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L27:
	ldr	r3, .L35+44
	ldr	r3, [r3]
	cmp	r3, r6
	bgt	.L5
	ldr	r3, .L35+48
	ldr	r3, [r3]
	cmp	r3, r6
	bgt	.L32
.L5:
	ldr	r3, .L35+52
	ldr	r3, [r3]
	cmp	r3, r6
	ble	.L33
.L7:
	ldr	r3, .L35+56
	ldr	r3, [r3]
	cmp	r3, r6
	bgt	.L8
	ldr	r3, .L35+60
	ldr	r3, [r3]
	cmp	r3, r6
	ble	.L8
	b	.L24
.L26:
	mov	r4, #0
	mov	r0, r5
	mov	r1, #0
	ldr	r2, .L35+64
	bl	_kvm_err
	mov	r0, r4
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L30:
	mov	r0, r5
	bl	_mips32_pte_get
	ldr	r3, .L35+68
	ldr	r3, [r3]
	tst	r0, r3
	bne	.L34
.L13:
	mov	r0, r5
	ldr	r2, .L35+72
	ldr	r1, [r5]
	bl	_kvm_err
	b	.L12
.L33:
	ldr	r3, .L35+76
	ldr	r3, [r3]
	cmp	r3, r6
	ble	.L7
	b	.L24
.L29:
	cmp	r1, r3
	bcs	.L12
	mov	r0, r5
	bl	_mips64_pte_get
	ldr	r3, .L35+68
	ldr	r3, [r3]
	tst	r0, r3
	beq	.L13
	bl	MIPS64_PTE_TO_PA
	mov	fp, r0
	b	.L6
.L10:
	mov	r3, r6
	mov	r0, r5
	ldr	r2, .L35+80
	ldr	r1, [r5]
	bl	_kvm_err
	mov	r0, r4
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L31:
	mov	r3, fp
	mov	r0, r5
	ldr	r2, .L35+84
	ldr	r1, [r5]
	bl	_kvm_err
	b	.L12
.L32:
	ldr	r3, .L35+88
	ldr	fp, [r3]
	and	fp, fp, r6
	b	.L6
.L34:
	bl	MIPS32_PTE_TO_PA
	mov	fp, r0
	b	.L6
.L36:
	.align	2
.L35:
	.word	EI_CLASS
	.word	ELFCLASS64
	.word	MIPS_PAGE_MASK
	.word	MIPS32_KSEG0_START
	.word	MIPS32_KSEG1_START
	.word	MIPS32_KSEG1_END
	.word	MIPS_PAGE_SHIFT
	.word	.LC3
	.word	MIPS32_KSEG0_END
	.word	MIPS_KSEG0_PHYS_MASK
	.word	MIPS_PAGE_SIZE
	.word	MIPS_XKPHYS_START
	.word	MIPS_XKPHYS_END
	.word	MIPS64_KSEG0_START
	.word	MIPS64_KSEG1_START
	.word	MIPS64_KSEG1_END
	.word	.LC0
	.word	MIPS_PTE_V
	.word	.LC4
	.word	MIPS64_KSEG0_END
	.word	.LC1
	.word	.LC2
	.word	MIPS_XKPHYS_PHYS_MASK
	.size	_mips_minidump_kvatop, .-_mips_minidump_kvatop
	.comm	MIPS_XKPHYS_START,4,4
	.comm	MIPS_XKPHYS_PHYS_MASK,4,4
	.comm	MIPS_XKPHYS_END,4,4
	.comm	MIPS_PTE_V,4,4
	.comm	MIPS_PAGE_SIZE,4,4
	.comm	MIPS_PAGE_SHIFT,4,4
	.comm	MIPS_PAGE_MASK,4,4
	.comm	MIPS_KSEG0_PHYS_MASK,4,4
	.comm	MIPS64_KSEG1_START,4,4
	.comm	MIPS64_KSEG1_END,4,4
	.comm	MIPS64_KSEG0_START,4,4
	.comm	MIPS64_KSEG0_END,4,4
	.comm	MIPS32_KSEG1_START,4,4
	.comm	MIPS32_KSEG1_END,4,4
	.comm	MIPS32_KSEG0_START,4,4
	.comm	MIPS32_KSEG0_END,4,4
	.comm	ELFCLASS64,4,4
	.comm	EI_CLASS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
