aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorBastiaan Jacques <b.jacques@planet.nl>2006-04-20 06:27:09 -0400
committerJaroslav Kysela <perex@suse.cz>2006-04-27 15:10:25 -0400
commitc6cc0e3b0c087d350bdc5912ecdfb17e796ae266 (patch)
treeba179f88b9b9d3818439727e5895b9e32715a2c1 /sound
parent1a183131fe284e68194e66cc4ff49d5876501eb0 (diff)
[ALSA] via82xx: tweak VT8251 workaround
Move the workaround for the VT8251 up a bit, and check for STAT_EOL rather than STAT_ACTIVE. This resolves issues some people were having with certain ALSA clients (and allows the STAT_ACTIVE check to do what it was intended to do). This change was suggested by Andrew Daviel. 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.c16
1 files changed, 7 insertions, 9 deletions
diff --git a/sound/pci/via82xx.c b/sound/pci/via82xx.c
index 1b740dd4825b..f7a22aa65a5e 100644
--- a/sound/pci/via82xx.c
+++ b/sound/pci/via82xx.c
@@ -863,16 +863,14 @@ static snd_pcm_uframes_t snd_via8233_pcm_pointer(struct snd_pcm_substream *subst
863 if (!status) 863 if (!status)
864 status = inb(VIADEV_REG(viadev, OFFSET_STATUS)); 864 status = inb(VIADEV_REG(viadev, OFFSET_STATUS));
865 865
866 /* An apparent bug in the 8251 is worked around by sending a
867 * REG_CTRL_START. */
868 if (chip->revision == VIA_REV_8251 && (status & VIA_REG_STAT_EOL))
869 snd_via82xx_pcm_trigger(substream, SNDRV_PCM_TRIGGER_START);
870
866 if (!(status & VIA_REG_STAT_ACTIVE)) { 871 if (!(status & VIA_REG_STAT_ACTIVE)) {
867 /* An apparent bug in the 8251 is worked around by sending 872 res = 0;
868 * a REG_CTRL_START. */ 873 goto unlock;
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 }
876 } 874 }
877 if (count & 0xffffff) { 875 if (count & 0xffffff) {
878 idx = count >> 24; 876 idx = count >> 24;