summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJens Axboe <axboe@fb.com>2014-12-19 15:03:15 -0700
committerJens Axboe <axboe@fb.com>2014-12-19 15:03:15 -0700
commit2a2f27b866dea76316f36baa0e318e6f06b99738 (patch)
treede037059f9d88e0eb8c406a3be0cd49299af8e49
parent2107ffe89bc5525ca8f8dc6d7492f10702db1681 (diff)
downloadfio-2a2f27b866dea76316f36baa0e318e6f06b99738.tar.gz
fio-2a2f27b866dea76316f36baa0e318e6f06b99738.tar.bz2
gettime: only use CPU affinity if available
Signed-off-by: Jens Axboe <axboe@fb.com>
-rw-r--r--gettime-thread.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/gettime-thread.c b/gettime-thread.c
index 73632d0b..65ca8341 100644
--- a/gettime-thread.c
+++ b/gettime-thread.c
@@ -95,5 +95,7 @@ err:
void fio_gtod_set_cpu(unsigned int cpu)
{
+#ifdef FIO_HAVE_CPU_AFFINITY
fio_cpu_set(&fio_gtod_cpumask, cpu);
+#endif
}