diff options
author | Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro> | 2009-03-23 09:12:24 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-04-03 06:23:06 -0400 |
commit | ca2b84cb3c4a0d4d2143b46ec072cdff5d1b3b87 (patch) | |
tree | 7163bac040f11c444b24cab53c4a784df73fa4f3 /mm/util.c | |
parent | ac44021fccd8f1f2b267b004f23a2e8d7ef05f7b (diff) |
kmemtrace: use tracepoints
kmemtrace now uses tracepoints instead of markers. We no longer need to
use format specifiers to pass arguments.
Signed-off-by: Eduard - Gabriel Munteanu <eduard.munteanu@linux360.ro>
[ folded: Use the new TP_PROTO and TP_ARGS to fix the build. ]
[ folded: fix build when CONFIG_KMEMTRACE is disabled. ]
[ folded: define tracepoints when CONFIG_TRACEPOINTS is enabled. ]
Signed-off-by: Pekka Enberg <penberg@cs.helsinki.fi>
LKML-Reference: <ae61c0f37156db8ec8dc0d5778018edde60a92e3.1237813499.git.eduard.munteanu@linux360.ro>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'mm/util.c')
-rw-r--r-- | mm/util.c | 16 |
1 files changed, 16 insertions, 0 deletions
@@ -4,6 +4,7 @@ | |||
4 | #include <linux/module.h> | 4 | #include <linux/module.h> |
5 | #include <linux/err.h> | 5 | #include <linux/err.h> |
6 | #include <linux/sched.h> | 6 | #include <linux/sched.h> |
7 | #include <linux/tracepoint.h> | ||
7 | #include <asm/uaccess.h> | 8 | #include <asm/uaccess.h> |
8 | 9 | ||
9 | /** | 10 | /** |
@@ -236,3 +237,18 @@ int __attribute__((weak)) get_user_pages_fast(unsigned long start, | |||
236 | return ret; | 237 | return ret; |
237 | } | 238 | } |
238 | EXPORT_SYMBOL_GPL(get_user_pages_fast); | 239 | EXPORT_SYMBOL_GPL(get_user_pages_fast); |
240 | |||
241 | /* Tracepoints definitions. */ | ||
242 | DEFINE_TRACE(kmalloc); | ||
243 | DEFINE_TRACE(kmem_cache_alloc); | ||
244 | DEFINE_TRACE(kmalloc_node); | ||
245 | DEFINE_TRACE(kmem_cache_alloc_node); | ||
246 | DEFINE_TRACE(kfree); | ||
247 | DEFINE_TRACE(kmem_cache_free); | ||
248 | |||
249 | EXPORT_TRACEPOINT_SYMBOL(kmalloc); | ||
250 | EXPORT_TRACEPOINT_SYMBOL(kmem_cache_alloc); | ||
251 | EXPORT_TRACEPOINT_SYMBOL(kmalloc_node); | ||
252 | EXPORT_TRACEPOINT_SYMBOL(kmem_cache_alloc_node); | ||
253 | EXPORT_TRACEPOINT_SYMBOL(kfree); | ||
254 | EXPORT_TRACEPOINT_SYMBOL(kmem_cache_free); | ||