From b0ff22d7b23118b6c7dc56f2256ce6dde634422a Mon Sep 17 00:00:00 2001 From: Jens Axboe Date: Tue, 1 Jan 2013 13:38:18 +0100 Subject: [PATCH] gettime: even rounding, don't always round up Signed-off-by: Jens Axboe --- gettime.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gettime.c b/gettime.c index 05625d1b..3011d744 100644 --- a/gettime.c +++ b/gettime.c @@ -273,7 +273,7 @@ static void calibrate_cpu_clock(void) dprint(FD_TIME, "cycles[%d]=%lu\n", i, cycles[i] / 10); avg /= samples; - avg = (avg + 9) / 10; + avg = (avg + 5) / 10; dprint(FD_TIME, "avg: %lu\n", avg); dprint(FD_TIME, "mean=%f, S=%f\n", mean, S); -- 2.25.1