On Tue, 23 Dec 2025 10:22:18 -0800
Namhyung Kim [off-list ref] wrote:
Reviewed-by: Namhyung Kim <namhyung@kernel.org>
Thanks,
Namhyung
quoted
---
kernel/trace/trace_events.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index a5a93d243047..754b14ca87a7 100644
--- a/kernel/trace/trace_events.c
+++ b/kernel/trace/trace_events.c
@@ -710,6 +710,8 @@ int trace_event_reg(struct trace_event_call *call,
#ifdef CONFIG_PERF_EVENTS
case TRACE_REG_PERF_REGISTER:
+ if (!call->class->perf_probe)
+ return -ENODEV;
Thanks Namhyung (and Jiri), but this actually already made it upstream as
it was a bug fix and I wanted to get it into the next rc release (rc2).
But, the real fix is having perf be able to handle synthetic_events as real
events.
Can you please review this patch:
https://lore.kernel.org/linux-trace-kernel/20251217113920.50b56246@gandalf.local.home/ (local)
I plan on queuing that for the next merge window.
Thanks,
-- Steve
quoted
return tracepoint_probe_register(call->tp,
call->class->perf_probe,
call);
--