[ALSA] oxygen: make AC97 codec optional
Only initialize and create mixer controls for the first AC97 codec when one has actually been detected. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
This commit is contained in:

committed by
Jaroslav Kysela

parent
12b74c80cc
commit
31c77643a0
@@ -714,7 +714,7 @@ int __devinit oxygen_pcm_init(struct oxygen *chip)
|
||||
snd_dma_pci_data(chip->pci),
|
||||
128 * 1024, 256 * 1024);
|
||||
|
||||
if (chip->has_2nd_ac97_codec) {
|
||||
if (chip->has_ac97_1) {
|
||||
err = snd_pcm_new(chip->card, "AC97", 2, 1, 0, &pcm);
|
||||
if (err < 0)
|
||||
return err;
|
||||
|
Reference in New Issue
Block a user