[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOJsxLHYZyGkORudmXd5+f3_NBXTh7rmDC-Cw3=06vyVk7WZaA@mail.gmail.com>
Date: Fri, 21 Sep 2012 10:47:24 +0300
From: Pekka Enberg <penberg@...nel.org>
To: Irina Tirdea <irina.tirdea@...il.com>
Cc: Arnaldo Carvalho de Melo <acme@...stprotocols.net>,
Ingo Molnar <mingo@...nel.org>,
Steven Rostedt <rostedt@...dmis.org>,
Peter Zijlstra <a.p.zijlstra@...llo.nl>,
LKML <linux-kernel@...r.kernel.org>,
Paul Mackerras <paulus@...ba.org>,
David Ahern <dsahern@...il.com>,
Namhyung Kim <namhyung@...nel.org>,
Jiri Olsa <jolsa@...hat.com>,
Irina Tirdea <irina.tirdea@...el.com>
Subject: Re: [PATCH 1/4] perf tools: configure tmp path at build time
Hi Irina,
On Fri, Sep 21, 2012 at 1:13 AM, Irina Tirdea <irina.tirdea@...il.com> wrote:
> diff --git a/tools/perf/util/map.c b/tools/perf/util/map.c
> index b442ee4..c5b4632 100644
> --- a/tools/perf/util/map.c
> +++ b/tools/perf/util/map.c
> @@ -59,7 +59,8 @@ struct map *map__new(struct list_head *dsos__list, u64 start, u64 len,
> no_dso = is_no_dso_memory(filename);
>
> if (anon) {
> - snprintf(newfilename, sizeof(newfilename), "/tmp/perf-%d.map", pid);
> + snprintf(newfilename, sizeof(newfilename),
> + PERF_TMP_DIR "/perf-%d.map", pid);
> filename = newfilename;
> }
[snip]
> diff --git a/tools/perf/util/symbol.c b/tools/perf/util/symbol.c
> index e2e8c69..eb671d5 100644
> --- a/tools/perf/util/symbol.c
> +++ b/tools/perf/util/symbol.c
> @@ -1051,7 +1051,7 @@ int dso__load(struct dso *dso, struct map *map, symbol_filter_t filter)
>
> dso->adjust_symbols = 0;
>
> - if (strncmp(dso->name, "/tmp/perf-", 10) == 0) {
> + if (strncmp(dso->name, PERF_TMP_DIR "/perf-", 10) == 0) {
> struct stat st;
>
> if (lstat(dso->name, &st) < 0)
Just to point out: these two path names are actually part of a
JIT/perf integration ABI. I'm OK with using PERF_TMP_DIR here but you
really ought to update tools/perf/Documentation/jit-interface.txt.
--
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