Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 47286

Summary: add post mixer restore script to /etc/init.d/alsasound
Product: Gentoo Linux Reporter: Carter Smithhart <carter.smithhart>
Component: [OLD] UnspecifiedAssignee: Jeremy Huddleston (RETIRED) <eradicator>
Status: RESOLVED DUPLICATE    
Severity: enhancement CC: gentoo-bugs, sound
Priority: High    
Version: unspecified   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Attachments: the patch.
the patch

Description Carter Smithhart 2004-04-08 17:17:16 UTC
/etc/init.d/alsasound.patch: provides the ability to write driver specific scripts, but I needed to provide a post driver load script, so here's a potential patch to solve this problem.

Reproducible: Always
Steps to Reproduce:
1. I added a emu10k1-post script in /etc/alsa.d that contains:
smith@innervision smithhcl $ cat /etc/alsa.d/emu10k1-post
#!/bin/bash
amixer set "Audigy Analog/Digital Output Jack" off

2.
3.

Actual Results:  
this patch provides the ability to add post mixer restore scripts per sound
driver. I ran into a problem where alsactl save/restore wasn't saving the
digital off/on setting, so I added a post mixer restore script and now
everything works.


Another solution would be to modify /etc/init.d/alsasound to execute the
commands that I needed to run, but I thought this patch was a better approach.
Comment 1 Carter Smithhart 2004-04-08 17:17:44 UTC
Created attachment 28917 [details]
the patch.
Comment 2 Jeremy Huddleston (RETIRED) gentoo-dev 2004-04-09 09:33:10 UTC
please post this a plain text.

I thought this functionality was already in there...
Comment 3 Carter Smithhart 2004-04-09 15:19:47 UTC
Created attachment 28994 [details, diff]
the patch
Comment 4 Carter Smithhart 2004-04-09 15:23:13 UTC
The problem is that the driver specific script gets executed before the mixer restore. The mixer restore step erases this one mixer setting and sets it to "on".

amixer set "Audigy Analog/Digital Output Jack" off

So my solution was to add a post-mixer-restore-per-driver script that allowed me to execute the above line AFTER the mixer restore.

Perhaps there's another solution though?
Comment 5 Jeremy Huddleston (RETIRED) gentoo-dev 2004-04-09 23:51:41 UTC
right... but if you set it to off and save your mixer settings, it should be off next time they're restored...  if they're not, then that is a bug in alsactl.
Comment 6 Jeremy Huddleston (RETIRED) gentoo-dev 2004-04-10 08:21:47 UTC
*** Bug 47405 has been marked as a duplicate of this bug. ***
Comment 7 Jeremy Huddleston (RETIRED) gentoo-dev 2004-04-10 08:25:57 UTC

*** This bug has been marked as a duplicate of 44940 ***
Comment 8 Carter Smithhart 2004-07-03 11:04:39 UTC
I don't know if anything was done to solve this problem... But it's fixed as of alsa 1.0.5