Skip to content

Commit e3d6e1b

Browse files
committed
tracing: tprobe-events: Support multiple tprobes on the same tracepoint
Allow user to set multiple tracepoint-probe events on the same tracepoint. After the last tprobe-event is removed, the tracepoint callback is unregistered. Link: https://lore.kernel.org/all/174343536245.843280.6548776576601537671.stgit@devnote2/ Signed-off-by: Masami Hiramatsu (Google) <mhiramat@kernel.org>
1 parent c135ab4 commit e3d6e1b

2 files changed

Lines changed: 205 additions & 50 deletions

File tree

include/linux/module.h

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
#include <linux/buildid.h>
1515
#include <linux/compiler.h>
1616
#include <linux/cache.h>
17+
#include <linux/cleanup.h>
1718
#include <linux/kmod.h>
1819
#include <linux/init.h>
1920
#include <linux/elf.h>
@@ -1019,4 +1020,7 @@ static inline unsigned long find_kallsyms_symbol_value(struct module *mod,
10191020

10201021
#endif /* CONFIG_MODULES && CONFIG_KALLSYMS */
10211022

1023+
/* Define __free(module_put) macro for struct module *. */
1024+
DEFINE_FREE(module_put, struct module *, if (_T) module_put(_T))
1025+
10221026
#endif /* _LINUX_MODULE_H */

0 commit comments

Comments
 (0)