[x86-64 patch 10/11] random.c precise timers on x86-64

From: Vojtech Pavlik (vojtech@suse.cz)
Date: Thu Sep 13 2001 - 11:43:43 EST


Hi!

This patch adds precise timing support on x86-64 into random.c.

diff -urN linux-x86_64/drivers/char/random.c linux/drivers/char/random.c
--- linux-x86_64/drivers/char/random.c Thu Sep 13 15:17:33 2001
+++ linux/drivers/char/random.c Tue Sep 11 09:49:17 2001
@@ -717,6 +717,10 @@
         } else {
                 time = jiffies;
         }
+#elif defined (__x86_64__)
+ __u32 high;
+ rdtsc(time, high);
+ num ^= high;
 #else
         time = jiffies;
 #endif

-- 
Vojtech Pavlik
SuSE Labs
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Sep 15 2001 - 21:00:41 EST