	.file	"extr_ac97_codec.c_ac97_read_mixer.c"
	.intel_syntax noprefix
	.text
	.p2align 4
	.type	ac97_read_mixer, @function
ac97_read_mixer:
.LFB0:
	.cfi_startproc
	endbr64
	mov	rax, QWORD PTR ac97_hw[rip]
	movsx	rdx, esi
	push	r12
	.cfi_def_cfa_offset 16
	.cfi_offset 12, -16
	push	rbp
	.cfi_def_cfa_offset 24
	.cfi_offset 6, -24
	mov	r12, rdx
	mov	rbp, rdi
	push	rbx
	.cfi_def_cfa_offset 32
	.cfi_offset 3, -32
	lea	rbx, [rax+rdx*8]
	mov	esi, DWORD PTR 4[rbx]
	call	[QWORD PTR [rdi]]
	mov	esi, eax
	xor	eax, eax
	test	DWORD PTR AC97_MUTE[rip], esi
	jne	.L1
	mov	eax, DWORD PTR AC97_STEREO_MASK[rip]
	mov	ecx, r12d
	sar	eax, cl
	and	eax, 1
	je	.L3
	mov	edx, esi
	sar	esi, 8
	and	edx, 127
	and	esi, 127
	imul	eax, edx, 100
	imul	esi, esi, 100
	cmp	DWORD PTR SOUND_MIXER_IGAIN[rip], r12d
	je	.L20
	cmp	DWORD PTR SOUND_MIXER_VOLUME[rip], r12d
	je	.L6
	cmp	DWORD PTR SOUND_MIXER_ALTPCM[rip], r12d
	je	.L6
	mov	edi, DWORD PTR [rbx]
.L8:
	cdq
	mov	r8d, 100
	idiv	edi
	mov	ecx, r8d
	sub	ecx, eax
	mov	eax, esi
	cdq
	idiv	edi
	sub	r8d, eax
.L5:
	mov	eax, ecx
	sal	eax, 8
	or	eax, r8d
.L1:
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	ret
	.p2align 4,,10
	.p2align 3
.L3:
	.cfi_restore_state
	cmp	DWORD PTR SOUND_MIXER_SPEAKER[rip], r12d
	je	.L21
	cmp	DWORD PTR SOUND_MIXER_PHONEIN[rip], r12d
	je	.L18
	cmp	DWORD PTR SOUND_MIXER_PHONEOUT[rip], r12d
	je	.L22
	cmp	DWORD PTR SOUND_MIXER_MIC[rip], r12d
	je	.L18
	cmp	DWORD PTR SOUND_MIXER_BASS[rip], r12d
	je	.L23
	cmp	DWORD PTR SOUND_MIXER_TREBLE[rip], r12d
	jne	.L1
.L17:
	and	esi, 14
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L20:
	mov	edi, DWORD PTR [rbx]
	cdq
	idiv	edi
	mov	ecx, eax
	mov	eax, esi
	cdq
	idiv	edi
	mov	r8d, eax
	jmp	.L5
	.p2align 4,,10
	.p2align 3
.L21:
	sar	esi
	and	esi, 15
.L16:
	imul	eax, esi, 100
	cdq
	idiv	DWORD PTR [rbx]
	mov	edx, 100
	pop	rbx
	.cfi_remember_state
	.cfi_def_cfa_offset 24
	pop	rbp
	.cfi_def_cfa_offset 16
	pop	r12
	.cfi_def_cfa_offset 8
	sub	edx, eax
	mov	eax, edx
	ret
	.p2align 4,,10
	.p2align 3
.L18:
	.cfi_restore_state
	and	esi, 31
	jmp	.L16
	.p2align 4,,10
	.p2align 3
.L6:
	mov	ecx, DWORD PTR 8[rbp]
	mov	edi, 1
	sal	edi, cl
	jmp	.L8
	.p2align 4,,10
	.p2align 3
.L22:
	and	esi, 31
	mov	ecx, DWORD PTR 8[rbp]
	mov	eax, 100
	imul	esi, esi, 100
	sar	esi, cl
	sub	eax, esi
	jmp	.L1
	.p2align 4,,10
	.p2align 3
.L23:
	sar	esi, 8
	jmp	.L17
	.cfi_endproc
.LFE0:
	.size	ac97_read_mixer, .-ac97_read_mixer
	.comm	ac97_hw,8,8
	.comm	SOUND_MIXER_VOLUME,4,4
	.comm	SOUND_MIXER_TREBLE,4,4
	.comm	SOUND_MIXER_SPEAKER,4,4
	.comm	SOUND_MIXER_PHONEOUT,4,4
	.comm	SOUND_MIXER_PHONEIN,4,4
	.comm	SOUND_MIXER_MIC,4,4
	.comm	SOUND_MIXER_IGAIN,4,4
	.comm	SOUND_MIXER_BASS,4,4
	.comm	SOUND_MIXER_ALTPCM,4,4
	.comm	AC97_STEREO_MASK,4,4
	.comm	AC97_MUTE,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_ac97_codec.c_ac97_read_mixer.c"
	.text
	.global	__aeabi_idiv
	.align	2
	.syntax unified
	.arm
	.fpu softvfp
	.type	ac97_read_mixer, %function
