	.file	"extr_pxa27x_keypad.c_pxa27x_keypad_config.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	pxa27x_keypad_config, @function
pxa27x_keypad_config:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	xor	ebx, ebx
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	mov	rbp, QWORD PTR 8[rdi]
	mov	edi, DWORD PTR KPC[rip]
	call	keypad_readl@PLT
	mov	rdi, QWORD PTR 40[rbp]
	test	rdi, rdi
	je	.L2
	cmp	QWORD PTR 32[rbp], 0
	jne	.L19
.L2:
	cmp	QWORD PTR 24[rbp], 0
	je	.L12
	mov	ecx, DWORD PTR 0[rbp]
	mov	eax, DWORD PTR 4[rbp]
	mov	edx, 2
	mov	esi, 3
	or	rbx, QWORD PTR KPC_REE0[rip]
	cmp	QWORD PTR 16[rbp], 0
	je	.L4
.L21:
	or	rbx, QWORD PTR KPC_REE1[rip]
	mov	edx, 4
	cmp	ecx, 4
	cmovb	ecx, edx
	or	esi, 12
	test	eax, eax
	jne	.L20
.L6:
	mov	edx, 1
	not	esi
	sal	edx, cl
	lea	eax, -1[rdx]
	and	eax, esi
.L7:
	mov	DWORD PTR [r12], eax
	test	ecx, ecx
	jne	.L9
.L8:
	or	rbx, QWORD PTR KPC_RE_ZERO_DEB[rip]
	mov	edi, DWORD PTR KPC[rip]
	mov	rsi, rbx
	call	keypad_writel@PLT
	mov	rsi, QWORD PTR DEFAULT_KPREC[rip]
	mov	edi, DWORD PTR KPREC[rip]
	call	keypad_writel@PLT
	mov	rsi, QWORD PTR 8[rbp]
	mov	edi, DWORD PTR KPKDI[rip]
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbx
	.cfi_def_cfa_offset 32
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	keypad_writel@PLT
	.p2align 4,,10
	.p2align 3
.L12:
	.cfi_restore_state
	xor	edx, edx
	xor	esi, esi
	cmp	QWORD PTR 16[rbp], 0
	mov	ecx, DWORD PTR 0[rbp]
	mov	eax, DWORD PTR 4[rbp]
	jne	.L21
.L4:
	cmp	edx, ecx
	cmovnb	ecx, edx
	test	eax, eax
	jne	.L7
	jmp	.L6
	.p2align 4,,10
	.p2align 3
.L20:
	mov	DWORD PTR [r12], eax
.L9:
	mov	r12, QWORD PTR KPC_DE[rip]
	mov	edi, ecx
	or	r12, QWORD PTR KPC_DIE[rip]
	call	KPC_DKN@PLT
	or	rbx, r12
	or	rbx, rax
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L19:
	mov	r13, QWORD PTR KPC_ASACT[rip]
	or	r13, QWORD PTR KPC_MIE[rip]
	or	r13, QWORD PTR KPC_ME[rip]
	or	r13, QWORD PTR KPC_MS_ALL[rip]
	call	KPC_MKRN@PLT
	mov	rdi, QWORD PTR 32[rbp]
	mov	rbx, rax
	call	KPC_MKCN@PLT
	or	rbx, r13
	or	rbx, rax
	jmp	.L2
	.cfi_endproc
.LFE0:
	.size	pxa27x_keypad_config, .-pxa27x_keypad_config
	.comm	KPREC,4,4
	.comm	KPKDI,4,4
	.comm	KPC_RE_ZERO_DEB,8,8
	.comm	KPC_REE1,8,8
	.comm	KPC_REE0,8,8
	.comm	KPC_MS_ALL,8,8
	.comm	KPC_MIE,8,8
	.comm	KPC_ME,8,8
	.comm	KPC_DIE,8,8
	.comm	KPC_DE,8,8
	.comm	KPC_ASACT,8,8
	.comm	KPC,4,4
	.comm	DEFAULT_KPREC,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_pxa27x_keypad.c_pxa27x_keypad_config.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	pxa27x_keypad_config, %function
