clock: hardwire tsc as unreliable on Solaris for now
authorJens Axboe <axboe@kernel.dk>
Sat, 2 Feb 2013 09:05:07 +0000 (10:05 +0100)
committerJens Axboe <axboe@kernel.dk>
Sat, 2 Feb 2013 09:05:07 +0000 (10:05 +0100)
Need to double check the cpuid test, it probably only is reliable
on Intel. Need to check the CPU vendor and flags appropriately.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
gettime.c

index cc9dcb7bea7ab28215e09304b3c32688be8d8f25..5c0e44576f2b3392fd0c982b2ee35a95c06cec3a 100644 (file)
--- a/gettime.c
+++ b/gettime.c
@@ -342,6 +342,14 @@ void fio_clock_init(void)
                log_err("fio: can't create TLS key\n");
 #endif
 
+       /*
+        * Probably an AMD issue, will need to investigate. Until that
+        * is done, disable the CPU clock.
+        */
+#if FIO_OS == os_solaris
+       tsc_reliable = 0;
+#endif
+
        fio_clock_source_inited = fio_clock_source;
        calibrate_cpu_clock();