aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/linux/slab_def.h2
-rw-r--r--include/linux/slub_def.h2
-rw-r--r--include/trace/kmemtrace.h (renamed from include/linux/kmemtrace.h)19
3 files changed, 6 insertions, 17 deletions
diff --git a/include/linux/slab_def.h b/include/linux/slab_def.h
index 7555ce99f6d2..455f9affea9a 100644
--- a/include/linux/slab_def.h
+++ b/include/linux/slab_def.h
@@ -14,7 +14,7 @@
14#include <asm/page.h> /* kmalloc_sizes.h needs PAGE_SIZE */ 14#include <asm/page.h> /* kmalloc_sizes.h needs PAGE_SIZE */
15#include <asm/cache.h> /* kmalloc_sizes.h needs L1_CACHE_BYTES */ 15#include <asm/cache.h> /* kmalloc_sizes.h needs L1_CACHE_BYTES */
16#include <linux/compiler.h> 16#include <linux/compiler.h>
17#include <linux/kmemtrace.h> 17#include <trace/kmemtrace.h>
18 18
19/* Size description struct for general caches. */ 19/* Size description struct for general caches. */
20struct cache_sizes { 20struct cache_sizes {
diff --git a/include/linux/slub_def.h b/include/linux/slub_def.h
index dc28432b5b9a..6b657f7dcb2b 100644
--- a/include/linux/slub_def.h
+++ b/include/linux/slub_def.h
@@ -10,7 +10,7 @@
10#include <linux/gfp.h> 10#include <linux/gfp.h>
11#include <linux/workqueue.h> 11#include <linux/workqueue.h>
12#include <linux/kobject.h> 12#include <linux/kobject.h>
13#include <linux/kmemtrace.h> 13#include <trace/kmemtrace.h>
14 14
15enum stat_item { 15enum stat_item {
16 ALLOC_FASTPATH, /* Allocation from cpu slab */ 16 ALLOC_FASTPATH, /* Allocation from cpu slab */
diff --git a/include/linux/kmemtrace.h b/include/trace/kmemtrace.h
index 5bea8ead6a6b..ad8b7857855a 100644
--- a/include/linux/kmemtrace.h
+++ b/include/trace/kmemtrace.h
@@ -22,28 +22,17 @@ enum kmemtrace_type_id {
22 22
23extern void kmemtrace_init(void); 23extern void kmemtrace_init(void);
24 24
25static inline void kmemtrace_mark_alloc_node(enum kmemtrace_type_id type_id, 25extern void kmemtrace_mark_alloc_node(enum kmemtrace_type_id type_id,
26 unsigned long call_site, 26 unsigned long call_site,
27 const void *ptr, 27 const void *ptr,
28 size_t bytes_req, 28 size_t bytes_req,
29 size_t bytes_alloc, 29 size_t bytes_alloc,
30 gfp_t gfp_flags, 30 gfp_t gfp_flags,
31 int node) 31 int node);
32{
33 trace_mark(kmemtrace_alloc, "type_id %d call_site %lu ptr %lu "
34 "bytes_req %lu bytes_alloc %lu gfp_flags %lu node %d",
35 type_id, call_site, (unsigned long) ptr,
36 (unsigned long) bytes_req, (unsigned long) bytes_alloc,
37 (unsigned long) gfp_flags, node);
38}
39 32
40static inline void kmemtrace_mark_free(enum kmemtrace_type_id type_id, 33extern void kmemtrace_mark_free(enum kmemtrace_type_id type_id,
41 unsigned long call_site, 34 unsigned long call_site,
42 const void *ptr) 35 const void *ptr);
43{
44 trace_mark(kmemtrace_free, "type_id %d call_site %lu ptr %lu",
45 type_id, call_site, (unsigned long) ptr);
46}
47 36
48#else /* CONFIG_KMEMTRACE */ 37#else /* CONFIG_KMEMTRACE */
49 38