	.file	"extr_evergreen.c_evergreen_pm_misc.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"Setting: vddc: %d\n"
.LC1:
	.string	"Setting: vddci: %d\n"
	.text
	.p2align 4
	.globl	evergreen_pm_misc
	.type	evergreen_pm_misc, @function
evergreen_pm_misc:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	mov	rax, QWORD PTR 56[rdi]
	movsx	r12, DWORD PTR 8[rdi]
	movsx	rbp, DWORD PTR 12[rdi]
	sal	rbp, 4
	add	rbp, QWORD PTR [rax+r12*8]
	mov	rax, QWORD PTR VOLTAGE_SW[rip]
	cmp	QWORD PTR 0[rbp], rax
	je	.L22
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	mov	esi, DWORD PTR 8[rbp]
	cmp	esi, 65281
	je	.L1
	mov	rbx, rdi
	test	esi, esi
	je	.L5
	cmp	esi, DWORD PTR 16[rdi]
	je	.L5
	mov	edx, DWORD PTR SET_VOLTAGE_TYPE_ASIC_VDDC[rip]
	call	radeon_atom_set_voltage@PLT
	mov	esi, DWORD PTR 8[rbp]
	lea	rdi, .LC0[rip]
	mov	DWORD PTR 16[rbx], esi
	call	DRM_DEBUG@PLT
.L5:
	mov	rax, QWORD PTR PM_METHOD_PROFILE[rip]
	cmp	QWORD PTR 24[rbx], rax
	je	.L23
.L6:
	mov	esi, DWORD PTR 12[rbp]
	cmp	esi, 65281
	je	.L1
	test	esi, esi
	je	.L1
	cmp	esi, DWORD PTR 40[rbx]
	je	.L1
	mov	edx, DWORD PTR SET_VOLTAGE_TYPE_ASIC_VDDCI[rip]
	mov	rdi, rbx
	call	radeon_atom_set_voltage@PLT
	mov	esi, DWORD PTR 12[rbp]
	lea	rdi, .LC1[rip]
	mov	DWORD PTR 40[rbx], esi
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	jmp	DRM_DEBUG@PLT
	.p2align 4,,10
	.p2align 3
.L23:
	.cfi_restore_state
	mov	rax, QWORD PTR CHIP_BARTS[rip]
	cmp	QWORD PTR [rbx], rax
	jl	.L6
	cmp	QWORD PTR 64[rbx], 0
	je	.L6
	mov	rax, QWORD PTR 32[rbx]
	cmp	rax, QWORD PTR PM_PROFILE_MID_MH_IDX[rip]
	je	.L7
	cmp	rax, QWORD PTR PM_PROFILE_LOW_MH_IDX[rip]
	jne	.L6
.L7:
	mov	rdx, QWORD PTR 48[rbx]
	mov	rcx, QWORD PTR PM_PROFILE_HIGH_MH_IDX[rip]
	mov	rax, QWORD PTR 56[rbx]
	mov	rbp, QWORD PTR [rdx+rcx*8]
	sal	rbp, 4
	add	rbp, QWORD PTR [rax+r12*8]
	jmp	.L6
	.cfi_endproc
.LFE0:
	.size	evergreen_pm_misc, .-evergreen_pm_misc
	.comm	VOLTAGE_SW,8,8
	.comm	SET_VOLTAGE_TYPE_ASIC_VDDCI,4,4
	.comm	SET_VOLTAGE_TYPE_ASIC_VDDC,4,4
	.comm	PM_PROFILE_MID_MH_IDX,8,8
	.comm	PM_PROFILE_LOW_MH_IDX,8,8
	.comm	PM_PROFILE_HIGH_MH_IDX,8,8
	.comm	PM_METHOD_PROFILE,8,8
	.comm	CHIP_BARTS,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_evergreen.c_evergreen_pm_misc.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Setting: vddc: %d\012\000"
	.align	2
.LC1:
	.ascii	"Setting: vddci: %d\012\000"
	.text
	.align	2
	.global	evergreen_pm_misc
	.syntax unified
	.arm
	.fpu softvfp
	.type	evergreen_pm_misc, %function
