projects
/
firefly-linux-kernel-4.4.55.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge branch 'x86-fpu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git...
[firefly-linux-kernel-4.4.55.git]
/
include
/
trace
/
events
/
module.h
diff --git
a/include/trace/events/module.h
b/include/trace/events/module.h
index 4b0f48ba16a688da9ead5b901604419c7823ea3b..c7bb2f0482fec377b1f67edd661d6331441fe7c3 100644
(file)
--- a/
include/trace/events/module.h
+++ b/
include/trace/events/module.h
@@
-51,11
+51,14
@@
TRACE_EVENT(module_free,
TP_printk("%s", __get_str(name))
);
TP_printk("%s", __get_str(name))
);
+#ifdef CONFIG_MODULE_UNLOAD
+/* trace_module_get/put are only used if CONFIG_MODULE_UNLOAD is defined */
+
DECLARE_EVENT_CLASS(module_refcnt,
DECLARE_EVENT_CLASS(module_refcnt,
- TP_PROTO(struct module *mod, unsigned long ip
, int refcnt
),
+ TP_PROTO(struct module *mod, unsigned long ip),
- TP_ARGS(mod, ip
, refcnt
),
+ TP_ARGS(mod, ip),
TP_STRUCT__entry(
__field( unsigned long, ip )
TP_STRUCT__entry(
__field( unsigned long, ip )
@@
-65,7
+68,7
@@
DECLARE_EVENT_CLASS(module_refcnt,
TP_fast_assign(
__entry->ip = ip;
TP_fast_assign(
__entry->ip = ip;
- __entry->refcnt =
refcnt
;
+ __entry->refcnt =
__this_cpu_read(mod->refptr->incs) + __this_cpu_read(mod->refptr->decs)
;
__assign_str(name, mod->name);
),
__assign_str(name, mod->name);
),
@@
-75,17
+78,18
@@
DECLARE_EVENT_CLASS(module_refcnt,
DEFINE_EVENT(module_refcnt, module_get,
DEFINE_EVENT(module_refcnt, module_get,
- TP_PROTO(struct module *mod, unsigned long ip
, int refcnt
),
+ TP_PROTO(struct module *mod, unsigned long ip),
- TP_ARGS(mod, ip
, refcnt
)
+ TP_ARGS(mod, ip)
);
DEFINE_EVENT(module_refcnt, module_put,
);
DEFINE_EVENT(module_refcnt, module_put,
- TP_PROTO(struct module *mod, unsigned long ip
, int refcnt
),
+ TP_PROTO(struct module *mod, unsigned long ip),
- TP_ARGS(mod, ip
, refcnt
)
+ TP_ARGS(mod, ip)
);
);
+#endif /* CONFIG_MODULE_UNLOAD */
TRACE_EVENT(module_request,
TRACE_EVENT(module_request,