Skip to content

Commit 4edab4c

Browse files
eddyz87Alexei Starovoitov
authored andcommitted
selftests/bpf: update send_signal to lower perf evemts frequency
Similar to commit [1] sample perf events less often in test_send_signal_nmi(). This should reduce perf events throttling. [1] 7015843 ("selftests/bpf: Fix send_signal test with nested CONFIG_PARAVIRT") Signed-off-by: Eduard Zingerman <eddyz87@gmail.com> Link: https://lore.kernel.org/r/20241112110906.3045278-5-eddyz87@gmail.com Signed-off-by: Alexei Starovoitov <ast@kernel.org>
1 parent 3209139 commit 4edab4c

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

tools/testing/selftests/bpf/prog_tests/send_signal.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,7 +229,8 @@ static void test_send_signal_perf(bool signal_thread, bool remote)
229229
static void test_send_signal_nmi(bool signal_thread, bool remote)
230230
{
231231
struct perf_event_attr attr = {
232-
.sample_period = 1,
232+
.freq = 1,
233+
.sample_freq = 1000,
233234
.type = PERF_TYPE_HARDWARE,
234235
.config = PERF_COUNT_HW_CPU_CYCLES,
235236
};

0 commit comments

Comments
 (0)