aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/oxygen/oxygen.c
diff options
context:
space:
mode:
authorClemens Ladisch <clemens@ladisch.de>2010-11-03 07:26:35 -0400
committerTakashi Iwai <tiwai@suse.de>2010-11-03 09:57:32 -0400
commit2146dcfd15ad55cfdd18b45e1e6601d6a86f0cbe (patch)
tree0afc42a4f22a14034654d0906ef83c3cf97e4b2e /sound/pci/oxygen/oxygen.c
parent18f24839f18f1934c1e37e86ce8f3fecbb0328c9 (diff)
ALSA: oxygen: add HiFier Serenade support
Add support for the TempoTec/MediaTek HiFier Serenade sound card. The PCI ID was already there, but the driver handled it like the Fantasia model, which resulted in a dummy recording device. As a stereo output-only card, this model is to be handled exactly like the HG2PCI. Signed-off-by: Clemens Ladisch <clemens@ladisch.de> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/pci/oxygen/oxygen.c')
-rw-r--r--sound/pci/oxygen/oxygen.c27
1 files changed, 14 insertions, 13 deletions
diff --git a/sound/pci/oxygen/oxygen.c b/sound/pci/oxygen/oxygen.c
index 13f39e58f3de..ea8fffefad9f 100644
--- a/sound/pci/oxygen/oxygen.c
+++ b/sound/pci/oxygen/oxygen.c
@@ -70,8 +70,8 @@ enum {
70 MODEL_MERIDIAN, 70 MODEL_MERIDIAN,
71 MODEL_CLARO, 71 MODEL_CLARO,
72 MODEL_CLARO_HALO, 72 MODEL_CLARO_HALO,
73 MODEL_HIFIER, 73 MODEL_FANTASIA,
74 MODEL_HG2PCI, 74 MODEL_2CH_OUTPUT,
75}; 75};
76 76
77static DEFINE_PCI_DEVICE_TABLE(oxygen_ids) = { 77static DEFINE_PCI_DEVICE_TABLE(oxygen_ids) = {
@@ -85,10 +85,11 @@ static DEFINE_PCI_DEVICE_TABLE(oxygen_ids) = {
85 { OXYGEN_PCI_SUBID(0x147a, 0xa017), .driver_data = MODEL_CMEDIA_REF }, 85 { OXYGEN_PCI_SUBID(0x147a, 0xa017), .driver_data = MODEL_CMEDIA_REF },
86 { OXYGEN_PCI_SUBID(0x1a58, 0x0910), .driver_data = MODEL_CMEDIA_REF }, 86 { OXYGEN_PCI_SUBID(0x1a58, 0x0910), .driver_data = MODEL_CMEDIA_REF },
87 /* Kuroutoshikou CMI8787-HG2PCI */ 87 /* Kuroutoshikou CMI8787-HG2PCI */
88 { OXYGEN_PCI_SUBID(0x13f6, 0xffff), .driver_data = MODEL_HG2PCI }, 88 { OXYGEN_PCI_SUBID(0x13f6, 0xffff), .driver_data = MODEL_2CH_OUTPUT },
89 /* TempoTec HiFier Fantasia */ 89 /* TempoTec HiFier Fantasia */
90 { OXYGEN_PCI_SUBID(0x14c3, 0x1710), .driver_data = MODEL_HIFIER }, 90 { OXYGEN_PCI_SUBID(0x14c3, 0x1710), .driver_data = MODEL_FANTASIA },
91 { OXYGEN_PCI_SUBID(0x14c3, 0x1711), .driver_data = MODEL_HIFIER }, 91 /* TempoTec HiFier Serenade */
92 { OXYGEN_PCI_SUBID(0x14c3, 0x1711), .driver_data = MODEL_2CH_OUTPUT },
92 /* AuzenTech X-Meridian */ 93 /* AuzenTech X-Meridian */
93 { OXYGEN_PCI_SUBID(0x415a, 0x5431), .driver_data = MODEL_MERIDIAN }, 94 { OXYGEN_PCI_SUBID(0x415a, 0x5431), .driver_data = MODEL_MERIDIAN },
94 /* HT-Omega Claro */ 95 /* HT-Omega Claro */
@@ -244,13 +245,13 @@ static void claro_halo_init(struct oxygen *chip)
244 claro_enable_hp(chip); 245 claro_enable_hp(chip);
245} 246}
246 247
247static void hifier_init(struct oxygen *chip) 248static void fantasia_init(struct oxygen *chip)
248{ 249{
249 ak4396_init(chip); 250 ak4396_init(chip);
250 snd_component_add(chip->card, "CS5340"); 251 snd_component_add(chip->card, "CS5340");
251} 252}
252 253
253static void hg2pci_init(struct oxygen *chip) 254static void stereo_output_init(struct oxygen *chip)
254{ 255{
255 ak4396_init(chip); 256 ak4396_init(chip);
256} 257}
@@ -583,20 +584,20 @@ static int __devinit get_oxygen_model(struct oxygen *chip,
583 CAPTURE_0_FROM_I2S_2 | 584 CAPTURE_0_FROM_I2S_2 |
584 CAPTURE_1_FROM_SPDIF; 585 CAPTURE_1_FROM_SPDIF;
585 break; 586 break;
586 case MODEL_HIFIER: 587 case MODEL_FANTASIA:
587 case MODEL_HG2PCI: 588 case MODEL_2CH_OUTPUT:
588 chip->model.shortname = "C-Media CMI8787"; 589 chip->model.shortname = "C-Media CMI8787";
589 chip->model.chip = "CMI8787"; 590 chip->model.chip = "CMI8787";
590 if (id->driver_data == MODEL_HIFIER) 591 if (id->driver_data == MODEL_FANTASIA)
591 chip->model.init = hifier_init; 592 chip->model.init = fantasia_init;
592 else 593 else
593 chip->model.init = hg2pci_init; 594 chip->model.init = stereo_output_init;
594 chip->model.resume = stereo_resume; 595 chip->model.resume = stereo_resume;
595 chip->model.mixer_init = generic_mixer_init; 596 chip->model.mixer_init = generic_mixer_init;
596 chip->model.set_adc_params = set_no_params; 597 chip->model.set_adc_params = set_no_params;
597 chip->model.device_config = PLAYBACK_0_TO_I2S | 598 chip->model.device_config = PLAYBACK_0_TO_I2S |
598 PLAYBACK_1_TO_SPDIF; 599 PLAYBACK_1_TO_SPDIF;
599 if (id->driver_data == MODEL_HIFIER) 600 if (id->driver_data == MODEL_FANTASIA)
600 chip->model.device_config |= CAPTURE_0_FROM_I2S_1; 601 chip->model.device_config |= CAPTURE_0_FROM_I2S_1;
601 chip->model.dac_channels = 2; 602 chip->model.dac_channels = 2;
602 break; 603 break;