	.file	"extr_i2c-aspeed.c_aspeed_i2c_init_clk.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	aspeed_i2c_init_clk, @function
aspeed_i2c_init_clk:
.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	rbx, rdi
	mov	esi, DWORD PTR 20[rdi]
	mov	edi, DWORD PTR 24[rdi]
	call	DIV_ROUND_UP@PLT
	mov	rdi, QWORD PTR ASPEED_I2C_AC_TIMING_REG1[rip]
	add	rdi, QWORD PTR 8[rbx]
	mov	r12d, eax
	call	readl@PLT
	mov	ebp, DWORD PTR ASPEED_I2CD_TIME_TBUF_MASK[rip]
	mov	edi, DWORD PTR 16[rbx]
	mov	esi, r12d
	or	ebp, DWORD PTR ASPEED_I2CD_TIME_THDSTA_MASK[rip]
	or	ebp, DWORD PTR ASPEED_I2CD_TIME_TACST_MASK[rip]
	and	ebp, eax
	call	[QWORD PTR [rbx]]
	mov	edi, ebp
	mov	rsi, QWORD PTR ASPEED_I2C_AC_TIMING_REG1[rip]
	add	rsi, QWORD PTR 8[rbx]
	or	edi, eax
	call	writel@PLT
	mov	edi, DWORD PTR ASPEED_NO_TIMEOUT_CTRL[rip]
	mov	rsi, QWORD PTR ASPEED_I2C_AC_TIMING_REG2[rip]
	add	rsi, QWORD PTR 8[rbx]
	call	writel@PLT
	pop	rbx
	.cfi_def_cfa_offset 24
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	aspeed_i2c_init_clk, .-aspeed_i2c_init_clk
	.comm	ASPEED_NO_TIMEOUT_CTRL,4,4
	.comm	ASPEED_I2C_AC_TIMING_REG2,8,8
	.comm	ASPEED_I2C_AC_TIMING_REG1,8,8
	.comm	ASPEED_I2CD_TIME_THDSTA_MASK,4,4
	.comm	ASPEED_I2CD_TIME_TBUF_MASK,4,4
	.comm	ASPEED_I2CD_TIME_TACST_MASK,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_i2c-aspeed.c_aspeed_i2c_init_clk.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	aspeed_i2c_init_clk, %function
aspeed_i2c_init_clk:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r0
	ldr	r1, [r0, #12]
	ldr	r0, [r0, #16]
	bl	DIV_ROUND_UP
	ldr	r7, .L4
	ldr	r2, [r4, #4]
	ldr	r3, [r7]
	mov	r6, r0
	add	r0, r2, r3
	bl	readl
	mov	r2, r0
	ldr	r1, .L4+4
	ldr	r0, .L4+8
	ldr	r3, .L4+12
	ldr	r5, [r0]
	ldr	r1, [r1]
	ldr	r3, [r3]
	orr	r5, r5, r1
	ldr	r0, [r4, #8]
	mov	r1, r6
	orr	r5, r5, r3
	ldr	r3, [r4]
	and	r5, r5, r2
	blx	r3
	ldr	r3, [r7]
	ldr	r1, [r4, #4]
	orr	r0, r5, r0
	add	r1, r1, r3
	bl	writel
	ldr	r3, .L4+16
	ldr	r1, [r4, #4]
	ldr	r2, [r3]
	ldr	r3, .L4+20
	add	r1, r1, r2
	ldr	r0, [r3]
	bl	writel
	mov	r0, #0
	pop	{r4, r5, r6, r7, r8, pc}
.L5:
	.align	2
.L4:
	.word	ASPEED_I2C_AC_TIMING_REG1
	.word	ASPEED_I2CD_TIME_THDSTA_MASK
	.word	ASPEED_I2CD_TIME_TBUF_MASK
	.word	ASPEED_I2CD_TIME_TACST_MASK
	.word	ASPEED_I2C_AC_TIMING_REG2
	.word	ASPEED_NO_TIMEOUT_CTRL
	.size	aspeed_i2c_init_clk, .-aspeed_i2c_init_clk
	.comm	ASPEED_NO_TIMEOUT_CTRL,4,4
	.comm	ASPEED_I2C_AC_TIMING_REG2,4,4
	.comm	ASPEED_I2C_AC_TIMING_REG1,4,4
	.comm	ASPEED_I2CD_TIME_THDSTA_MASK,4,4
	.comm	ASPEED_I2CD_TIME_TBUF_MASK,4,4
	.comm	ASPEED_I2CD_TIME_TACST_MASK,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
