Centos-kernel-stream-9/tools/perf/util
Yauheni Kaliuta bf8c9262cb perf tools: Move libbpf init in libbpf_init function
Bugzilla: https://bugzilla.redhat.com/2120968

commit 3a7ab605978d9dd48ad2c7db8df7ad388884f887
Author: Jiri Olsa <jolsa@kernel.org>
Date:   Fri Apr 22 12:00:23 2022 +0200

    perf tools: Move libbpf init in libbpf_init function
    
    Move the libbpf init code into a single function, so that we have a single
    place doing that.
    
    Signed-off-by: Jiri Olsa <jolsa@kernel.org>
    Cc: Alexander Shishkin <alexander.shishkin@linux.intel.com>
    Cc: Alexei Starovoitov <ast@kernel.org>
    Cc: Andrii Nakryiko <andrii@kernel.org>
    Cc: Daniel Borkmann <daniel@iogearbox.net>
    Cc: Ian Rogers <irogers@google.com>
    Cc: Ingo Molnar <mingo@kernel.org>
    Cc: John Fastabend <john.fastabend@gmail.com>
    Cc: Martin KaFai Lau <kafai@fb.com>
    Cc: Namhyung Kim <namhyung@kernel.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Song Liu <songliubraving@fb.com>
    Cc: Yonghong Song <yhs@fb.com>
    Cc: bpf@vger.kernel.org
    Cc: netdev@vger.kernel.org
    Link: https://lore.kernel.org/r/20220422100025.1469207-4-jolsa@kernel.org
    Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>

Signed-off-by: Yauheni Kaliuta <ykaliuta@redhat.com>
2022-11-28 16:52:11 +02:00
..
arm-spe-decoder perf arm-spe: Use SPE data source for neoverse cores 2022-11-14 20:25:59 +01:00
bpf_skel perf lock contention: Fix a build error on 32-bit 2022-11-14 20:26:07 +01:00
c++ perf clang: Fix header include for LLVM >= 14 2022-09-21 07:22:57 +02:00
cs-etm-decoder perf cs-etm: Print the decoder name 2022-04-25 12:33:10 +02:00
include linkage: remove SYM_FUNC_{START,END}_ALIAS() 2022-09-21 07:22:40 +02:00
intel-pt-decoder perf intel-pt: Add support for emulated ptwrite 2022-09-21 07:23:04 +02:00
libunwind perf unwind arm64: Use perf's copy of kernel headers 2022-09-21 07:23:11 +02:00
scripting-engines perf build: Fixup disabling of -Wdeprecated-declarations for the python scripting engine 2022-11-14 20:26:07 +01:00
Build perf parse-events: Ignore clang 15 warning about variable set but unused in bison produced code 2022-11-14 20:26:07 +01:00
PERF-VERSION-GEN perf tools: Fix version kernel tag 2022-09-21 07:22:54 +02:00
affinity.c perf affinity: Fix out of bound access to "sched_cpus" mask 2022-11-14 20:26:05 +01:00
affinity.h
amd-sample-raw.c perf script ibs: Support new IBS bits in raw trace dump 2022-11-14 20:25:43 +01:00
annotate.c perf annotate: Drop objdump stderr to avoid getting stuck waiting for stdout output 2022-09-21 07:22:57 +02:00
annotate.h perf symbols: Factor out annotation init/exit 2022-05-16 11:35:27 +02:00
archinsn.h
arm-spe.c perf arm-spe: augment the data source type with neoverse_spe list 2022-11-14 20:26:07 +01:00
arm-spe.h
arm64-frame-pointer-unwind-support.c perf unwind: Don't show unwind error messages when augmenting frame pointer stack 2022-05-16 11:36:17 +02:00
arm64-frame-pointer-unwind-support.h perf arm64: Inject missing frames when using 'perf record --call-graph=fp' 2022-05-16 11:35:48 +02:00
auxtrace.c perf auxtrace: Add machine_pid and vcpu to auxtrace_error 2022-11-14 20:25:46 +01:00
auxtrace.h perf auxtrace: Add machine_pid and vcpu to auxtrace_error 2022-11-14 20:25:46 +01:00
block-info.c
block-info.h
block-range.c
block-range.h
bpf-event.c Merge: BPF and XDP rebase to v5.18 2022-11-21 05:30:47 -05:00
bpf-event.h perf bpf: Pull in bpf_program__get_prog_info_linear() 2022-05-16 11:35:09 +02:00
bpf-loader.c perf tools: Move libbpf init in libbpf_init function 2022-11-28 16:52:11 +02:00
bpf-loader.h
bpf-prologue.c
bpf-prologue.h
bpf-utils.c perf bpf: 8 byte align bpil data 2022-09-21 07:23:14 +02:00
bpf-utils.h perf bpf: Pull in bpf_program__get_prog_info_linear() 2022-05-16 11:35:09 +02:00
bpf_counter.c Merge: perf: Sync with upstream v5.19 2022-11-07 01:58:21 -05:00
bpf_counter.h perf bpf: Rename 'cpu' to 'cpu_map_idx' 2022-05-16 11:36:00 +02:00
bpf_counter_cgroup.c perf stat: Use evsel->core.cpus to iterate cpus in BPF cgroup counters 2022-11-14 20:26:06 +01:00
bpf_ftrace.c perf evlist: Rename cpus to user_requested_cpus 2022-09-21 07:22:55 +02:00
bpf_kwork.c perf kwork: Add workqueue trace BPF support 2022-11-14 20:25:50 +01:00
bpf_lock_contention.c perf lock: Print the number of lost entries for BPF 2022-11-14 20:25:56 +01:00
bpf_map.c perf: Stop using bpf_map__def() API 2022-10-25 14:58:11 +02:00
bpf_map.h
bpf_off_cpu.c perf offcpu: Track child processes 2022-11-14 20:25:58 +01:00
branch.c perf: Add irq and exception return branch types 2022-09-21 07:22:41 +02:00
branch.h
build-id.c perf build-id: Print debuginfod queries if -v option is used 2022-11-14 20:26:00 +01:00
build-id.h perf buildid-cache: Add guestmount'd files to the build ID cache 2022-11-14 20:25:45 +01:00
cache.h
cacheline.c
cacheline.h
call-path.c
call-path.h
callchain.c perf record: Allow to specify max stack depth of fp callchain 2022-11-14 20:25:44 +01:00
callchain.h perf callchain: Enable dwarf_callchain_users on arm64 2022-05-16 11:35:48 +02:00
cap.c
cap.h
cgroup.c
cgroup.h
clockid.c
clockid.h
cloexec.c
cloexec.h
color.c
color.h
color_config.c
comm.c
comm.h
compress.h
config.c perf config: Refine error message to eliminate confusion 2022-04-25 12:34:27 +02:00
config.h
copyfile.c
copyfile.h
counts.c perf cpumap: Migrate to libperf cpumap api 2022-05-16 11:36:06 +02:00
counts.h perf counts: Switch name cpu to cpu_map_idx 2022-05-16 11:35:56 +02:00
cpu-set-sched.h
cpumap.c perf cpumap: Fix alignment for masks in event encoding 2022-11-14 20:26:03 +01:00
cpumap.h perf cpumap: Fix alignment for masks in event encoding 2022-11-14 20:26:03 +01:00
cputopo.c perf cpumap: Migrate to libperf cpumap api 2022-05-16 11:36:06 +02:00
cputopo.h perf cputopo: Match thread_siblings to topology ABI name 2022-05-16 11:35:23 +02:00
cs-etm.c perf cs-etm: Fix duplicated 'the' in comment 2022-11-14 20:25:48 +01:00
cs-etm.h perf cs-etm: Save TRCDEVARCH register 2022-04-25 12:33:10 +02:00
data-convert-bt.c tools/perf: Add '__rel_loc' event field parsing support 2022-05-16 11:35:39 +02:00
data-convert-json.c perf data convert: Prefer sampled CPU when exporting JSON 2022-11-14 20:25:41 +01:00
data-convert.h
data.c perf tools: Automatically use guest kcore_dir if present 2022-11-14 20:25:46 +01:00
data.h perf data: Add missing unistd.h header needed for pid_t 2022-11-14 20:25:49 +01:00
db-export.c
db-export.h
debug.c perf script: Fix hex dump character output 2022-05-16 11:35:49 +02:00
debug.h perf tools: Add WARN_ONCE equivalent for UI warnings 2022-04-25 12:33:02 +02:00
demangle-java.c
demangle-java.h
demangle-ocaml.c
demangle-ocaml.h
demangle-rust.c
demangle-rust.h
dlfilter.c perf dlfilter: Add machine_pid and vcpu 2022-11-14 20:25:46 +01:00
dlfilter.h perf tests: Add dlfilter test 2022-04-25 12:33:06 +02:00
dso.c perf tools: Try chroot'ed filename when opening dso/symbol 2022-09-21 07:22:44 +02:00
dso.h perf tools: Export dsos__for_each_with_build_id() 2022-11-14 20:25:45 +01:00
dsos.c perf tools: Fix dso_id inode generation comparison 2022-11-14 20:25:44 +01:00
dsos.h
dump-insn.c
dump-insn.h
dwarf-aux.c
dwarf-aux.h
dwarf-regs.c
env.c perf header: Record non-CPU PMU capabilities 2022-11-14 20:25:42 +01:00
env.h perf header: Record non-CPU PMU capabilities 2022-11-14 20:25:42 +01:00
event.c perf record: Add finished init event 2022-11-14 20:25:42 +01:00
event.h perf tools: Support reading PERF_FORMAT_LOST 2022-11-14 20:26:04 +01:00
events_stats.h perf tools: Fix double word in comments 2022-11-14 20:26:00 +01:00
evlist-hybrid.c perf evlist: Fix failed to use cpu list for uncore events 2022-05-16 11:36:13 +02:00
evlist-hybrid.h perf tools: Enable on a list of CPUs for hybrid 2022-04-25 12:33:06 +02:00
evlist.c perf x86 evlist: Add default hybrid events for perf stat 2022-11-14 20:25:55 +01:00
evlist.h perf x86 evlist: Add default hybrid events for perf stat 2022-11-14 20:25:55 +01:00
evsel.c perf tools: Support reading PERF_FORMAT_LOST 2022-11-14 20:26:04 +01:00
evsel.h perf evsel: Add arch_evsel__hw_name() 2022-11-14 20:25:54 +01:00
evsel_config.h
evsel_fprintf.c perf script: Show binary offsets for userspace addr 2022-05-16 11:35:08 +02:00
evsel_fprintf.h
evswitch.c
evswitch.h
expr.c perf tsc: Add arch TSC frequency information 2022-11-14 20:25:48 +01:00
expr.h perf expr: Add source_count for aggregating events 2022-05-16 11:35:24 +02:00
expr.l perf expr: Allow exponents on floating point values 2022-09-21 07:23:13 +02:00
expr.y perf expr: Add source_count for aggregating events 2022-05-16 11:35:24 +02:00
find-map.c
fncache.c
fncache.h
ftrace.h perf ftrace latency: Add -n/--use-nsec option 2022-09-21 07:22:54 +02:00
genelf.c perf jit: Include program header in ELF files 2022-11-14 20:26:06 +01:00
genelf.h perf inject: Fix GEN_ELF_TEXT_OFFSET for jit 2022-11-14 20:26:07 +01:00
genelf_debug.c
generate-cmdlist.sh
get_current_dir_name.c perf tools: Fixup get_current_dir_name() compilation 2022-04-25 12:33:07 +02:00
get_current_dir_name.h
hashmap.c
hashmap.h
header.c perf header: Record non-CPU PMU capabilities 2022-11-14 20:25:42 +01:00
header.h perf header: Record non-CPU PMU capabilities 2022-11-14 20:25:42 +01:00
help-unknown-cmd.c
help-unknown-cmd.h
hist.c perf report: Add "addr_from" and "addr_to" sort dimensions 2022-09-21 07:22:52 +02:00
hist.h perf report: Add "addr_from" and "addr_to" sort dimensions 2022-09-21 07:22:52 +02:00
intel-bts.c perf tools: Use __BYTE_ORDER__ 2022-05-16 11:35:12 +02:00
intel-bts.h
intel-pt.c perf intel-pt: Use guest pid/tid etc in guest samples 2022-11-14 20:25:47 +01:00
intel-pt.h
intlist.c
intlist.h
iostat.c
iostat.h
jit.h
jitdump.c perf inject jit: Ignore memfd and anonymous mmap events if jitdump present 2022-11-14 20:25:57 +01:00
jitdump.h
kvm-stat.h
kwork.h perf kwork: Implement BPF trace 2022-11-14 20:25:50 +01:00
levenshtein.c
levenshtein.h
llvm-utils.c perf bpf: Convert legacy map definition to BTF-defined 2022-11-14 20:25:55 +01:00
llvm-utils.h
lock-contention.h perf lock contention: Fix a build error on 32-bit 2022-11-14 20:26:07 +01:00
lzma.c
machine.c perf machine: Fix missing free of machine->kallsyms_filename 2022-11-14 20:25:58 +01:00
machine.h perf machine: Use realloc_array_as_needed() in machine__set_current_tid() 2022-11-14 20:25:47 +01:00
map.c perf tools: Set build-id using build-id header on new mmap records 2022-09-21 07:22:53 +02:00
map.h perf map: Make map__contains_symbol() args const 2022-09-21 07:22:47 +02:00
map_symbol.h perf tools: Apply correct label to user/kernel symbols in branch mode 2022-05-16 11:36:10 +02:00
maps.c perf maps: Move maps code to own C file 2022-09-21 07:22:47 +02:00
maps.h perf maps: Reduce scope of init and exit 2022-09-21 07:22:47 +02:00
mem-events.c perf mem: Add statistics for peer snooping 2022-11-14 20:25:59 +01:00
mem-events.h perf mem: Add statistics for peer snooping 2022-11-14 20:25:59 +01:00
mem2node.c
mem2node.h
memswap.c
memswap.h
metricgroup.c perf metric: Return early if no CPU PMU table exists 2022-11-14 20:26:04 +01:00
metricgroup.h perf metrics: Copy entire pmu_event in find metric 2022-11-14 20:26:02 +01:00
mmap.c perf auxtrace: Remove auxtrace_mmap_params__set_idx() per_cpu parameter 2022-09-21 07:23:09 +02:00
mmap.h perf record: Introduce compressor at mmap buffer object 2022-09-21 07:22:46 +02:00
namespaces.c perf namespaces: Add functions to access nsinfo 2022-09-21 07:22:47 +02:00
namespaces.h perf namespaces: Add functions to access nsinfo 2022-09-21 07:22:47 +02:00
off_cpu.h perf offcpu: Accept allowed sample types only 2022-09-21 07:23:14 +02:00
ordered-events.c perf report: Output data file name in raw trace dump 2022-09-21 07:22:46 +02:00
ordered-events.h perf ordered_events: Add ordered_events__last_flush_time() 2022-11-14 20:25:45 +01:00
parse-branch-options.c perf test: Fix skipping branch stack sampling test 2022-11-14 23:55:21 +01:00
parse-branch-options.h
parse-events-hybrid.c perf parse-events: Remove "not supported" hybrid cache events 2022-11-14 20:26:07 +01:00
parse-events-hybrid.h perf parse-events: Add new "metric-id" term 2022-05-16 11:34:59 +02:00
parse-events.c perf parse-events: Remove "not supported" hybrid cache events 2022-11-14 20:26:07 +01:00
parse-events.h perf parse-events: Remove "not supported" hybrid cache events 2022-11-14 20:26:07 +01:00
parse-events.l perf stat: Add user_time and system_time events 2022-09-21 07:23:01 +02:00
parse-events.y perf parse-events: Support event alias in form foo-bar-baz 2022-05-16 11:36:07 +02:00
parse-regs-options.c
parse-regs-options.h
parse-sublevel-options.c
parse-sublevel-options.h perf tools: Add missing newline at the end of header file 2022-04-25 12:33:06 +02:00
path.c perf test: Shell - Limit to only run executable scripts in tests 2022-09-21 07:22:59 +02:00
path.h perf test: Shell - Limit to only run executable scripts in tests 2022-09-21 07:22:59 +02:00
perf-hooks-list.h
perf-hooks.c
perf-hooks.h
perf_api_probe.c perf tools: Do not pass NULL to parse_events() 2022-11-14 20:25:58 +01:00
perf_api_probe.h
perf_event_attr_fprintf.c perf tools: Add missing branch_sample_type to perf_event_attr__fprintf() 2022-05-16 11:36:09 +02:00
perf_regs.c perf tools arm64: Add support for VG register 2022-09-21 07:23:11 +02:00
perf_regs.h perf tools: Refactor SMPL_REG macro in perf_regs.h 2022-05-16 11:35:48 +02:00
pfm.c perf parse-events: Add new "metric-id" term 2022-05-16 11:34:59 +02:00
pfm.h
pmu-hybrid.c
pmu-hybrid.h
pmu.c perf pmu-events: Hide the pmu_events 2022-11-14 20:26:02 +01:00
pmu.h perf pmu-events: Hide the pmu_events 2022-11-14 20:26:02 +01:00
pmu.l
pmu.y
print-events.c perf parse-events: Remove "not supported" hybrid cache events 2022-11-14 20:26:07 +01:00
print-events.h perf parse-events: Break out tracepoint and printing 2022-11-14 20:25:55 +01:00
print_binary.c
print_binary.h
probe-event.c perf probe: Fix an error handling path in 'parse_perf_probe_command()' 2022-11-14 20:25:57 +01:00
probe-event.h
probe-file.c
probe-file.h
probe-finder.c
probe-finder.h
pstack.c
pstack.h
python-ext-sources perf unwind: Use dynamic register set for DWARF unwind 2022-09-21 07:23:11 +02:00
python.c perf python: Add perf_env stubs that will be needed in evsel__open_strerror() 2022-09-21 07:22:55 +02:00
rb_resort.h
rblist.c
rblist.h
record.c perf tools: Do not pass NULL to parse_events() 2022-11-14 20:25:58 +01:00
record.h perf record: Add new option to sample identifier 2022-11-14 20:25:42 +01:00
rlimit.c
rlimit.h
rwsem.c
rwsem.h
s390-cpumcf-kernel.h
s390-cpumsf-kernel.h
s390-cpumsf.c perf tools: Use __BYTE_ORDER__ 2022-05-16 11:35:12 +02:00
s390-cpumsf.h
s390-sample-raw.c perf pmu-events: Hide the pmu_events 2022-11-14 20:26:02 +01:00
sample-raw.c perf report: Add support to print a textual representation of IBS raw sample data 2022-04-25 12:33:11 +02:00
sample-raw.h perf report: Add support to print a textual representation of IBS raw sample data 2022-04-25 12:33:11 +02:00
session.c perf tools: Support reading PERF_FORMAT_LOST 2022-11-14 20:26:04 +01:00
session.h perf tools: Export perf_event__process_finished_round() 2022-11-14 20:25:45 +01:00
setns.c
setup.py perf python: Ignore unused command line arguments when building with clang 2022-11-14 20:25:48 +01:00
sideband_evlist.c perf evlist: Rename cpus to user_requested_cpus 2022-09-21 07:22:55 +02:00
smt.c perf tools: Probe non-deprecated sysfs path 1st 2022-05-16 11:36:02 +02:00
smt.h
sort.c perf report: Add "addr_from" and "addr_to" sort dimensions 2022-09-21 07:22:52 +02:00
sort.h perf report: Add "addr_from" and "addr_to" sort dimensions 2022-09-21 07:22:52 +02:00
spark.c
spark.h
srccode.c
srccode.h
srcline.c perf srcline: Use long-running addr2line per DSO 2022-05-16 11:34:53 +02:00
srcline.h
stat-display.c perf stat: Fix cpu check to use id.cpu.cpu in aggr_printout() 2022-11-14 20:26:08 +01:00
stat-shadow.c perf stat: Capitalize topdown metrics' names 2022-11-14 20:26:04 +01:00
stat.c perf stat: Add JSON output option 2022-11-14 20:25:56 +01:00
stat.h perf stat: Add JSON output option 2022-11-14 20:25:56 +01:00
strbuf.c
strbuf.h
stream.c
stream.h
strfilter.c
strfilter.h
string.c
string2.h
strlist.c
strlist.h
svghelper.c perf cpumap: Migrate to libperf cpumap api 2022-05-16 11:36:06 +02:00
svghelper.h
symbol-elf.c perf kcore_copy: Do not check /proc/modules is unchanged 2022-11-14 20:26:06 +01:00
symbol-minimal.c
symbol.c perf tools: Automatically use guest kcore_dir if present 2022-11-14 20:25:46 +01:00
symbol.h perf symbol: Remove arch__symbols__fixup_end() 2022-09-21 07:22:58 +02:00
symbol_conf.h perf tools: Add guest_code support 2022-09-21 07:23:08 +02:00
symbol_fprintf.c
symsrc.h
synthetic-events.c perf tools: Honor namespace when synthesizing build-ids 2022-11-14 20:26:06 +01:00
synthetic-events.h perf cpumap: Synthetic events and const/static 2022-11-14 20:26:03 +01:00
syscalltbl.c
syscalltbl.h
target.c
target.h perf tools: Create hybrid flag in target 2022-04-25 12:33:06 +02:00
term.c
term.h
thread-stack.c
thread-stack.h
thread.c perf tools: Add guest_cpu to hypervisor threads 2022-11-14 20:25:45 +01:00
thread.h perf tools: Add guest_cpu to hypervisor threads 2022-11-14 20:25:45 +01:00
thread_map.c
thread_map.h
time-utils.c
time-utils.h
tool.h perf record: Add finished init event 2022-11-14 20:25:42 +01:00
top.c perf evlist: Rename cpus to user_requested_cpus 2022-09-21 07:22:55 +02:00
top.h perf tui: Only support --tui with slang 2022-09-21 07:22:51 +02:00
topdown.c perf stat: Add topdown metrics in the default perf stat on the hybrid machine 2022-11-14 20:25:55 +01:00
topdown.h perf stat: Add topdown metrics in the default perf stat on the hybrid machine 2022-11-14 20:25:55 +01:00
trace-event-info.c perf parse-events: Break out tracepoint and printing 2022-11-14 20:25:55 +01:00
trace-event-parse.c perf tools: Use ARRAY_SIZE() instead of ad hoc equivalent, spotted by array_size.cocci 2022-09-21 07:22:53 +02:00
trace-event-read.c
trace-event-scripting.c
trace-event.c
trace-event.h perf script python: Allow reporting the [un]throttle PERF_RECORD_ meta event 2022-04-25 12:33:10 +02:00
tracepoint.c perf parse-events: Break out tracepoint and printing 2022-11-14 20:25:55 +01:00
tracepoint.h perf parse-events: Break out tracepoint and printing 2022-11-14 20:25:55 +01:00
trigger.h
tsc.c
tsc.h perf tsc: Add arch TSC frequency information 2022-11-14 20:25:48 +01:00
units.c
units.h
unwind-libdw.c perf unwind: Don't show unwind error messages when augmenting frame pointer stack 2022-05-16 11:36:17 +02:00
unwind-libdw.h perf unwind: Don't show unwind error messages when augmenting frame pointer stack 2022-05-16 11:36:17 +02:00
unwind-libunwind-local.c perf unwind: Fix unitialized 'offset' variable on aarch64 2022-09-21 07:23:14 +02:00
unwind-libunwind.c perf unwind: Don't show unwind error messages when augmenting frame pointer stack 2022-05-16 11:36:17 +02:00
unwind.h perf unwind: Don't show unwind error messages when augmenting frame pointer stack 2022-05-16 11:36:17 +02:00
usage.c
util.c perf tools: Add reallocarray_as_needed() 2022-11-14 20:25:46 +01:00
util.h perf tools: Add reallocarray_as_needed() 2022-11-14 20:25:46 +01:00
values.c
values.h
vdso.c
vdso.h
zlib.c
zstd.c