	.file	"extr_ice1712.c_snd_ice1712_pro_route_spdif_put.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	snd_ice1712_pro_route_spdif_put, @function
snd_ice1712_pro_route_spdif_put:
.LFB0:
	.cfi_startproc
	endbr64
	push	r13
	.cfi_def_cfa_offset 16
	.cfi_offset 13, -16
	mov	r13, rsi
	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
	push	rbx
	.cfi_def_cfa_offset 40
	.cfi_offset 3, -40
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	call	snd_kcontrol_chip@PLT
	lea	rsi, 8[r13]
	mov	rdi, rbp
	mov	r12, rax
	call	snd_ctl_get_ioffidx@PLT
	mov	rdi, r12
	mov	ebx, eax
	call	spin_lock_irq@PLT
	mov	esi, DWORD PTR ROUTE_SPDOUT[rip]
	mov	rdi, r12
	call	ICEMT@PLT
	mov	edi, eax
	call	inw@PLT
	mov	rdx, QWORD PTR 0[r13]
	lea	ecx, [rbx+rbx]
	mov	edx, DWORD PTR [rdx]
	cmp	edx, 10
	jg	.L2
	mov	edi, 3
	sal	edi, cl
	mov	ebp, edi
	not	ebp
	mov	esi, ebp
	and	esi, eax
	cmp	edx, 8
	jle	.L11
	or	edi, esi
	lea	ecx, 8[0+rbx*4]
	mov	esi, 8
	sal	esi, cl
	lea	ebp, -72[0+rdx*8]
	not	esi
	sal	ebp, cl
	and	esi, edi
	or	ebp, esi
	jmp	.L7
	.p2align 4,,10
	.p2align 3
.L2:
	mov	esi, 3
	mov	ebp, 1
	sal	esi, cl
	sal	ebp, cl
	not	esi
	and	esi, eax
.L5:
	or	ebp, esi
.L7:
	xor	r13d, r13d
	cmp	ebp, eax
	setne	r13b
	je	.L6
	mov	esi, DWORD PTR ROUTE_SPDOUT[rip]
	mov	rdi, r12
	call	ICEMT@PLT
	mov	edi, ebp
	mov	esi, eax
	call	outw@PLT
.L6:
	mov	rdi, r12
	call	spin_unlock_irq@PLT
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r13d
	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
	ret
	.p2align 4,,10
	.p2align 3
.L11:
	.cfi_restore_state
	xor	ebp, ebp
	test	edx, edx
	jle	.L5
	mov	ebp, 2
	mov	edi, 7
	sub	edx, 1
	sal	ebp, cl
	lea	ecx, 8[0+rbx*4]
	sal	edi, cl
	or	esi, ebp
	sal	edx, cl
	mov	ebp, edi
	not	ebp
	and	ebp, esi
	or	ebp, edx
	jmp	.L7
	.cfi_endproc
.LFE0:
	.size	snd_ice1712_pro_route_spdif_put, .-snd_ice1712_pro_route_spdif_put
	.comm	ROUTE_SPDOUT,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_ice1712.c_snd_ice1712_pro_route_spdif_put.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	snd_ice1712_pro_route_spdif_put, %function
snd_ice1712_pro_route_spdif_put:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r8, r1
	mov	r4, r0
	bl	snd_kcontrol_chip
	add	r1, r8, #4
	mov	r6, r0
	mov	r0, r4
	bl	snd_ctl_get_ioffidx
	ldr	r5, .L12
	mov	r7, r0
	mov	r0, r6
	bl	spin_lock_irq
	ldr	r1, [r5]
	mov	r0, r6
	bl	ICEMT
	bl	inw
	ldr	r3, [r8]
	ldr	r2, [r3]
	cmp	r2, #10
	bgt	.L2
	mov	r3, #3
	lsl	r4, r7, #1
	lsl	r3, r3, r4
	cmp	r2, #8
	bic	r1, r0, r3
	ble	.L11
	mov	ip, #8
	add	r7, r7, #2
	lsl	r7, r7, #2
	orr	r4, r3, r1
	sub	r2, r2, #9
	lsl	r2, r2, #3
	bic	r4, r4, ip, lsl r7
	orr	r4, r4, r2, lsl r7
.L7:
	cmp	r4, r0
	movne	r7, #1
	moveq	r7, #0
	beq	.L6
	ldr	r1, [r5]
	mov	r0, r6
	bl	ICEMT
	mov	r1, r0
	mov	r0, r4
	bl	outw
.L6:
	mov	r0, r6
	bl	spin_unlock_irq
	mov	r0, r7
	pop	{r4, r5, r6, r7, r8, pc}
.L2:
	mov	r4, #1
	mov	r1, #3
	lsl	r7, r7, r4
	lsl	r4, r4, r7
	bic	r1, r0, r1, lsl r7
.L5:
	orr	r4, r4, r1
	b	.L7
.L11:
	cmp	r2, #0
	movle	r4, #0
	ble	.L5
	mov	r3, #2
	mov	ip, #7
	add	r7, r7, r3
	lsl	r7, r7, r3
	orr	r4, r1, r3, lsl r4
	sub	r2, r2, #1
	bic	r4, r4, ip, lsl r7
	orr	r4, r4, r2, lsl r7
	b	.L7
.L13:
	.align	2
.L12:
	.word	ROUTE_SPDOUT
	.size	snd_ice1712_pro_route_spdif_put, .-snd_ice1712_pro_route_spdif_put
	.comm	ROUTE_SPDOUT,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
