summaryrefslogtreecommitdiffstats
path: root/sys/dev/sound
diff options
context:
space:
mode:
authorariff <ariff@FreeBSD.org>2007-03-05 07:45:38 +0000
committerariff <ariff@FreeBSD.org>2007-03-05 07:45:38 +0000
commit914d3ae38712a1c29d4651be96661fe4c36cfab0 (patch)
tree89b3b685f9537235387c71f77fd6a498e564ac01 /sys/dev/sound
parentfd84d7e97e3e7b0db5c08b39c6a0339eeaf22bdb (diff)
downloadFreeBSD-src-914d3ae38712a1c29d4651be96661fe4c36cfab0.zip
FreeBSD-src-914d3ae38712a1c29d4651be96661fe4c36cfab0.tar.gz
Quick bandaid for possible broken multiple playback channels implementation.
Reported/Tested by: Oliver Iberien <odilist@sonic.net>
Diffstat (limited to 'sys/dev/sound')
-rw-r--r--sys/dev/sound/pci/envy24.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/dev/sound/pci/envy24.c b/sys/dev/sound/pci/envy24.c
index 33cdb74..8de3c3b 100644
--- a/sys/dev/sound/pci/envy24.c
+++ b/sys/dev/sound/pci/envy24.c
@@ -2413,15 +2413,16 @@ envy24_pci_attach(device_t dev)
mixer_init(dev, &envy24mixer_class, sc);
/* set channel information */
- err = pcm_register(dev, sc, 5, 2 + sc->adcn);
+ err = pcm_register(dev, sc, sc->dacn, sc->adcn);
if (err)
goto bad;
- sc->chnum = 0;
- for (i = 0; i < 5; i++) {
+ sc->chnum = ENVY24_CHAN_PLAY_DAC1;
+ for (i = 0; i < sc->dacn; i++) {
pcm_addchan(dev, PCMDIR_PLAY, &envy24chan_class, sc);
sc->chnum++;
}
- for (i = 0; i < 2 + sc->adcn; i++) {
+ sc->chnum = ENVY24_CHAN_REC_ADC1;
+ for (i = 0; i < sc->adcn; i++) {
pcm_addchan(dev, PCMDIR_REC, &envy24chan_class, sc);
sc->chnum++;
}
OpenPOWER on IntegriCloud