	.file	"extr_si_dpm.c_si_upload_smc_data.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	si_upload_smc_data, @function
si_upload_smc_data:
.LFB0:
	.cfi_startproc
	endbr64
	cmp	QWORD PTR 16[rdi], 0
	je	.L17
	push	rbp
	.cfi_def_cfa_offset 16
	.cfi_offset 6, -16
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 24
	.cfi_offset 3, -24
	sub	rsp, 8
	.cfi_def_cfa_offset 32
	mov	ecx, DWORD PTR [rdi]
	test	ecx, ecx
	jle	.L3
	mov	edx, DWORD PTR 24[rdi]
	mov	eax, edx
	and	eax, 1
	je	.L6
	jmp	.L21
	.p2align 4,,10
	.p2align 3
.L8:
	bt	edx, eax
	jc	.L22
.L6:
	add	eax, 1
	cmp	eax, ecx
	jne	.L8
.L3:
	add	rsp, 8
	.cfi_def_cfa_offset 24
	xor	eax, eax
	pop	rbx
	.cfi_def_cfa_offset 16
	pop	rbp
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L17:
	.cfi_restore 3
	.cfi_restore 6
	xor	eax, eax
	ret
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -24
	.cfi_offset 6, -16
	cdqe
	sal	rax, 3
.L5:
	mov	rdx, QWORD PTR 8[rbp]
	mov	rbx, QWORD PTR [rdx+rax]
	test	rbx, rbx
	je	.L3
	mov	eax, DWORD PTR [rbx]
	test	eax, eax
	jle	.L3
	mov	edx, DWORD PTR 4[rbx]
	mov	esi, DWORD PTR SI_SMC_SOFT_REGISTER_crtc_index[rip]
	mov	rdi, rbp
	call	si_write_smc_soft_register@PLT
	cmp	rax, QWORD PTR PPSMC_Result_OK[rip]
	jne	.L3
	mov	eax, DWORD PTR 8[rbx]
	mov	esi, DWORD PTR SI_SMC_SOFT_REGISTER_mclk_change_block_cp_min[rip]
	mov	rdi, rbp
	cdq
	idiv	DWORD PTR [rbx]
	mov	edx, eax
	call	si_write_smc_soft_register@PLT
	cmp	rax, QWORD PTR PPSMC_Result_OK[rip]
	jne	.L3
	mov	eax, DWORD PTR 12[rbx]
	mov	esi, DWORD PTR SI_SMC_SOFT_REGISTER_mclk_change_block_cp_max[rip]
	mov	rdi, rbp
	cdq
	idiv	DWORD PTR [rbx]
	mov	edx, eax
	call	si_write_smc_soft_register@PLT
	jmp	.L3
.L21:
	xor	eax, eax
	jmp	.L5
	.cfi_endproc
.LFE0:
	.size	si_upload_smc_data, .-si_upload_smc_data
	.comm	SI_SMC_SOFT_REGISTER_mclk_change_block_cp_min,4,4
	.comm	SI_SMC_SOFT_REGISTER_mclk_change_block_cp_max,4,4
	.comm	SI_SMC_SOFT_REGISTER_crtc_index,4,4
	.comm	PPSMC_Result_OK,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_si_dpm.c_si_upload_smc_data.c"
	.text
	.global	__aeabi_idiv
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	si_upload_smc_data, %function
si_upload_smc_data:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r3, [r0, #8]
	cmp	r3, #0
	beq	.L17
	ldr	ip, [r0]
	push	{r4, r5, r6, lr}
	cmp	ip, #0
	mov	r4, r0
	ble	.L3
	ldr	r1, [r0, #12]
	ands	r3, r1, #1
	beq	.L6
	b	.L21
.L8:
	tst	r2, #1
	bne	.L22
.L6:
	add	r3, r3, #1
	cmp	r3, ip
	asr	r2, r1, r3
	bne	.L8
.L3:
	mov	r0, #0
	pop	{r4, r5, r6, pc}
.L17:
	mov	r0, #0
	bx	lr
.L22:
	lsl	r3, r3, #2
.L5:
	ldr	r2, [r4, #4]
	ldr	r5, [r2, r3]
	cmp	r5, #0
	beq	.L3
	ldr	r3, [r5]
	cmp	r3, #0
	ble	.L3
	ldr	r3, .L23
	mov	r0, r4
	ldr	r1, [r3]
	ldr	r2, [r5, #4]
	bl	si_write_smc_soft_register
	ldr	r6, .L23+4
	ldr	r3, [r6]
	cmp	r0, r3
	bne	.L3
	ldr	r1, [r5]
	ldr	r0, [r5, #8]
	bl	__aeabi_idiv
	ldr	r3, .L23+8
	mov	r2, r0
	ldr	r1, [r3]
	mov	r0, r4
	bl	si_write_smc_soft_register
	ldr	r3, [r6]
	cmp	r0, r3
	bne	.L3
	ldr	r1, [r5]
	ldr	r0, [r5, #12]
	bl	__aeabi_idiv
	ldr	r3, .L23+12
	mov	r2, r0
	ldr	r1, [r3]
	mov	r0, r4
	bl	si_write_smc_soft_register
	b	.L3
.L21:
	mov	r3, #0
	b	.L5
.L24:
	.align	2
.L23:
	.word	SI_SMC_SOFT_REGISTER_crtc_index
	.word	PPSMC_Result_OK
	.word	SI_SMC_SOFT_REGISTER_mclk_change_block_cp_min
	.word	SI_SMC_SOFT_REGISTER_mclk_change_block_cp_max
	.size	si_upload_smc_data, .-si_upload_smc_data
	.comm	SI_SMC_SOFT_REGISTER_mclk_change_block_cp_min,4,4
	.comm	SI_SMC_SOFT_REGISTER_mclk_change_block_cp_max,4,4
	.comm	SI_SMC_SOFT_REGISTER_crtc_index,4,4
	.comm	PPSMC_Result_OK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
