mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2026-09-22 09:34:56 +02:00
tools/rv: Fix cleanup after failed trace setup
[ Upstream commit33ec2269a4] Currently if ikm_setup_trace_instance() fails, the tool returns without any cleanup, if rv was called with both -t and -r, this means the reactor is not going to be cleared. Jump to the cleanup label to restore the reactor if necessary. Fixes:6d60f89691("tools/rv: Add in-kernel monitor interface") Reviewed-by: Nam Cao <namcao@linutronix.de> Link: https://lore.kernel.org/r/20260514152055.229162-5-gmonaco@redhat.com Signed-off-by: Gabriele Monaco <gmonaco@redhat.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
7fce959e9b
commit
9eaa4e8d55
@@ -655,7 +655,7 @@ int ikm_run_monitor(char *monitor_name, int argc, char **argv)
|
||||
if (config_trace) {
|
||||
inst = ikm_setup_trace_instance(monitor_name);
|
||||
if (!inst)
|
||||
return -1;
|
||||
goto out_free_instance;
|
||||
}
|
||||
|
||||
retval = ikm_enable(monitor_name);
|
||||
|
||||
Reference in New Issue
Block a user