	.file	"extr_ctpcm.c_ct_pcm_playback_open.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	ct_pcm_playback_open, @function
ct_pcm_playback_open:
.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
	sub	rsp, 8
	.cfi_def_cfa_offset 48
	call	snd_pcm_substream_chip@PLT
	mov	esi, DWORD PTR GFP_KERNEL[rip]
	mov	edi, 16
	mov	r13, QWORD PTR 8[r12]
	mov	rbx, rax
	call	kzalloc@PLT
	test	rax, rax
	je	.L10
	mov	QWORD PTR 8[rax], r12
	mov	rbp, rax
	mov	eax, DWORD PTR ct_atc_pcm_interrupt[rip]
	mov	DWORD PTR 4[rbp], eax
	mov	eax, DWORD PTR ct_atc_pcm_free_substream[rip]
	mov	QWORD PTR 8[r13], rbp
	mov	DWORD PTR 4[r13], eax
	mov	rax, QWORD PTR [r12]
	mov	rax, QWORD PTR [rax]
	cmp	rax, QWORD PTR IEC958[rip]
	je	.L13
	mov	edx, DWORD PTR ct_pcm_playback_hw[rip]
	cmp	rax, QWORD PTR FRONT[rip]
	mov	DWORD PTR 0[r13], edx
	je	.L14
.L5:
	mov	esi, DWORD PTR SNDRV_PCM_HW_PARAM_PERIODS[rip]
	mov	rdi, r13
	call	snd_pcm_hw_constraint_integer@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L11
	mov	ecx, DWORD PTR UINT_MAX[rip]
	mov	esi, DWORD PTR SNDRV_PCM_HW_PARAM_BUFFER_BYTES[rip]
	mov	edx, 1024
	mov	rdi, r13
	call	snd_pcm_hw_constraint_minmax@PLT
	mov	r12d, eax
	test	eax, eax
	js	.L11
	mov	edi, DWORD PTR [rbx]
	mov	rsi, rbp
	xor	r12d, r12d
	call	ct_timer_instance_new@PLT
	mov	DWORD PTR 0[rbp], eax
	test	eax, eax
	je	.L10
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	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
	mov	rdi, rbp
	call	kfree@PLT
	add	rsp, 8
	.cfi_remember_state
	.cfi_def_cfa_offset 40
	mov	eax, r12d
	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
.L10:
	.cfi_restore_state
	mov	r12d, DWORD PTR ENOMEM[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
	neg	r12d
	mov	eax, r12d
	pop	r12
	.cfi_def_cfa_offset 16
	pop	r13
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L13:
	.cfi_restore_state
	mov	eax, DWORD PTR ct_spdif_passthru_playback_hw[rip]
	mov	esi, 1
	mov	rdi, rbx
	mov	DWORD PTR 0[r13], eax
	call	[QWORD PTR 8[rbx]]
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L14:
	mov	DWORD PTR 0[r13], 8
	jmp	.L5
	.cfi_endproc
.LFE0:
	.size	ct_pcm_playback_open, .-ct_pcm_playback_open
	.comm	ct_spdif_passthru_playback_hw,4,4
	.comm	ct_pcm_playback_hw,4,4
	.comm	ct_atc_pcm_interrupt,4,4
	.comm	ct_atc_pcm_free_substream,4,4
	.comm	UINT_MAX,4,4
	.comm	SNDRV_PCM_HW_PARAM_PERIODS,4,4
	.comm	SNDRV_PCM_HW_PARAM_BUFFER_BYTES,4,4
	.comm	IEC958,8,8
	.comm	GFP_KERNEL,4,4
	.comm	FRONT,8,8
	.comm	ENOMEM,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_ctpcm.c_ct_pcm_playback_open.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	ct_pcm_playback_open, %function
ct_pcm_playback_open:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, r7, r8, lr}
	mov	r4, r0
	bl	snd_pcm_substream_chip
	ldr	r2, .L14
	mov	r6, r0
	ldr	r1, [r2]
	mov	r0, #12
	ldr	r7, [r4, #4]
	bl	kzalloc
	subs	r5, r0, #0
	beq	.L10
	ldr	r3, [r4]
	ldr	r2, .L14+4
	ldr	r3, [r3]
	ldr	r2, [r2]
	ldr	r1, .L14+8
	cmp	r3, r2
	ldr	r2, .L14+12
	ldr	r1, [r1]
	ldr	r2, [r2]
	stmib	r5, {r1, r4}
	stmib	r7, {r2, r5}
	beq	.L13
	ldr	r1, .L14+16
	ldr	r2, .L14+20
	ldr	r1, [r1]
	ldr	r2, [r2]
	cmp	r3, r1
	moveq	r3, #8
	str	r2, [r7]
	streq	r3, [r7]
.L5:
	ldr	r3, .L14+24
	mov	r0, r7
	ldr	r1, [r3]
	bl	snd_pcm_hw_constraint_integer
	subs	r4, r0, #0
	blt	.L11
	ldr	r2, .L14+28
	ldr	r3, .L14+32
	ldr	r1, [r2]
	mov	r0, r7
	mov	r2, #1024
	ldr	r3, [r3]
	bl	snd_pcm_hw_constraint_minmax
	subs	r4, r0, #0
	blt	.L11
	mov	r1, r5
	ldr	r0, [r6]
	bl	ct_timer_instance_new
	cmp	r0, #0
	movne	r4, #0
	str	r0, [r5]
	beq	.L10
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, pc}
.L11:
	mov	r0, r5
	bl	kfree
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, pc}
.L10:
	ldr	r3, .L14+36
	ldr	r4, [r3]
	rsb	r4, r4, #0
	mov	r0, r4
	pop	{r4, r5, r6, r7, r8, pc}
.L13:
	ldr	r2, .L14+40
	ldr	r3, [r6, #4]
	ldr	r2, [r2]
	mov	r1, #1
	mov	r0, r6
	str	r2, [r7]
	blx	r3
	b	.L5
.L15:
	.align	2
.L14:
	.word	GFP_KERNEL
	.word	IEC958
	.word	ct_atc_pcm_interrupt
	.word	ct_atc_pcm_free_substream
	.word	FRONT
	.word	ct_pcm_playback_hw
	.word	SNDRV_PCM_HW_PARAM_PERIODS
	.word	SNDRV_PCM_HW_PARAM_BUFFER_BYTES
	.word	UINT_MAX
	.word	ENOMEM
	.word	ct_spdif_passthru_playback_hw
	.size	ct_pcm_playback_open, .-ct_pcm_playback_open
	.comm	ct_spdif_passthru_playback_hw,4,4
	.comm	ct_pcm_playback_hw,4,4
	.comm	ct_atc_pcm_interrupt,4,4
	.comm	ct_atc_pcm_free_substream,4,4
	.comm	UINT_MAX,4,4
	.comm	SNDRV_PCM_HW_PARAM_PERIODS,4,4
	.comm	SNDRV_PCM_HW_PARAM_BUFFER_BYTES,4,4
	.comm	IEC958,4,4
	.comm	GFP_KERNEL,4,4
	.comm	FRONT,4,4
	.comm	ENOMEM,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
