Bug 84030

Summary: redhat-config-soundcard is not compatible with Alsa sound
Product: [Retired] Red Hat Linux Reporter: Brian "netdragon" Bober <netdragon>
Component: redhat-config-soundcardAssignee: Brent Fox <bfox>
Status: CLOSED WORKSFORME QA Contact:
Severity: medium Docs Contact:
Priority: medium    
Version: 8.0   
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
URL: http://groups.google.com/groups?q=Alsa+mini+guide&hl=en&lr=&ie=UTF-8&oe=UTF-8&selm=3E2CB4CB.4060503%40nospam.nospam&rnum=2
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2003-03-20 20:48:27 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Brian "netdragon" Bober 2003-02-11 03:23:07 UTC
Description of problem:
Running redhat-config-soundcard will install /dev/dsp1 .. /dev/dspn and mess up Alsa

How reproducible:
Install Alsa, run redhat-config-soundcard

Actual results:
Installs /dev/dsp1, etc which makes Alsa not work, you have to do the following
to make Alsa work again:

rm -f /dev/dsp, /dev/dsp0, etc (but not /dev/dsp56k).

mknod /dev/dsp c 14 3

Expected results:
redhat-config-soundcard doesn't install more dsp devices.

Additional info:
I have only one soundcard, its an AC'97. Alsa works correctly, and after doing
the following, I never had anymore problems:

chmod 000 /path/to/redhat-config-soundcard


 :-)

Comment 1 Brian "netdragon" Bober 2003-02-11 03:24:08 UTC
Maybe severity=high isn't the correct severity because its not dataloss.

Comment 2 Brent Fox 2003-02-11 17:12:09 UTC
redhat-config-soundcard doesn't touch anything in /dev/.  All it does is writes
a new /etc/modules.conf file, unloads all the soundcard drivers, and then
reloads them so that the changes in /etc/modules.conf are applied.

When you play the test sound, it calls /usr/bin/play with the specified device
in /dev/

    def playTestSound(self, module):
        if self.dspList.index(module) == 0:
            device = "/dev/dsp"
        else:
            device = "/dev/dsp%d" % self.dspList.index(module)

        path = "/usr/bin/play"
        pid = os.fork()
        args = [path,  "-d", device,
"/usr/share/redhat-config-soundcard/redhat-sample.wav", "-v", "2"]

        if (not pid):
            os.execv(path, args)

But that shouldn't modify the devices in /dev/.



Comment 3 Brian "netdragon" Bober 2003-02-12 17:56:43 UTC
If I install Alsa sound, and have /dev/dsp, it works.
If I run redhat-config-soundcard, it creates /dev/dsp0 and /dev/dsp no longer
works but /dev/dsp0 does and programs don't use /dev/dsp0 but /dev/dsp. Happens
before I play any sound, right after I exit the util.

I have an 845GMax motherboard with an i8x0 AC97 audio.

Your problem looks like it is:  device = "/dev/dsp%d" % self.dspList.index(module)



Comment 4 Brent Fox 2003-02-12 18:28:01 UTC
But as you can see in the above code:

    def playTestSound(self, module):
        if self.dspList.index(module) == 0:
            device = "/dev/dsp"
        else:
            device = "/dev/dsp%d" % self.dspList.index(module)

So it takes the first device in the list (in your case there's only one item in
the list since you have only one soundcard) and makes it "/dev/dsp".  Other
items in the list start numbering at "1" so that additional soundcards are
assigned starting with "/dev/dsp1".

There is no code in redhat-config-soundcard that ever makes the string
"/dev/dsp0".  Also, there is no code in redhat-config-soundcard that actually
modifies the entries in /dev/ at all.  

As I said before, all redhat-config-soundcard does is:

1) Modifies /etc/modules.conf
2) Unloads all soundcard modules
3) Reloads all the soundcard modules to apply the changes to /etc/modules.conf


Can you try to upgrade to the latest redhat-config-soundcard in Rawhide and see
if that makes any difference?

Comment 5 Brent Fox 2003-02-26 17:53:55 UTC
ping?

Comment 6 Brent Fox 2003-03-20 20:48:27 UTC
Closing due to lack of input.