On 15/11/2024 20:15, Borislav Petkov wrote:
On Fri, Nov 15, 2024 at 11:48:37AM -0800, Vadim Fedorenko wrote:
arch/x86/net/bpf_jit_comp.c | 60 ++++++++++
arch/x86/net/bpf_jit_comp32.c | 33 ++++++
include/linux/bpf.h | 6 +
include/linux/filter.h | 1 +
kernel/bpf/core.c | 11 ++
kernel/bpf/helpers.c | 32 ++++++
kernel/bpf/verifier.c | 41 ++++++-
.../bpf/prog_tests/test_cpu_cycles.c | 35 ++++++
.../selftests/bpf/prog_tests/verifier.c | 2 +
.../selftests/bpf/progs/test_cpu_cycles.c | 25 +++++
.../selftests/bpf/progs/verifier_cpu_cycles.c | 104 ++++++++++++++++++
11 files changed, 344 insertions(+), 6 deletions(-)
create mode 100644 tools/testing/selftests/bpf/prog_tests/test_cpu_cycles.c
create mode 100644 tools/testing/selftests/bpf/progs/test_cpu_cycles.c
create mode 100644 tools/testing/selftests/bpf/progs/verifier_cpu_cycles.c
For your whole set:
s/boot_cpu_has/cpu_feature_enabled/g
thanks, will change it for the next version
Thx.