aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2007-11-16 09:20:28 -0500
committerJaroslav Kysela <perex@perex.cz>2008-01-31 11:29:26 -0500
commit9b1fffddc80949fb4aa93fdcc57544bc2108ced3 (patch)
tree2d4020236c2297bb973a65181dcf9e02e7fb5612
parent27da183402ac5ca7d5a4c4704c4a405cd1009c43 (diff)
[ALSA] snd hda suspend latency: shorten codec read
not sleeping for every codec read/write but doing a short udelay and a conditional reschedule has cut suspend+resume latency by about 1 second on my T60. Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Takashi Iwai <tiwai@suse.de> Signed-off-by: Jaroslav Kysela <perex@perex.cz>
-rw-r--r--sound/pci/hda/hda_intel.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sound/pci/hda/hda_intel.c b/sound/pci/hda/hda_intel.c
index 38c591649147..41edf85db38b 100644
--- a/sound/pci/hda/hda_intel.c
+++ b/sound/pci/hda/hda_intel.c
@@ -561,7 +561,8 @@ static unsigned int azx_rirb_get_response(struct hda_codec *codec)
561 } 561 }
562 if (!chip->rirb.cmds) 562 if (!chip->rirb.cmds)
563 return chip->rirb.res; /* the last value */ 563 return chip->rirb.res; /* the last value */
564 schedule_timeout_uninterruptible(1); 564 udelay(10);
565 cond_resched();
565 } while (time_after_eq(timeout, jiffies)); 566 } while (time_after_eq(timeout, jiffies));
566 567
567 if (chip->msi) { 568 if (chip->msi) {