ac97_read_mixer:
	@ args = 0, pretend = 0, frame = 0
	@ frame_needed = 0, uses_anonymous_args = 0
	ldr	r2, .L22
	push	{r4, r5, r6, r7, r8, lr}
	ldr	r4, [r2]
	mov	r5, r1
	add	r2, r4, r1, lsl #3
	ldr	r1, [r2, #4]
	ldr	r3, [r0]
	mov	r6, r0
	blx	r3
	ldr	r2, .L22+4
	ldr	r2, [r2]
	tst	r0, r2
	bne	.L14
	ldr	r2, .L22+8
	mov	r3, r0
	ldr	r0, [r2]
	asr	r0, r0, r5
	ands	r0, r0, #1
	beq	.L3
	ldr	r2, .L22+12
	asr	r0, r3, #8
	ldr	r2, [r2]
	and	r0, r0, #127
	and	r3, r3, #127
	add	r0, r0, r0, lsl #2
	add	r3, r3, r3, lsl #2
	add	r0, r0, r0, lsl #2
	add	r3, r3, r3, lsl #2
	cmp	r2, r5
	lsl	r7, r0, #2
	lsl	r0, r3, #2
	beq	.L19
	ldr	r3, .L22+16
	ldr	r3, [r3]
	cmp	r3, r5
	beq	.L6
	ldr	r3, .L22+20
	ldr	r3, [r3]
	cmp	r3, r5
	ldrne	r5, [r4, r5, lsl #3]
	beq	.L6
.L8:
	mov	r1, r5
	bl	__aeabi_idiv
	mov	r1, r5
	mov	r4, r0
	mov	r0, r7
	bl	__aeabi_idiv
	rsb	r4, r4, #100
	rsb	r0, r0, #100
.L5:
	orr	r0, r0, r4, lsl #8
	pop	{r4, r5, r6, r7, r8, pc}
.L14:
	mov	r0, #0
	pop	{r4, r5, r6, r7, r8, pc}
.L3:
	ldr	r2, .L22+24
	ldr	r2, [r2]
	cmp	r2, r5
	asreq	r0, r3, #1
	andeq	r0, r0, #15
	beq	.L16
	ldr	r2, .L22+28
	ldr	r2, [r2]
	cmp	r2, r5
	beq	.L20
	ldr	r2, .L22+32
	ldr	r2, [r2]
	cmp	r2, r5
	beq	.L21
	ldr	r2, .L22+36
	ldr	r2, [r2]
	cmp	r2, r5
	andeq	r3, r3, #31
	beq	.L17
	ldr	r2, .L22+40
	ldr	r2, [r2]
	cmp	r2, r5
	asreq	r0, r3, #8
	andeq	r0, r0, #14
	beq	.L16
	ldr	r2, .L22+44
	ldr	r2, [r2]
	cmp	r2, r5
	popne	{r4, r5, r6, r7, r8, pc}
	and	r3, r3, #14
.L17:
	add	r3, r3, r3, lsl #2
	add	r3, r3, r3, lsl #2
	ldr	r1, [r4, r2, lsl #3]
	lsl	r0, r3, #2
	bl	__aeabi_idiv
	rsb	r0, r0, #100
	pop	{r4, r5, r6, r7, r8, pc}
.L20:
	and	r0, r3, #31
.L16:
	add	r0, r0, r0, lsl #2
	add	r0, r0, r0, lsl #2
	ldr	r1, [r4, r2, lsl #3]
	lsl	r0, r0, #2
	bl	__aeabi_idiv
	rsb	r0, r0, #100
	pop	{r4, r5, r6, r7, r8, pc}
.L19:
	ldr	r5, [r4, r2, lsl #3]
	mov	r1, r5
	bl	__aeabi_idiv
	mov	r1, r5
	mov	r4, r0
	mov	r0, r7
	bl	__aeabi_idiv
	b	.L5
.L6:
	mov	r5, #1
	ldr	r1, [r6, #4]
	lsl	r5, r5, r1
	b	.L8
.L21:
	and	r3, r3, #31
	add	r3, r3, r3, lsl #2
	ldr	r2, [r6, #4]
	add	r3, r3, r3, lsl #2
	lsl	r0, r3, #2
	asr	r0, r0, r2
	rsb	r0, r0, #100
	pop	{r4, r5, r6, r7, r8, pc}
.L23:
	.align	2
.L22:
	.word	ac97_hw
	.word	AC97_MUTE
	.word	AC97_STEREO_MASK
	.word	SOUND_MIXER_IGAIN
	.word	SOUND_MIXER_VOLUME
	.word	SOUND_MIXER_ALTPCM
	.word	SOUND_MIXER_SPEAKER
	.word	SOUND_MIXER_PHONEIN
	.word	SOUND_MIXER_PHONEOUT
	.word	SOUND_MIXER_MIC
	.word	SOUND_MIXER_BASS
	.word	SOUND_MIXER_TREBLE
	.size	ac97_read_mixer, .-ac97_read_mixer
	.comm	ac97_hw,4,4
	.comm	SOUND_MIXER_VOLUME,4,4
	.comm	SOUND_MIXER_TREBLE,4,4
	.comm	SOUND_MIXER_SPEAKER,4,4
	.comm	SOUND_MIXER_PHONEOUT,4,4
	.comm	SOUND_MIXER_PHONEIN,4,4
	.comm	SOUND_MIXER_MIC,4,4
	.comm	SOUND_MIXER_IGAIN,4,4
	.comm	SOUND_MIXER_BASS,4,4
	.comm	SOUND_MIXER_ALTPCM,4,4
	.comm	AC97_STEREO_MASK,4,4
	.comm	AC97_MUTE,4,4
	.ident	"GCC: (Ubuntu 9.4.0-1ubuntu1~20.04.2) 9.4.0"
	.section	.note.GNU-stack,"",%progbits
