[packages/lttng-modules] - up to 2.5.2 - fix build with linux 3.18
baggins
baggins at pld-linux.org
Mon Jan 26 00:44:00 CET 2015
commit 6be7f7c9762f609e9ebd51537cbae8016a6b7021
Author: Jan Rękorajski <baggins at pld-linux.org>
Date: Mon Jan 26 00:43:44 2015 +0100
- up to 2.5.2
- fix build with linux 3.18
linux-3.14.25.patch | 11 ---------
linux-3.18.patch | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++
lttng-modules.spec | 8 +++----
3 files changed, 70 insertions(+), 15 deletions(-)
---
diff --git a/lttng-modules.spec b/lttng-modules.spec
index a7e893e..a88e22c 100644
--- a/lttng-modules.spec
+++ b/lttng-modules.spec
@@ -20,20 +20,20 @@ exit 1
%define kpkg %(echo %{_build_kernels} | tr , '\\n' | while read n ; do echo %%undefine alt_kernel ; [ -z "$n" ] || echo %%define alt_kernel $n ; echo %%kernel_pkg ; done)
%define bkpkg %(echo %{_build_kernels} | tr , '\\n' | while read n ; do echo %%undefine alt_kernel ; [ -z "$n" ] || echo %%define alt_kernel $n ; echo %%build_kernel_pkg ; done)
-%define rel 3
+%define rel 1
%define pname lttng-modules
Summary: LTTng 2.x kernel modules
Summary(pl.UTF-8): Moduły jądra LTTng 2.x
Name: %{pname}%{_alt_kernel}
-Version: 2.5.1
+Version: 2.5.2
Release: %{rel}@%{_kernel_ver_str}
License: GPL v2
Group: Base/Kernel
Source0: http://lttng.org/files/lttng-modules/%{pname}-%{version}.tar.bz2
-# Source0-md5: 2d99bb7311ba92e82e3b675f0b8dee7d
+# Source0-md5: 74d2fd161fdbf3426c6af5a36a774d4a
Patch0: build.patch
Patch1: linux-3.17.patch
-Patch2: linux-3.14.25.patch
+Patch2: linux-3.18.patch
URL: http://lttng.org/
%if %{with dist_kernel}
BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.38
diff --git a/linux-3.14.25.patch b/linux-3.14.25.patch
deleted file mode 100644
index 2bc6bab..0000000
--- a/linux-3.14.25.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- lttng-modules-2.5.1/instrumentation/events/lttng-module/compaction.h~ 2014-10-20 22:48:47.000000000 +0200
-+++ lttng-modules-2.5.1/instrumentation/events/lttng-module/compaction.h 2014-11-23 15:28:33.501139643 +0100
-@@ -46,7 +46,7 @@
- TP_ARGS(nr_scanned, nr_taken)
- )
-
--#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0))
-+#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,16,0)) || ((LINUX_VERSION_CODE >= KERNEL_VERSION(3,14,25)) && (LINUX_VERSION_CODE < KERNEL_VERSION(3,15,0)))
- TRACE_EVENT(mm_compaction_migratepages,
-
- TP_PROTO(unsigned long nr_all,
diff --git a/linux-3.18.patch b/linux-3.18.patch
new file mode 100644
index 0000000..f187fbe
--- /dev/null
+++ b/linux-3.18.patch
@@ -0,0 +1,66 @@
+Since kernel commit 8a9522d2fe compilation fails as kvm_age_page
+tracepoint had its signature changed, so update it accordingly.
+
+Tested pointing to kernels:
+ git reset --hard v3.17; make init/version.o
+ git reset --hard v3.18-rc1; make init/version.o
+
+Signed-off-by: Andr? Goddard Rosa <andre.goddard at gmail.com>
+---
+ instrumentation/events/lttng-module/kvm.h | 29 +++++++++++++++++++++++++++++
+ 1 file changed, 29 insertions(+)
+ mode change 100644 => 100755 instrumentation/events/lttng-module/kvm.h
+
+diff --git a/instrumentation/events/lttng-module/kvm.h b/instrumentation/events/lttng-module/kvm.h
+old mode 100644
+new mode 100755
+index c0d42e2..4f95095
+--- a/instrumentation/events/lttng-module/kvm.h
++++ b/instrumentation/events/lttng-module/kvm.h
+@@ -232,6 +232,34 @@ LTTNG_TRACEPOINT_EVENT(kvm_fpu,
+ TP_printk("%s", __print_symbolic(__entry->load, kvm_fpu_load_symbol))
+ )
+
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(3,18,0))
++
++TRACE_EVENT(kvm_age_page,
++ TP_PROTO(ulong gfn, int level, struct kvm_memory_slot *slot, int ref),
++ TP_ARGS(gfn, level, slot, ref),
++
++ TP_STRUCT__entry(
++ __field( u64, hva )
++ __field( u64, gfn )
++ __field( u8, level )
++ __field( u8, referenced )
++ ),
++
++ TP_fast_assign(
++ tp_assign(gfn, gfn)
++ tp_assign(level, level)
++ tp_assign(hva, ((gfn - slot->base_gfn) <<
++ PAGE_SHIFT) + slot->userspace_addr)
++ tp_assign(referenced, ref)
++ ),
++
++ TP_printk("hva %llx gfn %llx level %u %s",
++ __entry->hva, __entry->gfn, __entry->level,
++ __entry->referenced ? "YOUNG" : "OLD")
++)
++
++#else
++
+ TRACE_EVENT(kvm_age_page,
+ TP_PROTO(ulong hva, struct kvm_memory_slot *slot, int ref),
+ TP_ARGS(hva, slot, ref),
+@@ -254,6 +282,7 @@ LTTNG_TRACEPOINT_EVENT(kvm_age_page,
+ __entry->referenced ? "YOUNG" : "OLD")
+ )
+ #endif
++#endif
+
+ #if (LINUX_VERSION_CODE >= KERNEL_VERSION(2,6,38))
+
+--
+2.1.3
+
+
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/lttng-modules.git/commitdiff/6be7f7c9762f609e9ebd51537cbae8016a6b7021
More information about the pld-cvs-commit
mailing list