The fields are not uint64 just longs, update the printf format specifiers. Signed-off-by: Daniel Wagner <dwagner@xxxxxxx> --- src/cyclictest/cyclictest.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/cyclictest/cyclictest.c b/src/cyclictest/cyclictest.c index 157047837259..c43dd7cbbd64 100644 --- a/src/cyclictest/cyclictest.c +++ b/src/cyclictest/cyclictest.c @@ -11,7 +11,6 @@ #include <stdio.h> #include <stdlib.h> #include <stdint.h> -#include <inttypes.h> #include <stdarg.h> #include <unistd.h> #include <fcntl.h> @@ -1751,15 +1750,15 @@ static void write_stats(FILE *f, void *data) if (s->hist_array[j] == 0) continue; fprintf(f, "%s", comma ? ",\n" : "\n"); - fprintf(f, " \"%u\": %" PRIu64, j, s->hist_array[j]); + fprintf(f, " \"%u\": %ld", j, s->hist_array[j]); comma = 1; } if (comma) fprintf(f, "\n"); fprintf(f, " },\n"); - fprintf(f, " \"cycles\": %" PRIu64 ",\n", s->cycles); - fprintf(f, " \"min\": %" PRIu64 ",\n", s->min); - fprintf(f, " \"max\": %" PRIu64 ",\n", s->max); + fprintf(f, " \"cycles\": %ld,\n", s->cycles); + fprintf(f, " \"min\": %ld,\n", s->min); + fprintf(f, " \"max\": %ld,\n", s->max); fprintf(f, " \"avg\": %.2f,\n", s->avg/s->cycles); fprintf(f, " \"cpu\": %d,\n", par[i]->cpu); fprintf(f, " \"node\": %d\n", par[i]->node); -- 2.30.1