evergreen_pm_misc:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	ldr	r2, [r0, #32]
	ldr	r6, [r0, #4]
	ldr	r3, [r0, #8]
	ldr	r2, [r2, r6, lsl #2]
	ldr	r1, .L20
	add	r3, r3, r3, lsl #1
	ldr	ip, [r2, r3, lsl #2]
	ldr	r1, [r1]
	add	r5, r2, r3, lsl #2
	cmp	ip, r1
	popne	{r4, r5, r6, pc}
	ldr	r1, [r5, #4]
	ldr	r3, .L20+4
	cmp	r1, r3
	popeq	{r4, r5, r6, pc}
	cmp	r1, #0
	mov	r4, r0
	beq	.L5
	ldr	r3, [r0, #12]
	cmp	r1, r3
	beq	.L5
	ldr	r3, .L20+8
	ldr	r2, [r3]
	bl	radeon_atom_set_voltage
	ldr	r1, [r5, #4]
	ldr	r0, .L20+12
	str	r1, [r4, #12]
	bl	DRM_DEBUG
.L5:
	ldr	r3, .L20+16
	ldr	r2, [r4, #16]
	ldr	r3, [r3]
	cmp	r2, r3
	beq	.L19
.L6:
	ldr	r1, [r5, #8]
	ldr	r3, .L20+4
	cmp	r1, r3
	cmpne	r1, #0
	popeq	{r4, r5, r6, pc}
	ldr	r3, [r4, #24]
	cmp	r1, r3
	popeq	{r4, r5, r6, pc}
	ldr	r3, .L20+20
	mov	r0, r4
	ldr	r2, [r3]
	bl	radeon_atom_set_voltage
	ldr	r1, [r5, #8]
	ldr	r0, .L20+24
	str	r1, [r4, #24]
	pop	{r4, r5, r6, lr}
	b	DRM_DEBUG
.L19:
	ldr	r3, .L20+28
	ldr	r2, [r4]
	ldr	r3, [r3]
	cmp	r2, r3
	blt	.L6
	ldr	r3, [r4, #36]
	cmp	r3, #0
	beq	.L6
	ldr	r2, .L20+32
	ldr	r3, [r4, #20]
	ldr	r2, [r2]
	cmp	r3, r2
	beq	.L7
	ldr	r2, .L20+36
	ldr	r2, [r2]
	cmp	r3, r2
	bne	.L6
.L7:
	ldr	r3, .L20+40
	ldr	r2, [r4, #28]
	ldr	r1, [r3]
	ldr	r3, [r4, #32]
	ldr	r1, [r2, r1, lsl #2]
	ldr	r3, [r3, r6, lsl #2]
	add	r1, r1, r1, lsl #1
	add	r5, r3, r1, lsl #2
	b	.L6
.L21:
	.align	2
.L20:
	.word	VOLTAGE_SW
	.word	65281
	.word	SET_VOLTAGE_TYPE_ASIC_VDDC
	.word	.LC0
	.word	PM_METHOD_PROFILE
	.word	SET_VOLTAGE_TYPE_ASIC_VDDCI
	.word	.LC1
	.word	CHIP_BARTS
	.word	PM_PROFILE_MID_MH_IDX
	.word	PM_PROFILE_LOW_MH_IDX
	.word	PM_PROFILE_HIGH_MH_IDX
	.size	evergreen_pm_misc, .-evergreen_pm_misc
	.comm	VOLTAGE_SW,4,4
	.comm	SET_VOLTAGE_TYPE_ASIC_VDDCI,4,4
	.comm	SET_VOLTAGE_TYPE_ASIC_VDDC,4,4
	.comm	PM_PROFILE_MID_MH_IDX,4,4
	.comm	PM_PROFILE_LOW_MH_IDX,4,4
	.comm	PM_PROFILE_HIGH_MH_IDX,4,4
	.comm	PM_METHOD_PROFILE,4,4
	.comm	CHIP_BARTS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
