	.file	"extr_polaris10_smumgr.c_polaris10_populate_smc_link_level.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	polaris10_populate_smc_link_level, @function
polaris10_populate_smc_link_level:
.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
	push	r12
	.cfi_def_cfa_offset 40
	.cfi_offset 12, -40
	push	rbp
	.cfi_def_cfa_offset 48
	.cfi_offset 6, -48
	push	rbx
	.cfi_def_cfa_offset 56
	.cfi_offset 3, -56
	sub	rsp, 8
	.cfi_def_cfa_offset 64
	mov	r12, QWORD PTR 8[rdi]
	mov	r14, QWORD PTR [rdi]
	movsx	rax, DWORD PTR 8[r12]
	test	eax, eax
	js	.L2
	mov	r13, rsi
	xor	ebp, ebp
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rax, rbp
	mov	rdx, QWORD PTR 0[r13]
	lea	rbx, 0[rbp+rbp*2]
	add	rbp, 1
	sal	rax, 4
	add	rax, QWORD PTR 16[r12]
	sal	rbx, 4
	mov	rcx, QWORD PTR 8[rax]
	mov	edi, DWORD PTR [rax]
	mov	QWORD PTR 40[rdx+rbx], rcx
	call	encode_pcie_lane_width@PLT
	mov	r15, QWORD PTR 0[r13]
	mov	edi, 5
	add	r15, rbx
	mov	QWORD PTR 32[r15], rax
	movzx	eax, BYTE PTR [r12]
	mov	DWORD PTR [r15], 1
	mov	QWORD PTR 24[r15], rax
	call	PP_HOST_TO_SMC_UL@PLT
	mov	edi, 30
	add	rbx, QWORD PTR 0[r13]
	mov	QWORD PTR 16[r15], rax
	call	PP_HOST_TO_SMC_UL@PLT
	mov	QWORD PTR 8[rbx], rax
	movsx	rax, DWORD PTR 8[r12]
	cmp	eax, ebp
	jge	.L3
.L2:
	mov	QWORD PTR [r14], rax
	lea	rdi, 8[r12]
	call	phm_get_dpm_level_enable_mask_value@PLT
	mov	DWORD PTR 4[r12], eax
	add	rsp, 8
	.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
	.cfi_endproc
.LFE0:
	.size	polaris10_populate_smc_link_level, .-polaris10_populate_smc_link_level
	.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_polaris10_smumgr.c_polaris10_populate_smc_link_level.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	polaris10_populate_smc_link_level, %function
polaris10_populate_smc_link_level:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r3, r4, r5, r6, r7, r8, r9, r10, fp, lr}
	ldr	r10, [r0, #4]
	ldr	r9, [r0]
	ldr	r3, [r10, #8]
	cmp	r3, #0
	blt	.L2
	mov	r4, #0
	mov	r7, r1
	mov	r8, #1
	mov	fp, r4
.L3:
	ldr	r2, [r10, #12]
	ldr	r3, [r7]
	add	r1, r2, r4
	add	r5, r4, r4, lsl #1
	ldr	r1, [r1, #4]
	add	r3, r3, r5
	ldr	r0, [r2, r4]
	str	r1, [r3, #20]
	bl	encode_pcie_lane_width
	ldr	r3, [r7]
	ldrb	r2, [r10]	@ zero_extendqisi2
	add	r6, r3, r5
	str	r0, [r6, #16]
	str	r8, [r3, r5]
	mov	r0, #5
	str	r2, [r6, #12]
	bl	PP_HOST_TO_SMC_UL
	ldr	r3, [r7]
	str	r0, [r6, #8]
	mov	r0, #30
	add	r5, r3, r5
	bl	PP_HOST_TO_SMC_UL
	ldr	r3, [r10, #8]
	add	fp, fp, #1
	cmp	r3, fp
	add	r4, r4, #8
	str	r0, [r5, #4]
	bge	.L3
.L2:
	str	r3, [r9]
	add	r0, r10, #8
	bl	phm_get_dpm_level_enable_mask_value
	mov	r3, r0
	mov	r0, #0
	str	r3, [r10, #4]
	pop	{r3, r4, r5, r6, r7, r8, r9, r10, fp, pc}
	.size	polaris10_populate_smc_link_level, .-polaris10_populate_smc_link_level
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
