aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorBastiaan Jacques <b.jacques@planet.nl>2006-04-18 11:04:04 -0400
committerJaroslav Kysela <perex@suse.cz>2006-04-27 15:10:21 -0400
commit8263c65fbee1347b2ab1d8c9380946808d09f579 (patch)
tree4b503b7ea92011bd6f3df65967268ef98c78a9f3 /sound
parent5732e7a2cece461252bfcf2653bb09ab88ba36c5 (diff)
[ALSA] via82xx: add support for VIA VT8251 (AC'97)
Add support for VIA VT8251 AC'97. Includes a workaround which ensures sound won't stop playing after one second of playback. Signed-off-by: Bastiaan Jacques <b.jacques@planet.nl> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/pci/via82xx.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/sound/pci/via82xx.c b/sound/pci/via82xx.c
index 0f171dd1377b..1b740dd4825b 100644
--- a/sound/pci/via82xx.c
+++ b/sound/pci/via82xx.c
@@ -123,6 +123,7 @@ module_param(enable, bool, 0444);
123#define VIA_REV_8233A 0x40 /* 1 rec, 1 multi-pb, spdf */ 123#define VIA_REV_8233A 0x40 /* 1 rec, 1 multi-pb, spdf */
124#define VIA_REV_8235 0x50 /* 2 rec, 4 pb, 1 multi-pb, spdif */ 124#define VIA_REV_8235 0x50 /* 2 rec, 4 pb, 1 multi-pb, spdif */
125#define VIA_REV_8237 0x60 125#define VIA_REV_8237 0x60
126#define VIA_REV_8251 0x70
126 127
127/* 128/*
128 * Direct registers 129 * Direct registers
@@ -863,8 +864,15 @@ static snd_pcm_uframes_t snd_via8233_pcm_pointer(struct snd_pcm_substream *subst
863 status = inb(VIADEV_REG(viadev, OFFSET_STATUS)); 864 status = inb(VIADEV_REG(viadev, OFFSET_STATUS));
864 865
865 if (!(status & VIA_REG_STAT_ACTIVE)) { 866 if (!(status & VIA_REG_STAT_ACTIVE)) {
866 res = 0; 867 /* An apparent bug in the 8251 is worked around by sending
867 goto unlock; 868 * a REG_CTRL_START. */
869 if (chip->revision == VIA_REV_8251)
870 snd_via82xx_pcm_trigger(substream,
871 SNDRV_PCM_TRIGGER_START);
872 else {
873 res = 0;
874 goto unlock;
875 }
868 } 876 }
869 if (count & 0xffffff) { 877 if (count & 0xffffff) {
870 idx = count >> 24; 878 idx = count >> 24;
@@ -2313,6 +2321,7 @@ static struct via823x_info via823x_cards[] __devinitdata = {
2313 { VIA_REV_8233A, "VIA 8233A", TYPE_VIA8233A }, 2321 { VIA_REV_8233A, "VIA 8233A", TYPE_VIA8233A },
2314 { VIA_REV_8235, "VIA 8235", TYPE_VIA8233 }, 2322 { VIA_REV_8235, "VIA 8235", TYPE_VIA8233 },
2315 { VIA_REV_8237, "VIA 8237", TYPE_VIA8233 }, 2323 { VIA_REV_8237, "VIA 8237", TYPE_VIA8233 },
2324 { VIA_REV_8251, "VIA 8251", TYPE_VIA8233 },
2316}; 2325};
2317 2326
2318/* 2327/*
@@ -2342,6 +2351,7 @@ static int __devinit check_dxs_list(struct pci_dev *pci)
2342 { .subvendor = 0x1043, .subdevice = 0x810d, .action = VIA_DXS_SRC }, /* ASUS */ 2351 { .subvendor = 0x1043, .subdevice = 0x810d, .action = VIA_DXS_SRC }, /* ASUS */
2343 { .subvendor = 0x1043, .subdevice = 0x812a, .action = VIA_DXS_SRC }, /* ASUS A8V Deluxe */ 2352 { .subvendor = 0x1043, .subdevice = 0x812a, .action = VIA_DXS_SRC }, /* ASUS A8V Deluxe */
2344 { .subvendor = 0x1043, .subdevice = 0x8174, .action = VIA_DXS_SRC }, /* ASUS */ 2353 { .subvendor = 0x1043, .subdevice = 0x8174, .action = VIA_DXS_SRC }, /* ASUS */
2354 { .subvendor = 0x1043, .subdevice = 0x81b9, .action = VIA_DXS_SRC }, /* ASUS A8V-MX */
2345 { .subvendor = 0x1071, .subdevice = 0x8375, .action = VIA_DXS_NO_VRA }, /* Vobis/Yakumo/Mitac notebook */ 2355 { .subvendor = 0x1071, .subdevice = 0x8375, .action = VIA_DXS_NO_VRA }, /* Vobis/Yakumo/Mitac notebook */
2346 { .subvendor = 0x1071, .subdevice = 0x8399, .action = VIA_DXS_NO_VRA }, /* Umax AB 595T (VIA K8N800A - VT8237) */ 2356 { .subvendor = 0x1071, .subdevice = 0x8399, .action = VIA_DXS_NO_VRA }, /* Umax AB 595T (VIA K8N800A - VT8237) */
2347 { .subvendor = 0x10cf, .subdevice = 0x118e, .action = VIA_DXS_ENABLE }, /* FSC laptop */ 2357 { .subvendor = 0x10cf, .subdevice = 0x118e, .action = VIA_DXS_ENABLE }, /* FSC laptop */