	.file	"extr_cyapa_gen3.c_cyapa_gen3_show_baseline.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"Error reading dev status. err = %d\n"
	.align 8
.LC1:
	.string	"Trackpad device is busy. device state = 0x%x\n"
	.align 8
.LC2:
	.string	"Failed to send report baseline command. %d\n"
	.align 8
.LC3:
	.string	"Failed to read max baseline. err = %d\n"
	.align 8
.LC4:
	.string	"Failed to read min baseline. err = %d\n"
	.align 8
.LC5:
	.string	"Baseline report successful. Max: %d Min: %d\n"
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC6:
	.string	"%d %d\n"
	.section	.rodata.str1.8
	.align 8
.LC7:
	.string	"Device timed out going to Normal state.\n"
	.text
	.p2align 4
	.type	cyapa_gen3_show_baseline, @function
cyapa_gen3_show_baseline:
.LFB0:
	.cfi_startproc
	endbr64
	push	r14
	.cfi_def_cfa_offset 16
	.cfi_offset 14, -16
	mov	r14, rdx
	push	r13
	.cfi_def_cfa_offset 24
	.cfi_offset 13, -24
	mov	r13, rdi
	push	r12
	.cfi_def_cfa_offset 32
	.cfi_offset 12, -32
	push	rbp
	.cfi_def_cfa_offset 40
	.cfi_offset 6, -40
	push	rbx
	.cfi_def_cfa_offset 48
	.cfi_offset 3, -48
	call	dev_get_drvdata@PLT
	mov	esi, DWORD PTR CYAPA_CMD_DEV_STATUS[rip]
	mov	rdi, rax
	mov	rbp, rax
	call	cyapa_read_byte@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L18
	mov	eax, DWORD PTR CYAPA_DEV_NORMAL[rip]
	mov	edx, eax
	and	edx, r12d
	cmp	eax, edx
	jne	.L20
	mov	edx, DWORD PTR OP_REPORT_BASELINE_MASK[rip]
	mov	esi, DWORD PTR CYAPA_CMD_SOFT_RESET[rip]
	mov	rdi, rbp
	mov	ebx, 3
	call	cyapa_write_byte@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L21
.L5:
	mov	esi, 20000
	mov	edi, 10000
	call	usleep_range@PLT
	mov	esi, DWORD PTR CYAPA_CMD_DEV_STATUS[rip]
	mov	rdi, rbp
	call	cyapa_read_byte@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L18
	mov	edx, DWORD PTR CYAPA_DEV_NORMAL[rip]
	and	eax, edx
	cmp	edx, eax
	je	.L7
	sub	ebx, 1
	jne	.L5
	mov	rdi, r13
	lea	rsi, .LC7[rip]
	xor	eax, eax
	call	dev_err@PLT
	mov	r12d, DWORD PTR ETIMEDOUT[rip]
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	pop	rbp
	.cfi_def_cfa_offset 32
	neg	r12d
	mov	eax, r12d
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L20:
	.cfi_restore_state
	mov	edx, r12d
	lea	rsi, .LC1[rip]
	mov	rdi, r13
	call	dev_warn@PLT
	mov	r12d, DWORD PTR EAGAIN[rip]
	neg	r12d
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
.L3:
	.p2align 4,,10
	.p2align 3
.L7:
	.cfi_restore_state
	mov	esi, DWORD PTR CYAPA_CMD_MAX_BASELINE[rip]
	mov	rdi, rbp
	call	cyapa_read_byte@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L22
	mov	esi, DWORD PTR CYAPA_CMD_MIN_BASELINE[rip]
	mov	rdi, rbp
	call	cyapa_read_byte@PLT
	mov	ebx, eax
	test	eax, eax
	js	.L23
	mov	edx, r12d
	mov	rdi, r13
	lea	rsi, .LC5[rip]
	mov	ecx, eax
	call	dev_dbg@PLT
	mov	r8d, ebx
	mov	esi, DWORD PTR PAGE_SIZE[rip]
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	ecx, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	mov	rdi, r14
	pop	r12
	.cfi_def_cfa_offset 24
	lea	rdx, .LC6[rip]
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	jmp	scnprintf@PLT
	.p2align 4,,10
	.p2align 3
