patch-2.4.15 linux/drivers/sound/ac97_codec.c

Next file: linux/drivers/sound/aci.c
Previous file: linux/drivers/scsi/sym53c8xx_2/sym_nvram.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.14/linux/drivers/sound/ac97_codec.c linux/drivers/sound/ac97_codec.c
@@ -130,7 +130,7 @@
 	{0x54524103, "TriTech TR28023",		&null_ops},
 	{0x54524106, "TriTech TR28026",		&null_ops},
 	{0x54524108, "TriTech TR28028",		&tritech_ops},
-	{0x54524123, "TriTech TR?????",		&null_ops},
+	{0x54524123, "TriTech TR A5",		&null_ops},
 	{0x574D4C00, "Wolfson WM9704",		&wolfson_ops},
 	{0x574D4C03, "Wolfson WM9703/9704",	&wolfson_ops},
 	{0x574D4C04, "Wolfson WM9704 (quad)",	&wolfson_ops},
@@ -143,7 +143,6 @@
 	{0x83847656, "SigmaTel STAC9756/57",	&sigmatel_9744_ops},
 	{0x83847684, "SigmaTel STAC9783/84?",	&null_ops},
 	{0x57454301, "Winbond 83971D",		&null_ops},
-	{0,}
 };
 
 static const char *ac97_stereo_enhancements[] =
@@ -1020,4 +1019,31 @@
 }
 
 EXPORT_SYMBOL(ac97_set_adc_rate);
+
+int ac97_save_state(struct ac97_codec *codec)
+{
+	return 0;	
+}
+
+EXPORT_SYMBOL(ac97_save_state);
+
+int ac97_restore_state(struct ac97_codec *codec)
+{
+	int i;
+	unsigned int left, right, val;
+
+	for (i = 0; i < SOUND_MIXER_NRDEVICES; i++) {
+		if (!supported_mixer(codec, i)) 
+			continue;
+
+		val = codec->mixer_state[i];
+		right = val >> 8;
+		left = val  & 0xff;
+		codec->write_mixer(codec, i, left, right);
+	}
+	return 0;
+}
+
+EXPORT_SYMBOL(ac97_restore_state);
+
 MODULE_LICENSE("GPL");

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)