	.file	"extr_i2c-sun6i-p2wi.c_p2wi_probe.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC0:
	.string	"clock-frequency"
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC1:
	.string	"required clock-frequency (%u Hz) is too high (max = 6MHz)"
	.align 8
.LC2:
	.string	"P2WI only supports one slave device\n"
	.section	.rodata.str1.1
.LC3:
	.string	"reg"
	.section	.rodata.str1.8
	.align 8
.LC4:
	.string	"invalid slave address on node %pOF\n"
	.section	.rodata.str1.1
.LC5:
	.string	"failed to retrieve irq: %d\n"
.LC6:
	.string	"failed to retrieve clk: %d\n"
.LC7:
	.string	"failed to enable clk: %d\n"
	.section	.rodata.str1.8
	.align 8
.LC8:
	.string	"failed to retrieve reset controller: %d\n"
	.align 8
.LC9:
	.string	"failed to deassert reset line: %d\n"
	.align 8
.LC10:
	.string	"can't register interrupt handler irq%d: %d\n"
	.align 8
.LC11:
	.string	"clock-frequency is too high, setting it to %lu Hz\n"
	.align 8
.LC12:
	.string	"clock-frequency is too low, setting it to %lu Hz\n"
	.text
	.p2align 4
	.type	p2wi_probe, @function
p2wi_probe:
.LFB0:
	.cfi_startproc
	endbr64
	push	r15
	.cfi_def_cfa_offset 16
	.cfi_offset 15, -16
	lea	rsi, .LC0[rip]
	push	r14
	.cfi_def_cfa_offset 24
	.cfi_offset 14, -24
	push	r13
	.cfi_def_cfa_offset 32
	.cfi_offset 13, -32
	lea	r13, 8[rdi]
	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
	mov	rbx, rdi
	sub	rsp, 56
	.cfi_def_cfa_offset 112
	mov	r12, QWORD PTR 8[rdi]
	mov	rax, QWORD PTR fs:40
	mov	QWORD PTR 40[rsp], rax
	xor	eax, eax
	lea	rdx, 24[rsp]
	mov	QWORD PTR 24[rsp], 100000
	mov	rdi, r12
	call	of_property_read_u32@PLT
	mov	rdx, QWORD PTR 24[rsp]
	cmp	rdx, QWORD PTR P2WI_MAX_FREQ[rip]
	lea	rsi, .LC1[rip]
	ja	.L27
	mov	rdi, r12
	call	of_get_child_count@PLT
	cmp	eax, 1
	jg	.L29
	mov	edx, DWORD PTR GFP_KERNEL[rip]
	mov	esi, 80
	mov	rdi, r13
	call	devm_kzalloc@PLT
	mov	rbp, rax
	test	rax, rax
	je	.L30
	mov	DWORD PTR [rax], -1
	mov	rdi, r12
	xor	esi, esi
	call	of_get_next_available_child@PLT
	mov	r12, rax
	test	rax, rax
	je	.L6
	lea	rdx, 32[rsp]
	lea	rsi, .LC3[rip]
	mov	rdi, rax
	call	of_property_read_u32@PLT
	test	eax, eax
	jne	.L31
	mov	rax, QWORD PTR 32[rsp]
	mov	DWORD PTR 0[rbp], eax
.L6:
	mov	esi, DWORD PTR IORESOURCE_MEM[rip]
	xor	edx, edx
	mov	rdi, rbx
	call	platform_get_resource@PLT
	mov	rdi, r13
	mov	rsi, rax
	call	devm_ioremap_resource@PLT
	mov	QWORD PTR 64[rbp], rax
	mov	rdi, rax
	call	IS_ERR@PLT
	test	rax, rax
	jne	.L32
	mov	edi, DWORD PTR 56[rbp]
	mov	esi, DWORD PTR [rbx]
	mov	edx, 4
	call	strlcpy@PLT
	xor	esi, esi
	mov	rdi, rbx
	call	platform_get_irq@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L33
	xor	esi, esi
	mov	rdi, r13
	call	devm_clk_get@PLT
	mov	QWORD PTR 8[rbp], rax
	mov	rdi, rax
	call	IS_ERR@PLT
	mov	rdi, QWORD PTR 8[rbp]
	test	rax, rax
	jne	.L34
	call	clk_prepare_enable@PLT
	mov	r14d, eax
	test	eax, eax
	jne	.L35
	mov	rdi, QWORD PTR 8[rbp]
	call	clk_get_rate@PLT
	xor	esi, esi
	mov	rdi, r13
	mov	r14, rax
	call	devm_reset_control_get_exclusive@PLT
	mov	QWORD PTR 16[rbp], rax
	mov	rdi, rax
	call	IS_ERR@PLT
	mov	rdi, QWORD PTR 16[rbp]
	test	rax, rax
	jne	.L36
	call	reset_control_deassert@PLT
	mov	r15d, eax
	test	eax, eax
	jne	.L37
	lea	rdi, 72[rbp]
	lea	r15, 24[rbp]
	call	init_completion@PLT
	mov	QWORD PTR 32[rbp], r13
	mov	rdi, rbx
	mov	rsi, rbp
	lea	rax, p2wi_algo[rip]
	mov	QWORD PTR 48[rbp], rax
	mov	eax, DWORD PTR THIS_MODULE[rip]
	mov	DWORD PTR 40[rbp], eax
	mov	rax, QWORD PTR 8[rbx]
	mov	QWORD PTR 24[rbp], rax
	call	platform_set_drvdata@PLT
	mov	rsi, rbp
	mov	rdi, r15
	call	i2c_set_adapdata@PLT
	mov	r8d, DWORD PTR [rbx]
	mov	edx, DWORD PTR p2wi_interrupt[rip]
	xor	ecx, ecx
	mov	r9, rbp
	mov	esi, r12d
	mov	rdi, r13
	call	devm_request_irq@PLT
	mov	ebx, eax
	test	eax, eax
	jne	.L38
	mov	edi, DWORD PTR P2WI_CTRL_SOFT_RST[rip]
	mov	rsi, QWORD PTR P2WI_CTRL[rip]
	add	rsi, QWORD PTR 64[rbp]
	call	writel@PLT
	mov	rax, r14
	xor	edx, edx
	div	QWORD PTR 24[rsp]
	mov	r8d, eax
	test	eax, eax
	je	.L39
	mov	edx, DWORD PTR P2WI_CCR_MAX_CLK_DIV[rip]
	cmp	edx, eax
	jl	.L40
.L18:
	mov	edi, 1
	mov	DWORD PTR 12[rsp], r8d
	mov	r12, QWORD PTR P2WI_CCR[rip]
	add	r12, QWORD PTR 64[rbp]
	call	P2WI_CCR_SDA_OUT_DELAY@PLT
	mov	r8d, DWORD PTR 12[rsp]
	mov	ebx, eax
	mov	edi, r8d
	call	P2WI_CCR_CLK_DIV@PLT
	mov	rsi, r12
	or	ebx, eax
	mov	edi, ebx
	call	writel@PLT
	mov	rdi, r15
	call	i2c_add_adapter@PLT
	mov	r12d, eax
	test	eax, eax
	je	.L1
.L16:
	mov	rdi, QWORD PTR 16[rbp]
	call	reset_control_assert@PLT
