[PATCH] ad1848: replace HZ calculus with msecs_to_jiffies()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Takashi.

If I'm not mistaken, any (new) use of HZ these days is considered a bug so while I'm there...

Signed-off-by: Rene Herman <rene.herman@xxxxxxxxx>

Rene.
diff --git a/sound/isa/ad1848/ad1848_lib.c b/sound/isa/ad1848/ad1848_lib.c
index dcd4435..161da11 100644
--- a/sound/isa/ad1848/ad1848_lib.c
+++ b/sound/isa/ad1848/ad1848_lib.c
@@ -237,7 +237,7 @@ static void snd_ad1848_mce_down(struct snd_ad1848 *chip)
 #if 0
 	printk("(2) jiffies = %li\n", jiffies);
 #endif
-	time = HZ / 4;
+	time = msecs_to_jiffies(250);
 	while (snd_ad1848_in(chip, AD1848_TEST_INIT) & AD1848_CALIB_IN_PROGRESS) {
 		spin_unlock_irqrestore(&chip->reg_lock, flags);
 		if (time <= 0) {
@@ -250,7 +250,7 @@ static void snd_ad1848_mce_down(struct snd_ad1848 *chip)
 #if 0
 	printk("(3) jiffies = %li\n", jiffies);
 #endif
-	time = HZ / 10;
+	time = msecs_to_jiffies(100);
 	while (inb(AD1848P(chip, REGSEL)) & AD1848_INIT) {
 		spin_unlock_irqrestore(&chip->reg_lock, flags);
 		if (time <= 0) {
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux