]> git.ipfire.org Git - thirdparty/linux.git/commit
rv: Remove rv_reactor's reference counter
authorNam Cao <namcao@linutronix.de>
Thu, 24 Jul 2025 17:33:29 +0000 (19:33 +0200)
committerSteven Rostedt (Google) <rostedt@goodmis.org>
Fri, 25 Jul 2025 13:04:14 +0000 (09:04 -0400)
commit3d3800b4f7f4b1472a0ec2cffd535c05603f8f60
treef576c7270f0c602865d654f55959ef2564620ca8
parent3d3c376118b5f7ed7723c2b4fd7a0a1c1893d63e
rv: Remove rv_reactor's reference counter

rv_reactor has a reference counter to ensure it is not removed while
monitors are still using it.

However, this is futile, as __exit functions are not expected to fail and
will proceed normally despite rv_unregister_reactor() returning an error.

At the moment, reactors do not support being built as modules, therefore
they are never removed and the reference counters are not necessary.

If we support building RV reactors as modules in the future, kernel
module's centralized facilities such as try_module_get(), module_put() or
MODULE_SOFTDEP should be used instead of this custom implementation.

Remove this reference counter.

Cc: Masami Hiramatsu <mhiramat@kernel.org>
Cc: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Link: https://lore.kernel.org/bb946398436a5e17fb0f5b842ef3313c02291852.1753378331.git.namcao@linutronix.de
Reviewed-by: Gabriele Monaco <gmonaco@redhat.com>
Signed-off-by: Nam Cao <namcao@linutronix.de>
Signed-off-by: Steven Rostedt (Google) <rostedt@goodmis.org>
include/linux/rv.h
kernel/trace/rv/rv.c
kernel/trace/rv/rv.h
kernel/trace/rv/rv_reactors.c