diff options
author | Arnaldo Carvalho de Melo <acme@redhat.com> | 2016-08-08 21:04:23 +0300 |
---|---|---|
committer | Arnaldo Carvalho de Melo <acme@redhat.com> | 2016-08-23 21:37:33 +0300 |
commit | af15e67e8f8572072167bfb193ceabff04f4b21e (patch) | |
tree | 600c4dae2f79f0e2959fcc2d476ad605bb227029 | |
parent | f2b91be731a6c1aff9333c1ce3fece7a311f1e0d (diff) | |
download | linux-af15e67e8f8572072167bfb193ceabff04f4b21e.tar.xz |
perf bench sched-messaging: Use USEC_PER_MSEC
Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: David Ahern <dsahern@gmail.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Steven Rostedt <rostedt@goodmis.org>
Cc: Wang Nan <wangnan0@huawei.com>
Link: http://lkml.kernel.org/n/tip-xhyoyxejvorrgmwjx9k3j8k2@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
-rw-r--r-- | tools/perf/bench/sched-messaging.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/perf/bench/sched-messaging.c b/tools/perf/bench/sched-messaging.c index bfaf9503de8e..6a111e775210 100644 --- a/tools/perf/bench/sched-messaging.c +++ b/tools/perf/bench/sched-messaging.c @@ -29,6 +29,7 @@ #include <poll.h> #include <limits.h> #include <err.h> +#include <linux/time64.h> #define DATASIZE 100 @@ -312,11 +313,11 @@ int bench_sched_messaging(int argc, const char **argv, thread_mode ? "threads" : "processes"); printf(" %14s: %lu.%03lu [sec]\n", "Total time", diff.tv_sec, - (unsigned long) (diff.tv_usec/1000)); + (unsigned long) (diff.tv_usec / USEC_PER_MSEC)); break; case BENCH_FORMAT_SIMPLE: printf("%lu.%03lu\n", diff.tv_sec, - (unsigned long) (diff.tv_usec/1000)); + (unsigned long) (diff.tv_usec / USEC_PER_MSEC)); break; default: /* reaching here is something disaster */ |