[PATCH 2/7] perf tools: Add util function for overriding user set config values

Arnaldo Carvalho de Melo acme at kernel.org
Mon Apr 24 10:45:47 PDT 2023


Em Mon, Apr 24, 2023 at 06:36:14PM +0300, Adrian Hunter escreveu:
> On 24/04/23 16:47, James Clark wrote:
> > There is some duplicated code to only override config values if they
> > haven't already been set by the user so make a util function for this.
> > 
> > Signed-off-by: James Clark <james.clark at arm.com>
> 
> One minor comment, nevertheless:
> 
> Acked-by: Adrian Hunter <adrian.hunter at intel.com>

I just moved to  evsel__set_config_if_unset() to util/pmu.c, next to
some other evsel__ functions to not break the python.so binding, before
I was getting:

[acme at quaco perf-tools-next]$ perf test -v python
Couldn't bump rlimit(MEMLOCK), failures may take place when creating BPF maps, etc
 19: 'import perf' in python                                         :
--- start ---
test child forked, pid 500086
python usage test: "echo "import sys ; sys.path.append('/tmp/build/perf-tools-next/python'); import perf" | '/usr/bin/python3' "
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: /tmp/build/perf-tools-next/python/perf.cpython-311-x86_64-linux-gnu.so: undefined symbol: perf_pmu__format_bits
test child finished with -1
---- end ----
'import perf' in python: FAILED!
[acme at quaco perf-tools-next]$

Please run 'perf test' and 'make -C tools/perf build-test' prior to
sending pull requests,

Thanks, applied.

- Arnaldo




More information about the linux-arm-kernel mailing list