[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20120827153355.GA17634@infradead.org>
Date: Mon, 27 Aug 2012 12:33:55 -0300
From: Arnaldo Carvalho de Melo <acme@...hat.com>
To: Feng Tang <feng.tang@...el.com>
Cc: mingo@...e.hu, a.p.zijlstra@...llo.nl, namhyung@...nel.org,
dsahern@...il.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 1/3] perf tools: Fix a compiling error in
trace-event-perl.c for 32 bits machine
Em Mon, Aug 27, 2012 at 03:38:25PM +0800, Feng Tang escreveu:
> On my x86_32 mahcine, there is a compile error:
>
> CC util/scripting-engines/trace-event-perl.o
> cc1: warnings being treated as errors
> util/scripting-engines/trace-event-perl.c: In function ‘perl_process_tracepoint’:
> util/scripting-engines/trace-event-perl.c:285: error: format ‘%d’ expects type ‘int’, but argument 2 has type ‘__u64’
> make: *** [util/scripting-engines/trace-event-perl.o] Error 1
>
> Fix it by using the "%lld" for __u64.
>
> Signed-off-by: Feng Tang <feng.tang@...el.com>
> ---
> .../perf/util/scripting-engines/trace-event-perl.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/tools/perf/util/scripting-engines/trace-event-perl.c b/tools/perf/util/scripting-engines/trace-event-perl.c
> index d280010..1cde6aa 100644
> --- a/tools/perf/util/scripting-engines/trace-event-perl.c
> +++ b/tools/perf/util/scripting-engines/trace-event-perl.c
> @@ -282,7 +282,7 @@ static void perl_process_tracepoint(union perf_event *perf_event __unused,
>
> event = find_cache_event(evsel);
> if (!event)
> - die("ug! no event found for type %d", evsel->attr.config);
> + die("ug! no event found for type %lld", evsel->attr.config);
Please use PRIu64 instead, like in:
grep PRIu64 tools/perf/*/*.c
> pid = raw_field_value(event, "common_pid", data);
>
> --
> 1.7.1
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists