summaryrefslogtreecommitdiffstats
path: root/meta/recipes-kernel/lttng/lttng-modules/Update-vmscan-instrumentation-to-3.16-kernel.patch
diff options
context:
space:
mode:
Diffstat (limited to 'meta/recipes-kernel/lttng/lttng-modules/Update-vmscan-instrumentation-to-3.16-kernel.patch')
-rw-r--r--meta/recipes-kernel/lttng/lttng-modules/Update-vmscan-instrumentation-to-3.16-kernel.patch70
1 files changed, 70 insertions, 0 deletions
diff --git a/meta/recipes-kernel/lttng/lttng-modules/Update-vmscan-instrumentation-to-3.16-kernel.patch b/meta/recipes-kernel/lttng/lttng-modules/Update-vmscan-instrumentation-to-3.16-kernel.patch
new file mode 100644
index 0000000000..5f02270e89
--- /dev/null
+++ b/meta/recipes-kernel/lttng/lttng-modules/Update-vmscan-instrumentation-to-3.16-kernel.patch
@@ -0,0 +1,70 @@
1From 5defe623568273e9b87da1b817e373ff087fd862 Mon Sep 17 00:00:00 2001
2From: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
3Date: Sun, 13 Jul 2014 13:27:01 -0400
4Subject: [PATCH 1/2] Update vmscan instrumentation to 3.16 kernel
5
6Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
7---
8 instrumentation/events/lttng-module/vmscan.h | 39 ++++++++++++++++++++++++++++
9 1 file changed, 39 insertions(+)
10
11diff --git a/instrumentation/events/lttng-module/vmscan.h b/instrumentation/events/lttng-module/vmscan.h
12index 1fd50ba7c235..0b4aa56761dc 100644
13--- a/instrumentation/events/lttng-module/vmscan.h
14+++ b/instrumentation/events/lttng-module/vmscan.h
15@@ -238,6 +238,44 @@ TRACE_EVENT(mm_shrink_slab_start,
16 __entry->total_scan)
17 )
18
19+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0))
20+TRACE_EVENT(mm_shrink_slab_end,
21+ TP_PROTO(struct shrinker *shr, int nid, int shrinker_retval,
22+ long unused_scan_cnt, long new_scan_cnt, long total_scan),
23+
24+ TP_ARGS(shr, nid, shrinker_retval, unused_scan_cnt, new_scan_cnt,
25+ total_scan),
26+
27+ TP_STRUCT__entry(
28+ __field(struct shrinker *, shr)
29+ __field(int, nid)
30+ __field(void *, shrink)
31+ __field(long, unused_scan)
32+ __field(long, new_scan)
33+ __field(int, retval)
34+ __field(long, total_scan)
35+ ),
36+
37+ TP_fast_assign(
38+ tp_assign(shr, shr)
39+ tp_assign(nid, nid)
40+ tp_assign(shrink, shr->scan_objects)
41+ tp_assign(unused_scan, unused_scan_cnt)
42+ tp_assign(new_scan, new_scan_cnt)
43+ tp_assign(retval, shrinker_retval)
44+ tp_assign(total_scan, total_scan)
45+ ),
46+
47+ TP_printk("%pF %p: nid %d unused scan count %ld new scan count %ld total_scan %ld last shrinker return val %d",
48+ __entry->shrink,
49+ __entry->shr,
50+ __entry->nid,
51+ __entry->unused_scan,
52+ __entry->new_scan,
53+ __entry->total_scan,
54+ __entry->retval)
55+)
56+#else /* #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0)) */
57 TRACE_EVENT(mm_shrink_slab_end,
58 TP_PROTO(struct shrinker *shr, int shrinker_retval,
59 long unused_scan_cnt, long new_scan_cnt),
60@@ -274,6 +312,7 @@ TRACE_EVENT(mm_shrink_slab_end,
61 __entry->total_scan,
62 __entry->retval)
63 )
64+#endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0)) */
65 #endif
66
67 DECLARE_EVENT_CLASS(mm_vmscan_lru_isolate_template,
68--
691.8.1.2
70