mirror-linux/tools/perf/tests/shell
Thomas Richter 744175e972 perf test: Checking BPF metadata collection fails on version string
commit edf2cadf01 ("perf test: add test for BPF metadata collection")

fails consistently on the version string check. The perf version
string on some of the constant integration test machines contains
characters with special meaning in grep's extended regular expression
matching algorithm. The output of perf version is:

 # perf version
 perf version 6.17.0-20250814.rc1.git20.24ea63ea3877.63.fc42.s390x+git
 #

and the '+' character has special meaning in egrep command.
Also the use of egrep is deprecated.

Change the perf version string check to fixed character matching
and get rid of egrep's warning being deprecated. Use grep -F instead.

Output before:
 # perf test -F 102
 Checking BPF metadata collection
 egrep: warning: egrep is obsolescent; using grep -E
 Basic BPF metadata test [Failed invalid output]
 102: BPF metadata collection test             : FAILED!
 #

Output after:
 # perf test -F 102
 Checking BPF metadata collection
 Basic BPF metadata test [Success]
 102: BPF metadata collection test             : Ok
 #

Fixes: edf2cadf01 ("perf test: add test for BPF metadata collection")
Signed-off-by: Thomas Richter <tmricht@linux.ibm.com>
Reviewed-by: Ian Rogers <irogers@google.com>
Reviewed-by: Arnaldo Carvalho de Melo <acme@redhat.com>
Acked-by: Sumanth Korikkar <sumanthk@linux.ibm.com>
Cc: Blake Jones <blakejones@google.com>
Link: https://lore.kernel.org/r/20250822122540.4104658-1-tmricht@linux.ibm.com
Signed-off-by: Namhyung Kim <namhyung@kernel.org>
2025-09-04 16:37:19 -07:00
..
attr perf tools: Don't set attr.exclude_guest by default 2024-10-22 09:52:11 -07:00
base_probe perf test perftool_testsuite: Return correct value for skipping 2025-01-14 14:57:20 -03:00
base_report perf test: Add tests for latency and parallelism profiling 2025-02-18 14:04:32 -08:00
common perf test perftool_testsuite: Return correct value for skipping 2025-01-14 14:57:20 -03:00
coresight perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
lib perf stat: Fix uncore aggregation number 2025-06-27 16:14:10 -07:00
amd-ibs-swfilt.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
annotate.sh perf test annotate: Use --percent-limit rather than head to reduce output 2025-06-30 09:12:55 -07:00
attr.sh
buildid.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
daemon.sh
diff.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
drm_pmu.sh perf tests: Add a DRM PMU test 2025-06-25 11:12:35 -07:00
ftrace.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
header.sh perf header: Fix pipe mode header dumping 2025-07-03 11:22:17 -07:00
list.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
lock_contention.sh perf test: Ensure lock contention using pipe mode 2025-07-30 13:38:53 -07:00
perf-report-hierarchy.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
perftool-testsuite_probe.sh perf test: Skip perf probe tests when running as non-root 2025-03-05 09:17:01 -08:00
perftool-testsuite_report.sh perf test: Tag parallel failing shell tests with "(exclusive)" 2024-10-28 09:32:58 -07:00
pipe_test.sh
probe_vfs_getname.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
record+probe_libc_inet_pton.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
record+script_probe_vfs_getname.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
record+zstd_comp_decomp.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
record.sh perf test: Add basic callgraph test to record testing 2025-06-30 09:11:39 -07:00
record_bpf_filter.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
record_lbr.sh perf test: Update sysfs path for core PMU caps 2025-05-13 17:45:35 -03:00
record_offcpu.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
record_sideband.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
sched.sh perf test: Add more test cases to sched test 2025-07-03 11:52:20 -07:00
script.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
stat+csv_output.sh perf test: Add --metric-only to perf stat output tests 2025-03-05 09:17:01 -08:00
stat+csv_summary.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
stat+event_uniquifying.sh perf test: Restrict uniquifying test to machines with 'uncore_imc' 2025-06-16 14:05:10 -03:00
stat+json_output.sh perf tests metric-only perf stat: Fix tests 84 and 86 s390 2025-04-25 12:32:07 -03:00
stat+shadow_stat.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
stat+std_output.sh perf test: Add --metric-only to perf stat output tests 2025-03-05 09:17:01 -08:00
stat.sh perf test stat: Additional topdown grouping tests 2025-03-11 19:05:04 -07:00
stat_all_metricgroups.sh
stat_all_metrics.sh perf tests metrics: Permission related fixes 2025-05-12 14:18:16 -03:00
stat_all_pfm.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
stat_all_pmu.sh perf test stat_all_pmu.sh: Correctly check 'perf stat' result 2025-03-14 10:41:34 -07:00
stat_bpf_counters.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
stat_bpf_counters_cgrp.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
stat_metrics_values.sh perf test: Hybrid improvements for metric value validation test 2025-05-13 17:24:42 -03:00
test_arm_callgraph_fp.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
test_arm_coresight.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
test_arm_coresight_disasm.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
test_arm_spe.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
test_arm_spe_fork.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
test_bpf_metadata.sh perf test: Checking BPF metadata collection fails on version string 2025-09-04 16:37:19 -07:00
test_brstack.sh perf tests: Harden branch stack sampling test 2025-05-12 14:55:15 -03:00
test_data_symbol.sh perf mem/c2c amd: Add ldlat support 2025-04-29 22:30:46 -03:00
test_intel_pt.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
test_java_symbol.sh
test_perf_data_converter_json.sh
test_stat_intel_tpebs.sh perf test: Extra verbosity and hypervisor skip for tpebs test 2025-02-03 19:45:50 -08:00
test_task_analyzer.sh perf tests shell task_analyzer: Run this test exclusively 2025-01-08 17:20:42 -03:00
test_uprobe_from_different_cu.sh perf test: Skip perf probe tests when running as non-root 2025-03-05 09:17:01 -08:00
trace+probe_vfs_getname.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
trace_btf_enum.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
trace_btf_general.sh perf test trace: Change the regex pattern in the struct test 2025-06-09 11:18:20 -07:00
trace_exit_race.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
trace_record_replay.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00
trace_summary.sh perf test: Change all remaining #!/bin/sh to #!/bin/bash 2025-06-26 10:31:05 -07:00