aboutsummaryrefslogtreecommitdiffstats
path: root/sound/pci/trident/trident_main.c
diff options
context:
space:
mode:
authorNishanth Aravamudan <nacc@us.ibm.com>2005-07-09 04:13:22 -0400
committerJaroslav Kysela <perex@suse.cz>2005-07-28 06:22:13 -0400
commitef21ca24faf28df6d06939e77d5032a313490289 (patch)
tree1c6c719f4671b803f1288eb8cdca18587ec2eb62 /sound/pci/trident/trident_main.c
parent072c01194df6e4843582d09380b780987f642d6d (diff)
[ALSA] sound/pci: fix-up sleeping paths
ENS1370/1+ driver,ES1968 driver,Intel8x0 driver,VIA82xx driver VIA82xx-modem driver,AC97 Codec,ALI5451 driver,CS46xx driver MIXART driver,RME HDSP driver,Trident driver,YMFPCI driver Description: Fix-up sleeping in sound/pci. These changes fall under the following two categories: 1) Replace schedule_timeout() with msleep() to guarantee the task delays as expected. This also involved replacing/removing custom sleep functions. 2) Do not assume jiffies will only increment by one if you request a 1 jiffy sleep, i.e. use time_after/time_before in while loops. Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/trident/trident_main.c')
-rw-r--r--sound/pci/trident/trident_main.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sound/pci/trident/trident_main.c b/sound/pci/trident/trident_main.c
index b01c91bb5f6a..29d89bfba0a4 100644
--- a/sound/pci/trident/trident_main.c
+++ b/sound/pci/trident/trident_main.c
@@ -3153,8 +3153,7 @@ static int snd_trident_gameport_open(struct gameport *gameport, int mode)
3153 switch (mode) { 3153 switch (mode) {
3154 case GAMEPORT_MODE_COOKED: 3154 case GAMEPORT_MODE_COOKED:
3155 outb(GAMEPORT_MODE_ADC, TRID_REG(chip, GAMEPORT_GCR)); 3155 outb(GAMEPORT_MODE_ADC, TRID_REG(chip, GAMEPORT_GCR));
3156 set_current_state(TASK_UNINTERRUPTIBLE); 3156 msleep(20);
3157 schedule_timeout(1 + 20 * HZ / 1000); /* 20msec */
3158 return 0; 3157 return 0;
3159 case GAMEPORT_MODE_RAW: 3158 case GAMEPORT_MODE_RAW:
3160 outb(0, TRID_REG(chip, GAMEPORT_GCR)); 3159 outb(0, TRID_REG(chip, GAMEPORT_GCR));