.L22:
	.cfi_restore_state
	mov	edx, r12d
	lea	rsi, .LC3[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L18:
	mov	edx, r12d
	mov	rdi, r13
	lea	rsi, .LC0[rip]
	xor	eax, eax
	call	dev_err@PLT
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	pop	rbp
	.cfi_def_cfa_offset 32
	pop	r12
	.cfi_def_cfa_offset 24
	pop	r13
	.cfi_def_cfa_offset 16
	pop	r14
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L21:
	.cfi_restore_state
	mov	edx, eax
	lea	rsi, .LC2[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L23:
	mov	edx, eax
	lea	rsi, .LC4[rip]
	mov	rdi, r13
	xor	eax, eax
	call	dev_err@PLT
	mov	r12d, ebx
	jmp	.L1
	.cfi_endproc
.LFE0:
	.size	cyapa_gen3_show_baseline, .-cyapa_gen3_show_baseline
	.comm	PAGE_SIZE,4,4
	.comm	OP_REPORT_BASELINE_MASK,4,4
	.comm	ETIMEDOUT,4,4
	.comm	EAGAIN,4,4
	.comm	CYAPA_DEV_NORMAL,4,4
	.comm	CYAPA_CMD_SOFT_RESET,4,4
	.comm	CYAPA_CMD_MIN_BASELINE,4,4
	.comm	CYAPA_CMD_MAX_BASELINE,4,4
	.comm	CYAPA_CMD_DEV_STATUS,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_cyapa_gen3.c_cyapa_gen3_show_baseline.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Error reading dev status. err = %d\012\000"
	.align	2
.LC1:
	.ascii	"Trackpad device is busy. device state = 0x%x\012\000"
	.align	2
.LC2:
	.ascii	"Failed to send report baseline command. %d\012\000"
	.align	2
.LC3:
	.ascii	"Failed to read max baseline. err = %d\012\000"
	.align	2
.LC4:
	.ascii	"Failed to read min baseline. err = %d\012\000"
	.align	2
.LC5:
	.ascii	"Baseline report successful. Max: %d Min: %d\012\000"
	.align	2
.LC6:
	.ascii	"%d %d\012\000"
	.align	2
.LC7:
	.ascii	"Device timed out going to Normal state.\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	cyapa_gen3_show_baseline, %function
cyapa_gen3_show_baseline:
	@ args = 0, pretend = 0, frame = 8
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, r9, r10, fp, lr}
	sub	sp, sp, #20
	str	r2, [sp, #12]
	mov	r6, r0
	bl	dev_get_drvdata
	ldr	r9, .L23
	mov	r5, r0
	ldr	r1, [r9]
	bl	cyapa_read_byte
	subs	r4, r0, #0
	blt	.L17
	ldr	r10, .L23+4
	ldr	r3, [r10]
	bics	r3, r3, r4
	bne	.L19
	ldr	r3, .L23+8
	ldr	r2, .L23+12
	mov	r0, r5
	ldr	r2, [r2]
	ldr	r1, [r3]
	bl	cyapa_write_byte
	subs	r4, r0, #0
	blt	.L20
	mov	r8, #3
	ldr	r7, .L23+16
	ldr	fp, .L23+20
.L5:
	mov	r1, r7
	mov	r0, fp
	bl	usleep_range
	mov	r0, r5
	ldr	r1, [r9]
	bl	cyapa_read_byte
	subs	r4, r0, #0
	blt	.L17
	ldr	r2, [r10]
	bics	r3, r2, r4
	beq	.L7
	subs	r8, r8, #1
	bne	.L5
	mov	r0, r6
	ldr	r1, .L23+24
	bl	dev_err
	ldr	r3, .L23+28
	ldr	r0, [r3]
	rsb	r4, r0, #0
	mov	r0, r4
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L19:
	mov	r2, r4
	mov	r0, r6
	ldr	r1, .L23+32
	bl	dev_warn
	ldr	r3, .L23+36
	ldr	r0, [r3]
	rsb	r4, r0, #0
.L1:
	mov	r0, r4
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L7:
	ldr	r3, .L23+40
	mov	r0, r5
	ldr	r1, [r3]
	bl	cyapa_read_byte
	subs	r4, r0, #0
	blt	.L21
	ldr	r3, .L23+44
	mov	r0, r5
	ldr	r1, [r3]
	bl	cyapa_read_byte
	subs	r5, r0, #0
	mov	r0, r6
	blt	.L22
.L3:
	mov	r3, r5
	mov	r2, r4
	ldr	r1, .L23+48
	bl	dev_dbg
	ldr	r2, .L23+52
	str	r5, [sp]
	mov	r3, r4
	ldr	r1, [r2]
	ldr	r0, [sp, #12]
	ldr	r2, .L23+56
	bl	scnprintf
	mov	r4, r0
	mov	r0, r4
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L21:
	mov	r0, r6
	mov	r2, r4
	ldr	r1, .L23+60
	bl	dev_err
	b	.L1
.L17:
	mov	r0, r6
	mov	r2, r4
	ldr	r1, .L23+64
	bl	dev_err
	mov	r0, r4
	add	sp, sp, #20
	@ sp needed
	pop	{r4, r5, r6, r7, r8, r9, r10, fp, pc}
.L20:
	mov	r0, r6
	mov	r2, r4
	ldr	r1, .L23+68
	bl	dev_err
	b	.L1
.L22:
	mov	r2, r5
	ldr	r1, .L23+72
	mov	r4, r5
	bl	dev_err
	b	.L1
.L24:
	.align	2
.L23:
	.word	CYAPA_CMD_DEV_STATUS
	.word	CYAPA_DEV_NORMAL
	.word	CYAPA_CMD_SOFT_RESET
	.word	OP_REPORT_BASELINE_MASK
	.word	20000
	.word	10000
	.word	.LC7
	.word	ETIMEDOUT
	.word	.LC1
	.word	EAGAIN
	.word	CYAPA_CMD_MAX_BASELINE
	.word	CYAPA_CMD_MIN_BASELINE
	.word	.LC5
	.word	PAGE_SIZE
	.word	.LC6
	.word	.LC3
	.word	.LC0
	.word	.LC2
	.word	.LC4
	.size	cyapa_gen3_show_baseline, .-cyapa_gen3_show_baseline
	.comm	PAGE_SIZE,4,4
	.comm	OP_REPORT_BASELINE_MASK,4,4
	.comm	ETIMEDOUT,4,4
	.comm	EAGAIN,4,4
	.comm	CYAPA_DEV_NORMAL,4,4
	.comm	CYAPA_CMD_SOFT_RESET,4,4
	.comm	CYAPA_CMD_MIN_BASELINE,4,4
	.comm	CYAPA_CMD_MAX_BASELINE,4,4
	.comm	CYAPA_CMD_DEV_STATUS,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
