	.file	"extr_cmt_speech.c_cs_hsi_read_on_control.c"
	.intel_syntax noprefix
	.text
	.section	.rodata.str1.8,"aMS",@progbits,1
	.align 8
.LC0:
	.string	"Control read already pending (%d)\n"
	.section	.rodata.str1.1,"aMS",@progbits,1
.LC1:
	.string	"Control read error (%d)\n"
.LC2:
	.string	"Issuing RX on control\n"
	.text
	.p2align 4
	.type	cs_hsi_read_on_control, @function
cs_hsi_read_on_control:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	lea	r13, 16[rdi]
	push	r12
	.cfi_def_cfa_offset 24
	.cfi_offset 12, -24
	push	rbp
	.cfi_def_cfa_offset 32
	.cfi_offset 6, -32
	mov	rbp, rdi
	mov	rdi, r13
	call	spin_lock@PLT
	mov	edx, DWORD PTR 0[rbp]
	mov	rdi, QWORD PTR 8[rbp]
	lea	rsi, .LC0[rip]
	mov	eax, DWORD PTR SSI_CHANNEL_STATE_READING[rip]
	test	edx, eax
	jne	.L6
	test	DWORD PTR SSI_CHANNEL_STATE_ERROR[rip], edx
	jne	.L8
	or	edx, eax
	lea	rsi, .LC2[rip]
	mov	DWORD PTR 0[rbp], edx
	call	dev_dbg@PLT
	mov	rdi, rbp
	call	cs_claim_cmd@PLT
	mov	rdi, r13
	mov	r12, rax
	call	spin_unlock@PLT
	mov	eax, DWORD PTR cs_hsi_peek_on_control_complete[rip]
	mov	rdi, QWORD PTR 8[rbp]
	mov	rsi, r12
	mov	QWORD PTR 8[r12], 0
	mov	DWORD PTR [r12], eax
	call	hsi_async_read@PLT
	test	eax, eax
	jne	.L9
	pop	rbp
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L8:
	.cfi_restore_state
	lea	rsi, .LC1[rip]
.L6:
	call	dev_err@PLT
	pop	rbp
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	mov	rdi, r13
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	spin_unlock@PLT
	.p2align 4,,10
	.p2align 3
.L9:
	.cfi_restore_state
	mov	rsi, r12
	mov	rdi, rbp
	pop	rbp
	.cfi_def_cfa_offset 24
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	jmp	cs_hsi_control_read_error@PLT
	.cfi_endproc
.LFE0:
	.size	cs_hsi_read_on_control, .-cs_hsi_read_on_control
	.comm	cs_hsi_peek_on_control_complete,4,4
	.comm	SSI_CHANNEL_STATE_READING,4,4
	.comm	SSI_CHANNEL_STATE_ERROR,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_cmt_speech.c_cs_hsi_read_on_control.c"
	.text
	.section	.rodata.str1.4,"aMS",%progbits,1
	.align	2
.LC0:
	.ascii	"Control read already pending (%d)\012\000"
	.align	2
.LC1:
	.ascii	"Control read error (%d)\012\000"
	.align	2
.LC2:
	.ascii	"Issuing RX on control\012\000"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	cs_hsi_read_on_control, %function
cs_hsi_read_on_control:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r0
	add	r7, r0, #8
	mov	r0, r7
	bl	spin_lock
	ldr	r3, .L9
	ldr	r2, [r4]
	ldr	r1, [r3]
	tst	r2, r1
	bne	.L7
	ldr	r3, .L9+4
	ldr	r0, [r4, #4]
	ldr	r3, [r3]
	ands	r5, r2, r3
	bne	.L8
	orr	r2, r2, r1
	str	r2, [r4]
	ldr	r1, .L9+8
	bl	dev_dbg
	mov	r0, r4
	bl	cs_claim_cmd
	mov	r6, r0
	mov	r0, r7
	bl	spin_unlock
	ldr	r3, .L9+12
	mov	r1, r6
	ldr	r3, [r3]
	ldr	r0, [r4, #4]
	str	r5, [r6, #4]
	str	r3, [r6]
	bl	hsi_async_read
	cmp	r0, #0
	popeq	{r4, r5, r6, r7, r8, pc}
	mov	r1, r6
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, lr}
	b	cs_hsi_control_read_error
.L8:
	ldr	r1, .L9+16
	bl	dev_err
	mov	r0, r7
	pop	{r4, r5, r6, r7, r8, lr}
	b	spin_unlock
.L7:
	ldr	r0, [r4, #4]
	ldr	r1, .L9+20
	bl	dev_err
	mov	r0, r7
	pop	{r4, r5, r6, r7, r8, lr}
	b	spin_unlock
.L10:
	.align	2
.L9:
	.word	SSI_CHANNEL_STATE_READING
	.word	SSI_CHANNEL_STATE_ERROR
	.word	.LC2
	.word	cs_hsi_peek_on_control_complete
	.word	.LC1
	.word	.LC0
	.size	cs_hsi_read_on_control, .-cs_hsi_read_on_control
	.comm	cs_hsi_peek_on_control_complete,4,4
	.comm	SSI_CHANNEL_STATE_READING,4,4
	.comm	SSI_CHANNEL_STATE_ERROR,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