.L13:
	mov	rdi, QWORD PTR 8[rbp]
	call	clk_disable_unprepare@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L29:
	lea	rsi, .LC2[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	mov	r12d, DWORD PTR EINVAL[rip]
	neg	r12d
.L1:
	mov	rax, QWORD PTR 40[rsp]
	xor	rax, QWORD PTR fs:40
	jne	.L41
	add	rsp, 56
	.cfi_remember_state
	.cfi_def_cfa_offset 56
	mov	eax, r12d
	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	rdx, r12
	lea	rsi, .LC4[rip]
	.p2align 4,,10
	.p2align 3
.L27:
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	mov	r12d, DWORD PTR EINVAL[rip]
	neg	r12d
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L32:
	mov	rdi, QWORD PTR 64[rbp]
	call	PTR_ERR@PLT
	mov	r12d, eax
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L30:
	mov	r12d, DWORD PTR ENOMEM[rip]
	neg	r12d
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L35:
	mov	edx, eax
	lea	rsi, .LC7[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	mov	r12d, r14d
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L33:
	mov	edx, eax
	lea	rsi, .LC5[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L34:
	call	PTR_ERR@PLT
	lea	rsi, .LC6[rip]
	mov	rdi, r13
	mov	r12d, eax
	mov	edx, eax
	xor	eax, eax
	call	dev_err@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L36:
	call	PTR_ERR@PLT
	lea	rsi, .LC8[rip]
	mov	rdi, r13
	mov	r12d, eax
	mov	edx, eax
	xor	eax, eax
	call	dev_err@PLT
	jmp	.L13
	.p2align 4,,10
	.p2align 3
.L37:
	mov	edx, eax
	lea	rsi, .LC9[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	mov	r12d, r15d
	jmp	.L13
.L38:
	mov	ecx, eax
	mov	edx, r12d
	lea	rsi, .LC10[rip]
	mov	rdi, r13
	xor	eax, eax
	mov	r12d, ebx
	call	dev_err@PLT
	jmp	.L16
.L39:
	mov	rdx, r14
	lea	rsi, .LC11[rip]
	mov	rdi, r13
	call	dev_warn@PLT
	mov	r8d, 1
	jmp	.L18
.L40:
	movsx	rcx, edx
	mov	rax, r14
	xor	edx, edx
	mov	rdi, r13
	div	rcx
	lea	rsi, .LC12[rip]
	mov	rdx, rax
	call	dev_warn@PLT
	mov	r8d, DWORD PTR P2WI_CCR_MAX_CLK_DIV[rip]
	jmp	.L18
.L41:
	call	__stack_chk_fail@PLT
	.cfi_endproc
.LFE0:
	.size	p2wi_probe, .-p2wi_probe
	.comm	p2wi_interrupt,4,4
	.comm	p2wi_algo,4,4
	.comm	THIS_MODULE,4,4
	.comm	P2WI_MAX_FREQ,8,8
	.comm	P2WI_CTRL_SOFT_RST,4,4
	.comm	P2WI_CTRL,8,8
	.comm	P2WI_CCR_MAX_CLK_DIV,4,4
	.comm	P2WI_CCR,8,8
	.comm	IORESOURCE_MEM,4,4
	.comm	GFP_KERNEL,4,4
	.comm	ENOMEM,4,4
	.comm	EINVAL,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-sun6i-p2wi.c_p2wi_probe.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"clock-frequency\000"
	.align	2
.LC1:
	.ascii	"required clock-frequency (%u Hz) is too high (max ="
	.ascii	" 6MHz)\000"
	.align	2
.LC2:
	.ascii	"P2WI only supports one slave device\012\000"
	.align	2
.LC3:
	.ascii	"reg\000"
	.align	2
.LC4:
	.ascii	"invalid slave address on node %pOF\012\000"
	.align	2
.LC5:
	.ascii	"failed to retrieve irq: %d\012\000"
	.align	2
.LC6:
	.ascii	"failed to retrieve clk: %d\012\000"
	.align	2
.LC7:
	.ascii	"failed to enable clk: %d\012\000"
	.align	2
.LC8:
	.ascii	"failed to retrieve reset controller: %d\012\000"
	.align	2
.LC9:
	.ascii	"failed to deassert reset line: %d\012\000"
	.align	2
.LC10:
	.ascii	"can't register interrupt handler irq%d: %d\012\000"
	.global	__aeabi_uidiv
	.align	2
.LC11:
	.ascii	"clock-frequency is too high, setting it to %lu Hz\012"
	.ascii	"\000"
	.align	2
.LC12:
	.ascii	"clock-frequency is too low, setting it to %lu Hz\012"
	.ascii	"\000"
	.section	.rodata.cst4,"aM",%progbits,4
	.align	2
.LC13:
	.word	__stack_chk_guard
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	p2wi_probe, %function
p2wi_probe:
	@ args = 0, pretend = 0, frame = 16
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, lr}
	mov	r4, r0
	ldr	r5, [r0, #4]
	sub	sp, sp, #24
	ldr	r3, .L42
	ldr	ip, .L42+4
	add	r2, sp, #12
	mov	r0, r5
	ldr	r1, .L42+8
	ldr	ip, [ip]
	str	ip, [sp, #20]
	mov	ip,#0
	str	r3, [sp, #12]
	bl	of_property_read_u32
	ldr	r3, .L42+12
	ldr	r2, [sp, #12]
	ldr	r3, [r3]
	add	r7, r4, #4
	cmp	r2, r3
	bhi	.L28
	mov	r0, r5
	bl	of_get_child_count
	cmp	r0, #1
	bgt	.L29
	ldr	r3, .L42+16
	mov	r1, #40
	mov	r0, r7
	ldr	r2, [r3]
	bl	devm_kzalloc
	subs	r6, r0, #0
	beq	.L30
	mvn	r3, #0
	mov	r0, r5
	mov	r1, #0
	str	r3, [r6]
	bl	of_get_next_available_child
	subs	r5, r0, #0
	beq	.L6
	ldr	r1, .L42+20
	add	r2, sp, #16
	bl	of_property_read_u32
	cmp	r0, #0
	bne	.L31
	ldr	r3, [sp, #16]
	str	r3, [r6]
.L6:
	ldr	r3, .L42+24
	mov	r2, #0
	ldr	r1, [r3]
	mov	r0, r4
	bl	platform_get_resource
	mov	r1, r0
	mov	r0, r7
	bl	devm_ioremap_resource
	str	r0, [r6, #32]
	bl	IS_ERR
	subs	r8, r0, #0
	bne	.L32
	mov	r2, #4
	ldr	r1, [r4]
	ldr	r0, [r6, #28]
	bl	strlcpy
	mov	r1, r8
	mov	r0, r4
	bl	platform_get_irq
	subs	r5, r0, #0
	blt	.L33
	mov	r1, r8
	mov	r0, r7
	bl	devm_clk_get
	str	r0, [r6, #4]
	bl	IS_ERR
	cmp	r0, #0
	ldr	r0, [r6, #4]
	bne	.L34
	bl	clk_prepare_enable
	subs	r8, r0, #0
	bne	.L35
	ldr	r0, [r6, #4]
	bl	clk_get_rate
	mov	r2, r0
	mov	r1, r8
	mov	r0, r7
	mov	r8, r2
	bl	devm_reset_control_get_exclusive
	str	r0, [r6, #8]
	bl	IS_ERR
	cmp	r0, #0
	ldr	r0, [r6, #8]
	bne	.L36
	bl	reset_control_deassert
	subs	r9, r0, #0
	bne	.L37
	add	r0, r6, #36
	bl	init_completion
	ldr	r3, .L42+28
	ldr	r2, .L42+32
	ldr	r1, [r3]
	ldr	r3, [r4, #4]
	mov	r0, r4
	str	r2, [r6, #24]
	str	r3, [r6, #12]
	str	r1, [r6, #20]
	str	r7, [r6, #16]
	mov	r1, r6
	add	r10, r6, #12
	bl	platform_set_drvdata
	mov	r1, r6
	mov	r0, r10
	bl	i2c_set_adapdata
	ldr	r3, [r4]
	ldr	r2, .L42+36
	stm	sp, {r3, r6}
	mov	r1, r5
	mov	r3, r9
	mov	r0, r7
	ldr	r2, [r2]
	bl	devm_request_irq
	subs	r3, r0, #0
	bne	.L38
	ldr	r3, .L42+40
	ldr	r1, [r6, #32]
	ldr	r2, [r3]
	ldr	r3, .L42+44
	add	r1, r1, r2
	ldr	r0, [r3]
	bl	writel
	mov	r0, r8
	ldr	r1, [sp, #12]
	bl	__aeabi_uidiv
	subs	r4, r0, #0
	beq	.L39
	ldr	r5, .L42+48
	ldr	r1, [r5]
	cmp	r1, r4
	blt	.L40
.L18:
	mov	r0, #1
	bl	P2WI_CCR_SDA_OUT_DELAY
	mov	r3, r0
	mov	r0, r4
	mov	r4, r3
	bl	P2WI_CCR_CLK_DIV
	ldr	r3, .L42+52
	ldr	r1, [r6, #32]
	ldr	r3, [r3]
	orr	r0, r4, r0
	add	r1, r1, r3
	bl	writel
	mov	r0, r10
	bl	i2c_add_adapter
	subs	r5, r0, #0
	beq	.L1
.L16:
	ldr	r0, [r6, #8]
	bl	reset_control_assert
.L13:
	ldr	r0, [r6, #4]
	bl	clk_disable_unprepare
	b	.L1
.L29:
	mov	r0, r7
	ldr	r1, .L42+56
	bl	dev_err
	ldr	r3, .L42+60
	ldr	r0, [r3]
	rsb	r5, r0, #0
.L1:
	ldr	r3, .L42+4
	ldr	r2, [r3]
	ldr	r3, [sp, #20]
	eors	r2, r3, r2
	mov	r3, #0
	bne	.L41
	mov	r0, r5
	add	sp, sp, #24
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, pc}
.L28:
	mov	r0, r7
	ldr	r1, .L42+64
	bl	dev_err
	ldr	r3, .L42+60
	ldr	r0, [r3]
	rsb	r5, r0, #0
	b	.L1
.L32:
	ldr	r0, [r6, #32]
	bl	PTR_ERR
	mov	r5, r0
	b	.L1
.L30:
	ldr	r3, .L42+68
	ldr	r0, [r3]
	rsb	r5, r0, #0
	b	.L1
.L35:
	mov	r0, r7
	mov	r2, r8
	ldr	r1, .L42+72
	mov	r5, r8
	bl	dev_err
	b	.L1
.L33:
	mov	r0, r7
	mov	r2, r5
	ldr	r1, .L42+76
	bl	dev_err
	b	.L1
.L34:
	bl	PTR_ERR
	mov	r5, r0
	ldr	r1, .L42+80
	mov	r0, r7
	mov	r2, r5
	bl	dev_err
	b	.L1
.L31:
	mov	r2, r5
	mov	r0, r7
	ldr	r1, .L42+84
	bl	dev_err
	ldr	r3, .L42+60
	ldr	r0, [r3]
	rsb	r5, r0, #0
	b	.L1
.L36:
	bl	PTR_ERR
	mov	r5, r0
	ldr	r1, .L42+88
	mov	r0, r7
	mov	r2, r5
	bl	dev_err
	b	.L13
.L37:
	mov	r0, r7
	mov	r2, r9
	ldr	r1, .L42+92
	mov	r5, r9
	bl	dev_err
	b	.L13
.L38:
	mov	r2, r5
	mov	r0, r7
	ldr	r1, .L42+96
	mov	r5, r3
	bl	dev_err
	b	.L16
.L39:
	mov	r2, r8
	mov	r0, r7
	ldr	r1, .L42+100
	bl	dev_warn
	mov	r4, #1
	b	.L18
.L40:
	mov	r0, r8
	bl	__aeabi_uidiv
	ldr	r1, .L42+104
	mov	r2, r0
	mov	r0, r7
	bl	dev_warn
	ldr	r4, [r5]
	b	.L18
.L41:
	bl	__stack_chk_fail
.L43:
	.align	2
.L42:
	.word	100000
	.word	.LC13
	.word	.LC0
	.word	P2WI_MAX_FREQ
	.word	GFP_KERNEL
	.word	.LC3
	.word	IORESOURCE_MEM
	.word	THIS_MODULE
	.word	p2wi_algo
	.word	p2wi_interrupt
	.word	P2WI_CTRL
	.word	P2WI_CTRL_SOFT_RST
	.word	P2WI_CCR_MAX_CLK_DIV
	.word	P2WI_CCR
	.word	.LC2
	.word	EINVAL
	.word	.LC1
	.word	ENOMEM
	.word	.LC7
	.word	.LC5
	.word	.LC6
	.word	.LC4
	.word	.LC8
	.word	.LC9
	.word	.LC10
	.word	.LC11
	.word	.LC12
	.size	p2wi_probe, .-p2wi_probe
	.comm	p2wi_interrupt,4,4
	.comm	p2wi_algo,4,4
	.comm	THIS_MODULE,4,4
	.comm	P2WI_MAX_FREQ,4,4
	.comm	P2WI_CTRL_SOFT_RST,4,4
	.comm	P2WI_CTRL,4,4
	.comm	P2WI_CCR_MAX_CLK_DIV,4,4
	.comm	P2WI_CCR,4,4
	.comm	IORESOURCE_MEM,4,4
	.comm	GFP_KERNEL,4,4
	.comm	ENOMEM,4,4
	.comm	EINVAL,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
