perf config: Honour $PERF_CONFIG env var to specify alternate .perfconfig
authorArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 30 Jul 2019 14:20:55 +0000 (11:20 -0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 5 Oct 2019 11:09:40 +0000 (13:09 +0200)
commit96b61fe7a5f755d7f268f2ab2eee3d017d115e5b
treea3d13ff517f0a497fb007820aa2919d742f9624d
parentdb751f6d5241fce65d3b73b22488230fa86ad72b
perf config: Honour $PERF_CONFIG env var to specify alternate .perfconfig

[ Upstream commit 61a461fcbd62d42c29a1ea6a9cc3838ad9f49401 ]

We had this comment in Documentation/perf_counter/config.c, i.e. since
when we got this from the git sources, but never really did that
getenv("PERF_CONFIG"), do it now as I need to disable whatever
~/.perfconfig root has so that tests parsing tool output are done for
the expected default output or that we specify an alternate config file
that when read will make the tools produce expected output.

Cc: Adrian Hunter <adrian.hunter@intel.com>
Cc: Jiri Olsa <jolsa@kernel.org>
Cc: Luis Cláudio Gonçalves <lclaudio@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: Taeung Song <treeze.taeung@gmail.com>
Fixes: 078006012401 ("perf_counter tools: add in basic glue from Git")
Link: https://lkml.kernel.org/n/tip-jo209zac9rut0dz1rqvbdlgm@git.kernel.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
tools/perf/perf.c