pxa27x_keypad_config:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	ldr	r7, .L20
	ldr	r5, [r0, #4]
	mov	r6, r0
	ldr	r0, [r7]
	bl	keypad_readl
	ldr	r0, [r5, #24]
	cmp	r0, #0
	moveq	r4, r0
	beq	.L2
	ldr	r4, [r5, #20]
	cmp	r4, #0
	bne	.L18
.L2:
	ldr	r0, [r5, #16]
	ldr	r2, [r5, #12]
	cmp	r0, #0
	ldrne	r3, .L20+4
	movne	r0, #2
	ldrne	r3, [r3]
	movne	r1, #3
	orrne	r4, r4, r3
	moveq	r1, r0
	cmp	r2, #0
	ldr	r3, [r5]
	ldr	r2, [r5, #4]
	beq	.L4
	ldr	r0, .L20+8
	cmp	r3, #4
	ldr	ip, [r0]
	movcs	r0, r3
	movcc	r0, #4
	cmp	r2, #0
	orr	r4, r4, ip
	orreq	r1, r1, #12
	bne	.L19
.L6:
	mvn	r1, r1
	mvn	r2, #0
	bic	r2, r1, r2, lsl r0
.L7:
	cmp	r0, #0
	str	r2, [r6]
	bne	.L9
.L8:
	ldr	r3, .L20+12
	ldr	r0, [r7]
	ldr	r1, [r3]
	orr	r1, r4, r1
	bl	keypad_writel
	ldr	r3, .L20+16
	ldr	r2, .L20+20
	ldr	r0, [r3]
	ldr	r1, [r2]
	bl	keypad_writel
	ldr	r3, .L20+24
	ldr	r1, [r5, #8]
	ldr	r0, [r3]
	pop	{r4, r5, r6, r7, r8, lr}
	b	keypad_writel
.L19:
	str	r2, [r6]
.L9:
	ldr	r2, .L20+28
	ldr	r3, .L20+32
	ldr	r6, [r2]
	ldr	r1, [r3]
	orr	r6, r6, r1
	bl	KPC_DKN
	orr	r4, r6, r4
	orr	r4, r0, r4
	b	.L8
.L4:
	cmp	r0, r3
	movcc	r0, r3
	cmp	r2, #0
	bne	.L7
	b	.L6
.L18:
	ldr	r1, .L20+36
	ldr	r2, .L20+40
	ldr	r3, .L20+44
	ldr	r8, [r1]
	ldr	r4, [r2]
	ldr	r3, [r3]
	ldr	r2, .L20+48
	orr	r3, r3, r8
	ldr	r8, [r2]
	orr	r3, r3, r4
	orr	r8, r3, r8
	bl	KPC_MKRN
	mov	r4, r0
	ldr	r0, [r5, #20]
	bl	KPC_MKCN
	orr	r4, r4, r8
	orr	r4, r4, r0
	b	.L2
.L21:
	.align	2
.L20:
	.word	KPC
	.word	KPC_REE0
	.word	KPC_REE1
	.word	KPC_RE_ZERO_DEB
	.word	KPREC
	.word	DEFAULT_KPREC
	.word	KPKDI
	.word	KPC_DE
	.word	KPC_DIE
	.word	KPC_MIE
	.word	KPC_ME
	.word	KPC_ASACT
	.word	KPC_MS_ALL
	.size	pxa27x_keypad_config, .-pxa27x_keypad_config
	.comm	KPREC,4,4
	.comm	KPKDI,4,4
	.comm	KPC_RE_ZERO_DEB,4,4
	.comm	KPC_REE1,4,4
	.comm	KPC_REE0,4,4
	.comm	KPC_MS_ALL,4,4
	.comm	KPC_MIE,4,4
	.comm	KPC_ME,4,4
	.comm	KPC_DIE,4,4
	.comm	KPC_DE,4,4
	.comm	KPC_ASACT,4,4
	.comm	KPC,4,4
	.comm	DEFAULT_KPREC,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
