	.file	"extr_cs47l35.c_cs47l35_remove.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	cs47l35_remove, @function
cs47l35_remove:
.LFB0:
	.cfi_startproc
	endbr64
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	mov	r12, rdi
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	call	platform_get_drvdata@PLT
	mov	rdi, r12
	mov	rbp, rax
	call	pm_runtime_disable@PLT
	mov	eax, DWORD PTR CS47L35_NUM_ADSP[rip]
	test	eax, eax
	jle	.L2
	xor	ebx, ebx
	.p2align 4,,10
	.p2align 3
.L3:
	mov	rax, QWORD PTR 8[rbp]
	lea	rdi, [rax+rbx*4]
	add	rbx, 1
	call	wm_adsp2_remove@PLT
	cmp	DWORD PTR CS47L35_NUM_ADSP[rip], ebx
	jg	.L3
.L2:
	mov	edi, DWORD PTR 0[rbp]
	mov	esi, DWORD PTR MADERA_IRQ_DSP_IRQ1[rip]
	xor	edx, edx
	call	madera_set_irq_wake@PLT
	mov	esi, DWORD PTR MADERA_IRQ_DSP_IRQ1[rip]
	mov	edi, DWORD PTR 0[rbp]
	mov	rdx, rbp
	call	madera_free_irq@PLT
	mov	rdi, rbp
	call	madera_free_overheat@PLT
	mov	rdi, rbp
	call	madera_core_free@PLT
	pop	rbx
	.cfi_def_cfa_offset 24
	xor	eax, eax
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.cfi_endproc
.LFE0:
	.size	cs47l35_remove, .-cs47l35_remove
	.comm	MADERA_IRQ_DSP_IRQ1,4,4
	.comm	CS47L35_NUM_ADSP,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_cs47l35.c_cs47l35_remove.c"
	.text
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	cs47l35_remove, %function
cs47l35_remove:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	push	{r4, r5, r6, lr}
	mov	r4, r0
	bl	platform_get_drvdata
	ldr	r6, .L7
	mov	r5, r0
	mov	r0, r4
	bl	pm_runtime_disable
	ldr	r3, [r6]
	cmp	r3, #0
	ble	.L2
	mov	r4, #0
.L3:
	ldr	r0, [r5, #4]
	add	r0, r0, r4, lsl #2
	bl	wm_adsp2_remove
	ldr	r3, [r6]
	add	r4, r4, #1
	cmp	r3, r4
	bgt	.L3
.L2:
	ldr	r4, .L7+4
	mov	r2, #0
	ldr	r1, [r4]
	ldr	r0, [r5]
	bl	madera_set_irq_wake
	mov	r2, r5
	ldr	r1, [r4]
	ldr	r0, [r5]
	bl	madera_free_irq
	mov	r0, r5
	bl	madera_free_overheat
	mov	r0, r5
	bl	madera_core_free
	mov	r0, #0
	pop	{r4, r5, r6, pc}
.L8:
	.align	2
.L7:
	.word	CS47L35_NUM_ADSP
	.word	MADERA_IRQ_DSP_IRQ1
	.size	cs47l35_remove, .-cs47l35_remove
	.comm	MADERA_IRQ_DSP_IRQ1,4,4
	.comm	CS47L35_NUM_ADSP,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
