[PATCH] trace-cmd: Do not load ftrace function event plugins if plugins are disabled

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If plugin loading is disabled with trace-cmd report options '-L' or '-N',
do not load ftrace function event plugins as well.

Reported-by: Douglas RAILLARD <douglas.raillard@xxxxxxx>
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=211255
Signed-off-by: Tzvetomir Stoyanov (VMware) <tz.stoyanov@xxxxxxxxx>
---
 lib/trace-cmd/trace-input.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/trace-cmd/trace-input.c b/lib/trace-cmd/trace-input.c
index 7d28254e..89e936d3 100644
--- a/lib/trace-cmd/trace-input.c
+++ b/lib/trace-cmd/trace-input.c
@@ -3128,7 +3128,8 @@ struct tracecmd_input *tracecmd_alloc_fd(int fd)
 		goto failed_read;
 
 	/* register default ftrace functions first */
-	tracecmd_ftrace_overrides(handle, &handle->finfo);
+	if (!tracecmd_disable_plugins && !tracecmd_disable_sys_plugins)
+		tracecmd_ftrace_overrides(handle, &handle->finfo);
 
 	handle->plugin_list = trace_load_plugins(handle->pevent);
 
-- 
2.29.2




[Index of Archives]     [Linux USB Development]     [Linux USB Development]     [Linux Audio Users]     [Yosemite Hiking]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux