summaryrefslogtreecommitdiffstats
path: root/poky/meta/recipes-kernel/lttng
diff options
context:
space:
mode:
Diffstat (limited to 'poky/meta/recipes-kernel/lttng')
-rw-r--r--poky/meta/recipes-kernel/lttng/babeltrace_1.5.6.bb (renamed from poky/meta/recipes-kernel/lttng/babeltrace_1.5.4.bb)13
-rw-r--r--poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch116
-rw-r--r--poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch67
-rw-r--r--poky/meta/recipes-kernel/lttng/lttng-modules_2.10.7.bb (renamed from poky/meta/recipes-kernel/lttng/lttng-modules_2.10.6.bb)6
-rw-r--r--poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch43
-rw-r--r--poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service9
-rw-r--r--poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb13
7 files changed, 258 insertions, 9 deletions
diff --git a/poky/meta/recipes-kernel/lttng/babeltrace_1.5.4.bb b/poky/meta/recipes-kernel/lttng/babeltrace_1.5.6.bb
index a29402adb..f5c31c446 100644
--- a/poky/meta/recipes-kernel/lttng/babeltrace_1.5.4.bb
+++ b/poky/meta/recipes-kernel/lttng/babeltrace_1.5.6.bb
@@ -2,18 +2,19 @@ SUMMARY = "Babeltrace - Trace Format Babel Tower"
DESCRIPTION = "Babeltrace provides trace read and write libraries in host side, as well as a trace converter, which used to convert LTTng 2.0 traces into human-readable log."
HOMEPAGE = "http://www.efficios.com/babeltrace/"
BUGTRACKER = "https://bugs.lttng.org/projects/babeltrace"
-
LICENSE = "MIT & GPLv2"
LIC_FILES_CHKSUM = "file://LICENSE;md5=76ba15dd76a248e1dd526bca0e2125fa"
DEPENDS = "glib-2.0 util-linux popt bison-native flex-native"
-inherit autotools pkgconfig
+SRC_URI = "git://git.linuxfoundation.org/diamon/babeltrace.git;branch=stable-1.5"
+SRCREV = "4f10a4adabee5ca61c27ba399b3438505e0cd6de"
+UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)$"
-SRC_URI = "http://www.efficios.com/files/babeltrace/babeltrace-${PV}.tar.bz2 \
-"
+S = "${WORKDIR}/git"
+
+inherit autotools pkgconfig
EXTRA_OECONF = "--disable-debug-info"
-SRC_URI[md5sum] = "3e8cdafec3ac0346a389870e87bf1344"
-SRC_URI[sha256sum] = "9643039923a0abc75a25b3d594cee0017423b57f10d2b625e96ed1e8d4891fc1"
+ASNEEDED = ""
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch
new file mode 100644
index 000000000..0fe4ee829
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-btrfs-Remove-unnecessary-fs_info-parameter.patch
@@ -0,0 +1,116 @@
+From 51ab0b1da29354375a19f865abcd233dd2178295 Mon Sep 17 00:00:00 2001
+From: Michael Jeanson <mjeanson@efficios.com>
+Date: Mon, 18 Jun 2018 14:53:19 -0400
+Subject: [PATCH] Fix: btrfs: Remove unnecessary fs_info parameter
+
+See upstream commit:
+
+ commit 3dca5c942dac60164e6a6e89172f25b86af07ce7
+ Author: Qu Wenruo <wqu@suse.com>
+ Date: Thu Apr 26 14:24:25 2018 +0800
+
+ btrfs: trace: Remove unnecessary fs_info parameter for btrfs__reserve_extent event class
+
+ fs_info can be extracted from btrfs_block_group_cache, and all
+ btrfs_block_group_cache is created by btrfs_create_block_group_cache()
+ with fs_info initialized, no need to worry about NULL pointer
+ dereference.
+
+Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
+Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+Upstream-Status: Backport
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+---
+ instrumentation/events/lttng-module/btrfs.h | 54 ++++++++++++++++++++++++++++-
+ 1 file changed, 53 insertions(+), 1 deletion(-)
+
+diff --git a/instrumentation/events/lttng-module/btrfs.h b/instrumentation/events/lttng-module/btrfs.h
+index 75cc73b..fd1b6b8 100644
+--- a/instrumentation/events/lttng-module/btrfs.h
++++ b/instrumentation/events/lttng-module/btrfs.h
+@@ -1658,8 +1658,57 @@ LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserved_extent, btrfs_reserved_extent_f
+
+ #endif /* #else #if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,10,0)) */
+
+-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0))
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,18,0))
++LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
++
++ btrfs_find_free_extent,
++
++ TP_PROTO(const struct btrfs_fs_info *info, u64 num_bytes, u64 empty_size,
++ u64 data),
++
++ TP_ARGS(info, num_bytes, empty_size, data),
++
++ TP_FIELDS(
++ ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
++ ctf_integer(u64, num_bytes, num_bytes)
++ ctf_integer(u64, empty_size, empty_size)
++ ctf_integer(u64, data, data)
++ )
++)
++
++LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent,
++
++ TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start,
++ u64 len),
++
++ TP_ARGS(block_group, start, len),
++
++ TP_FIELDS(
++ ctf_array(u8, fsid, block_group->fs_info->fsid, BTRFS_UUID_SIZE)
++ ctf_integer(u64, bg_objectid, block_group->key.objectid)
++ ctf_integer(u64, flags, block_group->flags)
++ ctf_integer(u64, start, start)
++ ctf_integer(u64, len, len)
++ )
++)
++
++LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent,
++
++ TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start,
++ u64 len),
++
++ TP_ARGS(block_group, start, len)
++)
++
++LTTNG_TRACEPOINT_EVENT_INSTANCE(btrfs__reserve_extent, btrfs_reserve_extent_cluster,
++
++ TP_PROTO(const struct btrfs_block_group_cache *block_group, u64 start,
++ u64 len),
++
++ TP_ARGS(block_group, start, len)
++)
+
++#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,14,0))
+ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
+
+ btrfs_find_free_extent,
+@@ -1670,6 +1719,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
+ TP_ARGS(info, num_bytes, empty_size, data),
+
+ TP_FIELDS(
++ ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
+ ctf_integer(u64, num_bytes, num_bytes)
+ ctf_integer(u64, empty_size, empty_size)
+ ctf_integer(u64, data, data)
+@@ -1685,6 +1735,7 @@ LTTNG_TRACEPOINT_EVENT_CLASS(btrfs__reserve_extent,
+ TP_ARGS(info, block_group, start, len),
+
+ TP_FIELDS(
++ ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
+ ctf_integer(u64, bg_objectid, block_group->key.objectid)
+ ctf_integer(u64, flags, block_group->flags)
+ ctf_integer(u64, start, start)
+@@ -1722,6 +1773,7 @@ LTTNG_TRACEPOINT_EVENT_MAP(find_free_extent,
+ TP_ARGS(info, num_bytes, empty_size, data),
+
+ TP_FIELDS(
++ ctf_array(u8, fsid, info->fsid, BTRFS_UUID_SIZE)
+ ctf_integer(u64, num_bytes, num_bytes)
+ ctf_integer(u64, empty_size, empty_size)
+ ctf_integer(u64, data, data)
+--
+2.13.3
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch
new file mode 100644
index 000000000..92e12df17
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-modules/0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch
@@ -0,0 +1,67 @@
+From 9e67b4c94b94493123d38379bd9b3eceae23a6f1 Mon Sep 17 00:00:00 2001
+From: Michael Jeanson <mjeanson@efficios.com>
+Date: Fri, 7 Sep 2018 12:21:12 -0400
+Subject: [PATCH] Fix: net: expose sk wmem in sock_exceed_buf_limit tracepoint
+ (4.19)
+
+See upstream commit:
+
+ commit d6f19938eb031ee2158272757db33258153ae59c
+ Author: Yafang Shao <laoar.shao@gmail.com>
+ Date: Sun Jul 1 23:31:30 2018 +0800
+
+ net: expose sk wmem in sock_exceed_buf_limit tracepoint
+
+ Currently trace_sock_exceed_buf_limit() only show rmem info,
+ but wmem limit may also be hit.
+ So expose wmem info in this tracepoint as well.
+
+ Regarding memcg, I think it is better to introduce a new tracepoint(if
+ that is needed), i.e. trace_memcg_limit_hit other than show memcg info in
+ trace_sock_exceed_buf_limit.
+
+Signed-off-by: Michael Jeanson <mjeanson@efficios.com>
+Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
+Upstream-Status: Backport
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+---
+ instrumentation/events/lttng-module/sock.h | 23 ++++++++++++++++++++++-
+ 1 file changed, 22 insertions(+), 1 deletion(-)
+
+diff --git a/instrumentation/events/lttng-module/sock.h b/instrumentation/events/lttng-module/sock.h
+index 5cd02ca..cd0c92b 100644
+--- a/instrumentation/events/lttng-module/sock.h
++++ b/instrumentation/events/lttng-module/sock.h
+@@ -21,7 +21,28 @@ LTTNG_TRACEPOINT_EVENT(sock_rcvqueue_full,
+ )
+ )
+
+-#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
++#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4,19,0))
++
++LTTNG_TRACEPOINT_EVENT(sock_exceed_buf_limit,
++
++ TP_PROTO(struct sock *sk, struct proto *prot, long allocated, int kind),
++
++ TP_ARGS(sk, prot, allocated, kind),
++
++ TP_FIELDS(
++ ctf_string(name, prot->name)
++ ctf_array(long, sysctl_mem, prot->sysctl_mem, 3)
++ ctf_integer(long, allocated, allocated)
++ ctf_integer(int, sysctl_rmem, sk_get_rmem0(sk, prot))
++ ctf_integer(int, rmem_alloc, atomic_read(&sk->sk_rmem_alloc))
++ ctf_integer(int, sysctl_wmem, sk_get_wmem0(sk, prot))
++ ctf_integer(int, wmem_alloc, refcount_read(&sk->sk_wmem_alloc))
++ ctf_integer(int, wmem_queued, sk->sk_wmem_queued)
++ ctf_integer(int, kind, kind)
++ )
++)
++
++#elif (LINUX_VERSION_CODE >= KERNEL_VERSION(4,15,0))
+
+ LTTNG_TRACEPOINT_EVENT(sock_exceed_buf_limit,
+
+--
+2.7.4
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.6.bb b/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.7.bb
index 614696689..f6c865a87 100644
--- a/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.6.bb
+++ b/poky/meta/recipes-kernel/lttng/lttng-modules_2.10.7.bb
@@ -11,13 +11,15 @@ inherit module
COMPATIBLE_HOST = '(x86_64|i.86|powerpc|aarch64|mips|nios2|arm).*-linux'
+#https://lttng.org/files/lttng-modules/lttng-modules-2.10.7.tar.bz2
SRC_URI = "https://lttng.org/files/${BPN}/${BPN}-${PV}.tar.bz2 \
file://Makefile-Do-not-fail-if-CONFIG_TRACEPOINTS-is-not-en.patch \
file://BUILD_RUNTIME_BUG_ON-vs-gcc7.patch \
+ file://0001-Fix-net-expose-sk-wmem-in-sock_exceed_buf_limit-trac.patch \
"
-SRC_URI[md5sum] = "8110099f4615fc89a74ffe9189b56cfc"
-SRC_URI[sha256sum] = "04a080c81743eb29d181bac29ceb0c15819a2f4210793f2cc9958d885435029f"
+SRC_URI[md5sum] = "d3cb4520948083bf1573a2e4cb7406aa"
+SRC_URI[sha256sum] = "f049428d3d131e103a7a7038d184731bf7bcdce00503fc19a2c9b5693ecbb3b5"
export INSTALL_MOD_DIR="kernel/lttng-modules"
diff --git a/poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch b/poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch
new file mode 100644
index 000000000..62a097859
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-tools/0001-Allow-multiple-attempts-to-connect-to-relayd.patch
@@ -0,0 +1,43 @@
+From 70eff899104b86bae02862927c76caaef5de5d3c Mon Sep 17 00:00:00 2001
+From: Mikael Beckius <mikael.beckius@windriver.com>
+Date: Thu, 7 May 2015 16:14:25 +0200
+Subject: [PATCH] Allow multiple attempts to connect to relayd.
+
+It is unclear why a session needs to be made
+unusable after a failure to connect to relayd
+since a check for a relayd connection is
+always made before a session can be configured.
+
+The behaviour was introduced in:
+d9078d0c000d04d49c599a72c1a725026b636ec0
+
+Signed-off-by: Mikael Beckius <mikael.beckius@windriver.com>
+[ The context has moved, adjust the hunk accordingly ]
+Signed-off-by: He Zhe <zhe.he@windriver.com>
+Upstream-Status: Pending
+---
+ src/bin/lttng-sessiond/cmd.c | 8 --------
+ 1 file changed, 8 deletions(-)
+
+diff --git a/src/bin/lttng-sessiond/cmd.c b/src/bin/lttng-sessiond/cmd.c
+index 73b4ce3..36f62ee 100644
+--- a/src/bin/lttng-sessiond/cmd.c
++++ b/src/bin/lttng-sessiond/cmd.c
+@@ -689,14 +689,6 @@ close_sock:
+ free(rsock);
+
+ error:
+- if (ret != LTTNG_OK) {
+- /*
+- * The consumer output for this session should not be used anymore
+- * since the relayd connection failed thus making any tracing or/and
+- * streaming not usable.
+- */
+- consumer->enabled = 0;
+- }
+ return ret;
+ }
+
+--
+1.7.9.5
+
diff --git a/poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service b/poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service
new file mode 100644
index 000000000..aaf813059
--- /dev/null
+++ b/poky/meta/recipes-kernel/lttng/lttng-tools/lttng-sessiond.service
@@ -0,0 +1,9 @@
+[Unit]
+Description=LTTng 2.x central tracing registry session daemon
+
+[Service]
+Type=forking
+ExecStart=/usr/bin/lttng-sessiond -d
+
+[Install]
+WantedBy=multi-user.target
diff --git a/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb b/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb
index 93626dd4b..0314b5363 100644
--- a/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb
+++ b/poky/meta/recipes-kernel/lttng/lttng-tools_2.9.5.bb
@@ -30,12 +30,17 @@ PACKAGECONFIG_remove_riscv64 = "lttng-ust"
SRC_URI = "https://lttng.org/files/lttng-tools/lttng-tools-${PV}.tar.bz2 \
file://x32.patch \
file://run-ptest \
+ file://0001-Allow-multiple-attempts-to-connect-to-relayd.patch \
+ file://lttng-sessiond.service \
"
SRC_URI[md5sum] = "051224eb991aee07f8721ff1877d0b96"
SRC_URI[sha256sum] = "77839eb6fc6c652125f08acfd9369701c2516eb05cc2084160e7efc7a3fb731c"
-inherit autotools ptest pkgconfig useradd python3-dir manpages
+inherit autotools ptest pkgconfig useradd python3-dir manpages systemd
+
+SYSTEMD_SERVICE_${PN} = "lttng-sessiond.service"
+SYSTEMD_AUTO_ENABLE = "disable"
USERADD_PACKAGES = "${PN}"
GROUPADD_PARAM_${PN} = "tracing"
@@ -51,6 +56,12 @@ FILES_${PN}-dev += "${PYTHON_SITEPACKAGES_DIR}/*.la"
INSANE_SKIP_${PN} = "libexec dev-so"
INSANE_SKIP_${PN}-dbg = "libexec"
+do_install_append () {
+ # install systemd unit file
+ install -d ${D}${systemd_unitdir}/system
+ install -m 0644 ${WORKDIR}/lttng-sessiond.service ${D}${systemd_unitdir}/system
+}
+
do_install_ptest () {
for f in Makefile tests/Makefile tests/utils/utils.sh ; do
install -D "${B}/$f" "${D}${PTEST_PATH}/$f"
OpenPOWER on IntegriCloud