patch-2.1.102 linux/drivers/sound/cs4232.c

Next file: linux/drivers/sound/dev_table.h
Previous file: linux/drivers/sound/audio_syms.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.1.101/linux/drivers/sound/cs4232.c linux/drivers/sound/cs4232.c
@@ -34,7 +34,7 @@
 #include "sound_config.h"
 #include "soundmodule.h"
 
-#if defined(CONFIG_CS4232) || defined (MODULE)
+#ifdef CONFIG_CS4232
 
 #define KEY_PORT	0x279	/* Same as LPT1 status port */
 #define CSN_NUM		0x99	/* Just a random number */
@@ -196,7 +196,6 @@
 {
 	int base = hw_config->io_base, irq = hw_config->irq;
 	int dma1 = hw_config->dma, dma2 = hw_config->dma2;
-	int old_num_mixers = num_mixers;
 
 	if (dma2 == -1)
 		dma2 = dma1;
@@ -208,7 +207,8 @@
 					  0,
 					  hw_config->osp);
 
-	if (num_mixers > old_num_mixers)
+	if (hw_config->slots[0] != -1 &&
+		audio_devs[hw_config->slots[0]]->mixer_dev!=-1)
 	{	
 		/* Assume the mixer map is as suggested in the CS4232 databook */
 		AD1848_REROUTE(SOUND_MIXER_LINE1, SOUND_MIXER_LINE);

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov