summaryrefslogtreecommitdiffstats
path: root/poky/meta/recipes-kernel
diff options
context:
space:
mode:
Diffstat (limited to 'poky/meta/recipes-kernel')
-rw-r--r--poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb3
-rw-r--r--poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb3
-rw-r--r--poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch103
-rw-r--r--poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch250
-rw-r--r--poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch64
-rw-r--r--poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch102
-rw-r--r--poky/meta/recipes-kernel/dtc/dtc.inc1
-rw-r--r--poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch43
-rw-r--r--poky/meta/recipes-kernel/dtc/dtc/make_install.patch23
-rw-r--r--poky/meta/recipes-kernel/dtc/dtc_1.4.7.bb (renamed from poky/meta/recipes-kernel/dtc/dtc_1.4.5.bb)2
-rw-r--r--poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb2
-rw-r--r--poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch41
-rw-r--r--poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service3
-rw-r--r--poky/meta/recipes-kernel/kexec/kexec-tools_2.0.17.bb (renamed from poky/meta/recipes-kernel/kexec/kexec-tools_2.0.16.bb)12
-rw-r--r--poky/meta/recipes-kernel/kmod/kmod_git.bb6
-rw-r--r--poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb22
-rw-r--r--poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc11
-rw-r--r--poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch44
-rw-r--r--poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.18.bb (renamed from poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.15.7.bb)6
-rw-r--r--poky/meta/recipes-kernel/linux/kernel-devsrc.bb248
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto-dev.bb6
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb38
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto-rt_4.18.bb (renamed from poky/meta/recipes-kernel/linux/linux-yocto-rt_4.15.bb)16
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb25
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.18.bb (renamed from poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.15.bb)14
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto.inc7
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb46
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb47
-rw-r--r--poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb48
-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
-rw-r--r--poky/meta/recipes-kernel/perf/perf-perl.inc7
-rw-r--r--poky/meta/recipes-kernel/perf/perf.bb25
-rw-r--r--poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch13
-rw-r--r--poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch34
-rw-r--r--poky/meta/recipes-kernel/sysprof/files/wordsize.patch38
-rw-r--r--poky/meta/recipes-kernel/sysprof/sysprof_3.30.0.bb (renamed from poky/meta/recipes-kernel/sysprof/sysprof_3.26.1.bb)11
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch42
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch61
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch277
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch215
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch36
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch128
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch29
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch39
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch38
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch42
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch31
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch40
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch53
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch117
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch15
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap_git.bb29
-rw-r--r--poky/meta/recipes-kernel/systemtap/systemtap_git.inc16
-rw-r--r--poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb33
-rw-r--r--poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc13
-rw-r--r--poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch27
-rw-r--r--poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch29
-rw-r--r--poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb34
64 files changed, 1395 insertions, 1580 deletions
diff --git a/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb b/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb
index 6052650c9..ed4327d40 100644
--- a/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb
+++ b/poky/meta/recipes-kernel/cryptodev/cryptodev-module_1.9.bb
@@ -11,6 +11,9 @@ SRC_URI += " \
file://0001-Disable-installing-header-file-provided-by-another-p.patch \
file://0001-ioctl.c-Fix-build-with-linux-4.13.patch \
file://0001-ioctl.c-Fix-build-with-linux-4.17.patch \
+file://0001-refactoring-split-big-function-to-simplify-maintaina.patch \
+file://0002-refactoring-relocate-code-to-simplify-later-patches.patch \
+file://0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch \
"
EXTRA_OEMAKE='KERNEL_DIR="${STAGING_KERNEL_DIR}" PREFIX="${D}"'
diff --git a/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb b/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb
index 9afb3de21..617db6cdd 100644
--- a/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb
+++ b/poky/meta/recipes-kernel/cryptodev/cryptodev-tests_1.9.bb
@@ -2,10 +2,11 @@ require cryptodev.inc
SUMMARY = "A test suite for /dev/crypto device driver"
-DEPENDS += "openssl10"
+DEPENDS += "openssl"
SRC_URI += " \
file://0001-Add-the-compile-and-install-rules-for-cryptodev-test.patch \
+file://0001-Port-tests-to-openssl-1.1.patch \
"
EXTRA_OEMAKE='KERNEL_DIR="${STAGING_EXECPREFIXDIR}" PREFIX="${D}"'
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch b/poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch
new file mode 100644
index 000000000..c9691265f
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0001-Port-tests-to-openssl-1.1.patch
@@ -0,0 +1,103 @@
+From 2fe4bdeb8cdd0b0f46d9caed807812855d51ea56 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 28 Mar 2018 20:11:05 +0300
+Subject: [PATCH] Port tests to openssl 1.1
+
+Upstream-Status: Accepted [https://github.com/cryptodev-linux/cryptodev-linux/pull/36]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+---
+ tests/openssl_wrapper.c | 33 +++++++++++++++++++++++++++++++++
+ 1 file changed, 33 insertions(+)
+
+diff --git a/tests/openssl_wrapper.c b/tests/openssl_wrapper.c
+index 038c58f..dea2496 100644
+--- a/tests/openssl_wrapper.c
++++ b/tests/openssl_wrapper.c
+@@ -4,6 +4,7 @@
+ #include <openssl/aes.h>
+ #include <openssl/evp.h>
+ #include <openssl/hmac.h>
++#include <openssl/opensslv.h>
+
+ //#define DEBUG
+
+@@ -23,10 +24,17 @@ enum ctx_type {
+ ctx_type_md,
+ };
+
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++union openssl_ctx {
++ HMAC_CTX *hmac;
++ EVP_MD_CTX *md;
++};
++#else
+ union openssl_ctx {
+ HMAC_CTX hmac;
+ EVP_MD_CTX md;
+ };
++#endif
+
+ struct ctx_mapping {
+ __u32 ses;
+@@ -63,6 +71,16 @@ static void remove_mapping(__u32 ses)
+ switch (mapping->type) {
+ case ctx_type_none:
+ break;
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++ case ctx_type_hmac:
++ dbgp("%s: calling HMAC_CTX_free\n", __func__);
++ HMAC_CTX_free(mapping->ctx.hmac);
++ break;
++ case ctx_type_md:
++ dbgp("%s: calling EVP_MD_CTX_free\n", __func__);
++ EVP_MD_CTX_free(mapping->ctx.md);
++ break;
++#else
+ case ctx_type_hmac:
+ dbgp("%s: calling HMAC_CTX_cleanup\n", __func__);
+ HMAC_CTX_cleanup(&mapping->ctx.hmac);
+@@ -71,6 +89,7 @@ static void remove_mapping(__u32 ses)
+ dbgp("%s: calling EVP_MD_CTX_cleanup\n", __func__);
+ EVP_MD_CTX_cleanup(&mapping->ctx.md);
+ break;
++#endif
+ }
+ memset(mapping, 0, sizeof(*mapping));
+ }
+@@ -127,10 +146,17 @@ static int openssl_hmac(struct session_op *sess, struct crypt_op *cop)
+
+ mapping->ses = sess->ses;
+ mapping->type = ctx_type_hmac;
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++ ctx = mapping->ctx.hmac;
++
++ dbgp("calling HMAC_CTX_new");
++ ctx = HMAC_CTX_new();
++#else
+ ctx = &mapping->ctx.hmac;
+
+ dbgp("calling HMAC_CTX_init");
+ HMAC_CTX_init(ctx);
++#endif
+ dbgp("calling HMAC_Init_ex");
+ if (!HMAC_Init_ex(ctx, sess->mackey, sess->mackeylen,
+ sess_to_evp_md(sess), NULL)) {
+@@ -172,10 +198,17 @@ static int openssl_md(struct session_op *sess, struct crypt_op *cop)
+
+ mapping->ses = sess->ses;
+ mapping->type = ctx_type_md;
++#if OPENSSL_VERSION_NUMBER >= 0x10100000L
++ ctx = mapping->ctx.md;
++
++ dbgp("calling EVP_MD_CTX_new");
++ ctx = EVP_MD_CTX_new();
++#else
+ ctx = &mapping->ctx.md;
+
+ dbgp("calling EVP_MD_CTX_init");
+ EVP_MD_CTX_init(ctx);
++#endif
+ dbgp("calling EVP_DigestInit");
+ EVP_DigestInit(ctx, sess_to_evp_md(sess));
+ }
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch b/poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch
new file mode 100644
index 000000000..f557b5dff
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0001-refactoring-split-big-function-to-simplify-maintaina.patch
@@ -0,0 +1,250 @@
+From 20dcf071bc3076ee7db9d603cfbe6a06e86c7d5f Mon Sep 17 00:00:00 2001
+From: Cristian Stoica <cristian.stoica@nxp.com>
+Date: Thu, 4 May 2017 15:06:20 +0300
+Subject: [PATCH 1/3] refactoring: split big function to simplify maintainance
+
+The setup of auth_buf in tls and aead is now duplicated but this
+is temporary and allows necessary corrections for the aead case
+with v4.2+ kernels.
+
+Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
+
+Upstream-Status: Backport
+
+Commit ID: 20dcf071bc3076ee7db9d603c
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ authenc.c | 197 ++++++++++++++++++++++++++++++++++++++++----------------------
+ 1 file changed, 126 insertions(+), 71 deletions(-)
+
+diff --git a/authenc.c b/authenc.c
+index 1bd7377..28eb0f9 100644
+--- a/authenc.c
++++ b/authenc.c
+@@ -609,96 +609,151 @@ auth_n_crypt(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop,
+ return 0;
+ }
+
+-/* This is the main crypto function - zero-copy edition */
+-static int
+-__crypto_auth_run_zc(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++static int crypto_auth_zc_srtp(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
+ {
+- struct scatterlist *dst_sg, *auth_sg, *src_sg;
++ struct scatterlist *dst_sg, *auth_sg;
+ struct crypt_auth_op *caop = &kcaop->caop;
+- int ret = 0;
++ int ret;
+
+- if (caop->flags & COP_FLAG_AEAD_SRTP_TYPE) {
+- if (unlikely(ses_ptr->cdata.init != 0 &&
+- (ses_ptr->cdata.stream == 0 ||
+- ses_ptr->cdata.aead != 0))) {
+- derr(0, "Only stream modes are allowed in SRTP mode (but not AEAD)");
+- return -EINVAL;
+- }
++ if (unlikely(ses_ptr->cdata.init != 0 &&
++ (ses_ptr->cdata.stream == 0 || ses_ptr->cdata.aead != 0))) {
++ derr(0, "Only stream modes are allowed in SRTP mode (but not AEAD)");
++ return -EINVAL;
++ }
+
+- ret = get_userbuf_srtp(ses_ptr, kcaop, &auth_sg, &dst_sg);
+- if (unlikely(ret)) {
+- derr(1, "get_userbuf_srtp(): Error getting user pages.");
+- return ret;
+- }
++ ret = get_userbuf_srtp(ses_ptr, kcaop, &auth_sg, &dst_sg);
++ if (unlikely(ret)) {
++ derr(1, "get_userbuf_srtp(): Error getting user pages.");
++ return ret;
++ }
+
+- ret = srtp_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+- dst_sg, caop->len);
++ ret = srtp_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
++ dst_sg, caop->len);
+
+- release_user_pages(ses_ptr);
+- } else { /* TLS and normal cases. Here auth data are usually small
+- * so we just copy them to a free page, instead of trying
+- * to map them.
+- */
+- unsigned char *auth_buf = NULL;
+- struct scatterlist tmp;
++ release_user_pages(ses_ptr);
+
+- if (unlikely(caop->auth_len > PAGE_SIZE)) {
+- derr(1, "auth data len is excessive.");
+- return -EINVAL;
+- }
++ return ret;
++}
+
+- auth_buf = (char *)__get_free_page(GFP_KERNEL);
+- if (unlikely(!auth_buf)) {
+- derr(1, "unable to get a free page.");
+- return -ENOMEM;
+- }
++static int crypto_auth_zc_tls(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++{
++ struct crypt_auth_op *caop = &kcaop->caop;
++ struct scatterlist *dst_sg, *auth_sg;
++ unsigned char *auth_buf = NULL;
++ struct scatterlist tmp;
++ int ret;
+
+- if (caop->auth_src && caop->auth_len > 0) {
+- if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
+- derr(1, "unable to copy auth data from userspace.");
+- ret = -EFAULT;
+- goto free_auth_buf;
+- }
++ if (unlikely(ses_ptr->cdata.aead != 0)) {
++ return -EINVAL;
++ }
++
++ if (unlikely(caop->auth_len > PAGE_SIZE)) {
++ derr(1, "auth data len is excessive.");
++ return -EINVAL;
++ }
++
++ auth_buf = (char *)__get_free_page(GFP_KERNEL);
++ if (unlikely(!auth_buf)) {
++ derr(1, "unable to get a free page.");
++ return -ENOMEM;
++ }
+
+- sg_init_one(&tmp, auth_buf, caop->auth_len);
+- auth_sg = &tmp;
+- } else {
+- auth_sg = NULL;
++ if (caop->auth_src && caop->auth_len > 0) {
++ if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
++ derr(1, "unable to copy auth data from userspace.");
++ ret = -EFAULT;
++ goto free_auth_buf;
+ }
+
+- if (caop->flags & COP_FLAG_AEAD_TLS_TYPE && ses_ptr->cdata.aead == 0) {
+- ret = get_userbuf_tls(ses_ptr, kcaop, &dst_sg);
+- if (unlikely(ret)) {
+- derr(1, "get_userbuf_tls(): Error getting user pages.");
+- goto free_auth_buf;
+- }
++ sg_init_one(&tmp, auth_buf, caop->auth_len);
++ auth_sg = &tmp;
++ } else {
++ auth_sg = NULL;
++ }
+
+- ret = tls_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+- dst_sg, caop->len);
+- } else {
+- if (unlikely(ses_ptr->cdata.init == 0 ||
+- (ses_ptr->cdata.stream == 0 &&
+- ses_ptr->cdata.aead == 0))) {
+- derr(0, "Only stream and AEAD ciphers are allowed for authenc");
+- ret = -EINVAL;
+- goto free_auth_buf;
+- }
++ ret = get_userbuf_tls(ses_ptr, kcaop, &dst_sg);
++ if (unlikely(ret)) {
++ derr(1, "get_userbuf_tls(): Error getting user pages.");
++ goto free_auth_buf;
++ }
+
+- ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
+- kcaop->task, kcaop->mm, &src_sg, &dst_sg);
+- if (unlikely(ret)) {
+- derr(1, "get_userbuf(): Error getting user pages.");
+- goto free_auth_buf;
+- }
++ ret = tls_auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
++ dst_sg, caop->len);
++ release_user_pages(ses_ptr);
++
++free_auth_buf:
++ free_page((unsigned long)auth_buf);
++ return ret;
++}
++
++static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++{
++ struct scatterlist *dst_sg, *auth_sg, *src_sg;
++ struct crypt_auth_op *caop = &kcaop->caop;
++ unsigned char *auth_buf = NULL;
++ struct scatterlist tmp;
++ int ret;
+
+- ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+- src_sg, dst_sg, caop->len);
++ if (unlikely(ses_ptr->cdata.init == 0 ||
++ (ses_ptr->cdata.stream == 0 && ses_ptr->cdata.aead == 0))) {
++ derr(0, "Only stream and AEAD ciphers are allowed for authenc");
++ return -EINVAL;
++ }
++
++ if (unlikely(caop->auth_len > PAGE_SIZE)) {
++ derr(1, "auth data len is excessive.");
++ return -EINVAL;
++ }
++
++ auth_buf = (char *)__get_free_page(GFP_KERNEL);
++ if (unlikely(!auth_buf)) {
++ derr(1, "unable to get a free page.");
++ return -ENOMEM;
++ }
++
++ if (caop->auth_src && caop->auth_len > 0) {
++ if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
++ derr(1, "unable to copy auth data from userspace.");
++ ret = -EFAULT;
++ goto free_auth_buf;
+ }
+
+- release_user_pages(ses_ptr);
++ sg_init_one(&tmp, auth_buf, caop->auth_len);
++ auth_sg = &tmp;
++ } else {
++ auth_sg = NULL;
++ }
++
++ ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
++ kcaop->task, kcaop->mm, &src_sg, &dst_sg);
++ if (unlikely(ret)) {
++ derr(1, "get_userbuf(): Error getting user pages.");
++ goto free_auth_buf;
++ }
++
++ ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
++ src_sg, dst_sg, caop->len);
++
++ release_user_pages(ses_ptr);
+
+ free_auth_buf:
+- free_page((unsigned long)auth_buf);
++ free_page((unsigned long)auth_buf);
++
++ return ret;
++}
++
++static int
++__crypto_auth_run_zc(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
++{
++ struct crypt_auth_op *caop = &kcaop->caop;
++ int ret;
++
++ if (caop->flags & COP_FLAG_AEAD_SRTP_TYPE) {
++ ret = crypto_auth_zc_srtp(ses_ptr, kcaop);
++ } else if (caop->flags & COP_FLAG_AEAD_TLS_TYPE) {
++ ret = crypto_auth_zc_tls(ses_ptr, kcaop);
++ } else {
++ ret = crypto_auth_zc_aead(ses_ptr, kcaop);
+ }
+
+ return ret;
+--
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch b/poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch
new file mode 100644
index 000000000..83d9005a0
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0002-refactoring-relocate-code-to-simplify-later-patches.patch
@@ -0,0 +1,64 @@
+From c2bf0e42b1d9fda60cde4a3a682784d349ef1c0b Mon Sep 17 00:00:00 2001
+From: Cristian Stoica <cristian.stoica@nxp.com>
+Date: Thu, 4 May 2017 15:06:21 +0300
+Subject: [PATCH 2/3] refactoring: relocate code to simplify later patches
+
+This code move will simplify the conversion to new AEAD interface in
+next patches
+
+Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
+
+Upstream-Status: Backport
+
+Commit ID: c2bf0e42b1d9fda
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ authenc.c | 17 +++++++++--------
+ 1 file changed, 9 insertions(+), 8 deletions(-)
+
+diff --git a/authenc.c b/authenc.c
+index 28eb0f9..95727b4 100644
+--- a/authenc.c
++++ b/authenc.c
+@@ -711,11 +711,18 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ return -ENOMEM;
+ }
+
++ ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
++ kcaop->task, kcaop->mm, &src_sg, &dst_sg);
++ if (unlikely(ret)) {
++ derr(1, "get_userbuf(): Error getting user pages.");
++ goto free_auth_buf;
++ }
++
+ if (caop->auth_src && caop->auth_len > 0) {
+ if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
+ derr(1, "unable to copy auth data from userspace.");
+ ret = -EFAULT;
+- goto free_auth_buf;
++ goto free_pages;
+ }
+
+ sg_init_one(&tmp, auth_buf, caop->auth_len);
+@@ -724,16 +731,10 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ auth_sg = NULL;
+ }
+
+- ret = get_userbuf(ses_ptr, caop->src, caop->len, caop->dst, kcaop->dst_len,
+- kcaop->task, kcaop->mm, &src_sg, &dst_sg);
+- if (unlikely(ret)) {
+- derr(1, "get_userbuf(): Error getting user pages.");
+- goto free_auth_buf;
+- }
+-
+ ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+ src_sg, dst_sg, caop->len);
+
++free_pages:
+ release_user_pages(ses_ptr);
+
+ free_auth_buf:
+--
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch b/poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch
new file mode 100644
index 000000000..860230778
--- /dev/null
+++ b/poky/meta/recipes-kernel/cryptodev/files/0003-convert-to-new-AEAD-interface-in-kernels-v4.2.patch
@@ -0,0 +1,102 @@
+From a705360197260d28535746ae98c461ba2cfb7a9e Mon Sep 17 00:00:00 2001
+From: Cristian Stoica <cristian.stoica@nxp.com>
+Date: Thu, 4 May 2017 15:06:22 +0300
+Subject: [PATCH 3/3] convert to new AEAD interface in kernels v4.2+
+
+The crypto API for AEAD ciphers changed in recent kernels so that
+associated data is now part of both source and destination scatter
+gathers. The source, destination and associated data buffers need
+to be stiched accordingly for the operations to succeed:
+
+src_sg: auth_buf + src_buf
+dst_sg: auth_buf + (dst_buf + tag space)
+
+This patch fixes a kernel crash observed with cipher-gcm test.
+
+See also kernel patch: 81c4c35eb61a69c229871c490b011c1171511d5a
+ crypto: ccm - Convert to new AEAD interface
+
+Reported-by: Phil Sutter <phil@nwl.cc>
+Signed-off-by: Cristian Stoica <cristian.stoica@nxp.com>
+
+Upstream-Status: Backport
+
+Commit ID: a705360197260d2853574
+
+Signed-off-by: Hongzhi.Song <hongzhi.song@windriver.com>
+---
+ authenc.c | 40 ++++++++++++++++++++++++++++++++++++++--
+ 1 file changed, 38 insertions(+), 2 deletions(-)
+
+diff --git a/authenc.c b/authenc.c
+index 95727b4..692951f 100644
+--- a/authenc.c
++++ b/authenc.c
+@@ -688,12 +688,20 @@ free_auth_buf:
+
+ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_auth_op *kcaop)
+ {
+- struct scatterlist *dst_sg, *auth_sg, *src_sg;
++ struct scatterlist *dst_sg;
++ struct scatterlist *src_sg;
+ struct crypt_auth_op *caop = &kcaop->caop;
+ unsigned char *auth_buf = NULL;
+- struct scatterlist tmp;
+ int ret;
+
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 2, 0))
++ struct scatterlist tmp;
++ struct scatterlist *auth_sg;
++#else
++ struct scatterlist auth1[2];
++ struct scatterlist auth2[2];
++#endif
++
+ if (unlikely(ses_ptr->cdata.init == 0 ||
+ (ses_ptr->cdata.stream == 0 && ses_ptr->cdata.aead == 0))) {
+ derr(0, "Only stream and AEAD ciphers are allowed for authenc");
+@@ -718,6 +726,7 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+ goto free_auth_buf;
+ }
+
++#if (LINUX_VERSION_CODE < KERNEL_VERSION(4, 2, 0))
+ if (caop->auth_src && caop->auth_len > 0) {
+ if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
+ derr(1, "unable to copy auth data from userspace.");
+@@ -733,6 +742,33 @@ static int crypto_auth_zc_aead(struct csession *ses_ptr, struct kernel_crypt_aut
+
+ ret = auth_n_crypt(ses_ptr, kcaop, auth_sg, caop->auth_len,
+ src_sg, dst_sg, caop->len);
++#else
++ if (caop->auth_src && caop->auth_len > 0) {
++ if (unlikely(copy_from_user(auth_buf, caop->auth_src, caop->auth_len))) {
++ derr(1, "unable to copy auth data from userspace.");
++ ret = -EFAULT;
++ goto free_pages;
++ }
++
++ sg_init_table(auth1, 2);
++ sg_set_buf(auth1, auth_buf, caop->auth_len);
++ sg_chain(auth1, 2, src_sg);
++
++ if (src_sg == dst_sg) {
++ src_sg = auth1;
++ dst_sg = auth1;
++ } else {
++ sg_init_table(auth2, 2);
++ sg_set_buf(auth2, auth_buf, caop->auth_len);
++ sg_chain(auth2, 2, dst_sg);
++ src_sg = auth1;
++ dst_sg = auth2;
++ }
++ }
++
++ ret = auth_n_crypt(ses_ptr, kcaop, NULL, caop->auth_len,
++ src_sg, dst_sg, caop->len);
++#endif
+
+ free_pages:
+ release_user_pages(ses_ptr);
+--
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/dtc/dtc.inc b/poky/meta/recipes-kernel/dtc/dtc.inc
index 9a90d4404..7a923bf52 100644
--- a/poky/meta/recipes-kernel/dtc/dtc.inc
+++ b/poky/meta/recipes-kernel/dtc/dtc.inc
@@ -7,7 +7,6 @@ DEPENDS = "flex-native bison-native"
SRC_URI = "git://git.kernel.org/pub/scm/utils/dtc/dtc.git \
file://make_install.patch \
- file://0001-checks-Use-proper-format-modifier-for-size_t.patch \
"
UPSTREAM_CHECK_GITTAGREGEX = "v(?P<pver>\d+(\.\d+)+)"
diff --git a/poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch b/poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch
deleted file mode 100644
index cab384dd9..000000000
--- a/poky/meta/recipes-kernel/dtc/dtc/0001-checks-Use-proper-format-modifier-for-size_t.patch
+++ /dev/null
@@ -1,43 +0,0 @@
-From c7a4c3817796107bb824a1f173faf90fae45396b Mon Sep 17 00:00:00 2001
-From: Thierry Reding <treding@nvidia.com>
-Date: Wed, 27 Sep 2017 15:04:09 +0200
-Subject: [PATCH] checks: Use proper format modifier for size_t
-
-The size of size_t can vary between architectures, so using %ld isn't
-going to work on 32-bit builds. Use the %zu modifier to make sure it is
-always correct.
-
-Upstream-Status: Backport
-Signed-off-by: Thierry Reding <treding@nvidia.com>
-Acked-by: Rob Herring <robh@kernel.org>
-Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- checks.c | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/checks.c b/checks.c
-index 902f2e3..08a3a29 100644
---- a/checks.c
-+++ b/checks.c
-@@ -972,7 +972,7 @@ static void check_property_phandle_args(struct check *c,
- int cell, cellsize = 0;
-
- if (prop->val.len % sizeof(cell_t)) {
-- FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %ld in node %s",
-+ FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %zu in node %s",
- prop->name, prop->val.len, sizeof(cell_t), node->fullpath);
- return;
- }
-@@ -1163,7 +1163,7 @@ static void check_interrupts_property(struct check *c,
- return;
-
- if (irq_prop->val.len % sizeof(cell_t))
-- FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %ld in node %s",
-+ FAIL(c, dti, "property '%s' size (%d) is invalid, expected multiple of %zu in node %s",
- irq_prop->name, irq_prop->val.len, sizeof(cell_t),
- node->fullpath);
-
---
-2.15.0
-
diff --git a/poky/meta/recipes-kernel/dtc/dtc/make_install.patch b/poky/meta/recipes-kernel/dtc/dtc/make_install.patch
index ccf17b38f..ea9359e81 100644
--- a/poky/meta/recipes-kernel/dtc/dtc/make_install.patch
+++ b/poky/meta/recipes-kernel/dtc/dtc/make_install.patch
@@ -1,17 +1,26 @@
+From e9852b9d206df1e42aa4c8afec55a0f5e099b533 Mon Sep 17 00:00:00 2001
+From: Saul Wold <sgw@linux.intel.com>
+Date: Thu, 3 Nov 2011 08:35:47 -0700
+Subject: [PATCH] dtc: Add patch to correctly install shared libraries and
+
Upstream-Status: Inappropriate [configuration]
-Index: git/Makefile
-===================================================================
---- git.orig/Makefile
-+++ git/Makefile
-@@ -168,8 +168,8 @@ install-bin: all $(SCRIPTS)
+---
+ Makefile | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/Makefile b/Makefile
+index d8ebc4f..f5e01be 100644
+--- a/Makefile
++++ b/Makefile
+@@ -205,8 +205,8 @@ install-bin: all $(SCRIPTS)
install-lib: all
@$(VECHO) INSTALL-LIB
$(INSTALL) -d $(DESTDIR)$(LIBDIR)
-- $(INSTALL) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)
+- $(INSTALL_LIB) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)
- ln -sf $(notdir $(LIBFDT_lib)) $(DESTDIR)$(LIBDIR)/$(LIBFDT_soname)
+ $(INSTALL) $(LIBFDT_lib) $(DESTDIR)$(LIBDIR)/$(LIBFDT_soname)
+ ln -sf $(LIBFDT_soname) $(DESTDIR)$(LIBDIR)/$(notdir $(LIBFDT_lib))
ln -sf $(LIBFDT_soname) $(DESTDIR)$(LIBDIR)/libfdt.$(SHAREDLIB_EXT)
- $(INSTALL) -m 644 $(LIBFDT_archive) $(DESTDIR)$(LIBDIR)
+ $(INSTALL_DATA) $(LIBFDT_archive) $(DESTDIR)$(LIBDIR)
diff --git a/poky/meta/recipes-kernel/dtc/dtc_1.4.5.bb b/poky/meta/recipes-kernel/dtc/dtc_1.4.7.bb
index 0e46cfbeb..6ce462a7f 100644
--- a/poky/meta/recipes-kernel/dtc/dtc_1.4.5.bb
+++ b/poky/meta/recipes-kernel/dtc/dtc_1.4.7.bb
@@ -3,7 +3,7 @@ require dtc.inc
LIC_FILES_CHKSUM = "file://GPL;md5=94d55d512a9ba36caa9b7df079bae19f \
file://libfdt/libfdt.h;beginline=3;endline=52;md5=fb360963151f8ec2d6c06b055bcbb68c"
-SRCREV = "22a65c5331c22979d416738eb756b9541672e00d"
+SRCREV = "88f18909db731a627456f26d779445f84e449536"
S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb b/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
index 4ccf9b07f..b353c21df 100644
--- a/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
+++ b/poky/meta/recipes-kernel/kern-tools/kern-tools-native_git.bb
@@ -4,7 +4,7 @@ LIC_FILES_CHKSUM = "file://git/tools/kgit;beginline=5;endline=9;md5=a6c2fa8aef1b
DEPENDS = "git-native"
-SRCREV = "8cd13500a27c0a6a911cc83c0349dec01ef66e27"
+SRCREV = "d6529f86fc5bcb3514953ff9fa2f51a3fbf03a0f"
PR = "r12"
PV = "0.2+git${SRCPV}"
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch b/poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch
new file mode 100644
index 000000000..e0cced55c
--- /dev/null
+++ b/poky/meta/recipes-kernel/kexec/kexec-tools/0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch
@@ -0,0 +1,41 @@
+From b9de21ef51a7ceab7122a707c188602eae22c4ee Mon Sep 17 00:00:00 2001
+From: Chris Clayton <chris2553@googlemail.com>
+Date: Mon, 20 Aug 2018 12:00:31 +0100
+Subject: [PATCH] kexec: fix for "Unhandled rela relocation: R_X86_64_PLT32" error
+
+In response to a change in binutils, commit b21ebf2fb4c
+(x86: Treat R_X86_64_PLT32 as R_X86_64_PC32) was applied to
+the linux kernel during the 4.16 development cycle and has
+since been backported to earlier stable kernel series. The
+change results in the failure message in $SUBJECT when
+rebooting via kexec.
+
+Fix this by replicating the change in kexec.
+
+Upstream-Status: Backport[https://git.kernel.org/pub/scm/utils/kernel/kexec/kexec-tools.git/commit/?id=b9de21ef51a7ceab7122a707c188602eae22c4ee]
+
+Signed-off-by: Chris Clayton <chris2553@googlemail.com>
+Acked-by: Baoquan He <bhe@redhat.com>
+Tested-by: Bhupesh Sharma <bhsharma@redhat.com>
+Acked-by: Bhupesh Sharma <bhsharma@redhat.com>
+Signed-off-by: Simon Horman <horms@verge.net.au>
+Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
+---
+ kexec/arch/x86_64/kexec-elf-rel-x86_64.c | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+index 7fdde73..db85b44 100644
+--- a/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
++++ b/kexec/arch/x86_64/kexec-elf-rel-x86_64.c
+@@ -79,6 +79,7 @@ void machine_apply_elf_rel(struct mem_ehdr *UNUSED(ehdr),
+ goto overflow;
+ break;
+ case R_X86_64_PC32:
++ case R_X86_64_PLT32:
+ *(uint32_t *)location = value - address;
+ break;
+ default:
+--
+2.7.4
+
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service b/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service
index 013c5a62b..b4a2c0611 100644
--- a/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service
+++ b/poky/meta/recipes-kernel/kexec/kexec-tools/kdump.service
@@ -1,7 +1,8 @@
[Unit]
Description=Reboot and dump vmcore via kexec
DefaultDependencies=no
-After=basic.target
+Requires=sysinit.target
+After=sysinit.target
[Service]
Type=oneshot
diff --git a/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.16.bb b/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.17.bb
index ebb483268..4b9b5accb 100644
--- a/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.16.bb
+++ b/poky/meta/recipes-kernel/kexec/kexec-tools_2.0.17.bb
@@ -9,8 +9,6 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=ea5bed2f60d357618ca161ad539f7c0a \
file://kexec/kexec.c;beginline=1;endline=20;md5=af10f6ae4a8715965e648aa687ad3e09"
DEPENDS = "zlib xz"
-PR = "r1"
-
SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz \
file://kdump \
file://kdump.conf \
@@ -20,10 +18,11 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/kernel/kexec/kexec-tools-${PV}.tar.gz
file://0010-kexec-ARM-Fix-add_buffer_phys_virt-align-issue.patch \
file://kexec-x32.patch \
file://0001-Disable-PIE-during-link.patch \
- "
+ file://0001-kexec-fix-for-Unhandled-rela-relocation-R_X86_64_PLT.patch \
+ "
-SRC_URI[md5sum] = "5198968de79b5ded96f97f3c2ea9637b"
-SRC_URI[sha256sum] = "cf17fc99bf77c9b39f06ee88ac0e86d0349c4a0c3f8214a3cc78eece872f6f3a"
+SRC_URI[md5sum] = "8e071ca473694a71e4ae60ed7ef6f377"
+SRC_URI[sha256sum] = "450c87ba048641eb05f9717f5567aca57f063c266149ae663b58a34e5852deaf"
inherit autotools update-rc.d systemd
@@ -79,6 +78,9 @@ INITSCRIPT_PACKAGES = "kdump"
INITSCRIPT_NAME_kdump = "kdump"
INITSCRIPT_PARAMS_kdump = "start 56 2 3 4 5 . stop 56 0 1 6 ."
+SYSTEMD_PACKAGES = "kdump"
+SYSTEMD_SERVICE_kdump = "kdump.service"
+
SECURITY_PIE_CFLAGS_remove = "-fPIE -pie"
COMPATIBLE_HOST = '(x86_64.*|i.86.*|arm.*|aarch64.*|powerpc.*|mips.*)-(linux|freebsd.*)'
diff --git a/poky/meta/recipes-kernel/kmod/kmod_git.bb b/poky/meta/recipes-kernel/kmod/kmod_git.bb
index 69185b245..bd21d2ff7 100644
--- a/poky/meta/recipes-kernel/kmod/kmod_git.bb
+++ b/poky/meta/recipes-kernel/kmod/kmod_git.bb
@@ -13,9 +13,7 @@ RREPLACES_${PN} += "module-init-tools-insmod-static module-init-tools-depmod mod
RCONFLICTS_libkmod2 += "module-init-tools-insmod-static module-init-tools-depmod module-init-tools"
# autotools set prefix to /usr, however we want them in /bin and /sbin
-bindir = "${base_bindir}"
-sbindir = "${base_sbindir}"
-# libdir = "${base_libdir}"
+EXTRA_OECONF += " --bindir=${base_bindir} --sbindir=${base_sbindir}"
do_install_append () {
install -dm755 ${D}${base_bindir}
@@ -41,7 +39,7 @@ do_compile_prepend() {
inherit update-alternatives bash-completion
-ALTERNATIVE_PRIORITY = "60"
+ALTERNATIVE_PRIORITY = "70"
ALTERNATIVE_kmod = "insmod modprobe rmmod modinfo bin-lsmod lsmod depmod"
diff --git a/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb b/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb
index cf7abb0f9..2525545bd 100644
--- a/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb
+++ b/poky/meta/recipes-kernel/linux-firmware/linux-firmware_git.bb
@@ -66,12 +66,13 @@ LIC_FILES_CHKSUM = "\
file://LICENCE.Abilis;md5=b5ee3f410780e56711ad48eadc22b8bc \
file://LICENCE.adsp_sst;md5=615c45b91a5a4a9fe046d6ab9a2df728 \
file://LICENCE.agere;md5=af0133de6b4a9b2522defd5f188afd31 \
- file://LICENSE.amdgpu;md5=0aa3c2f3e736af320a08a3aeeccecf29 \
+ file://LICENSE.amdgpu;md5=88b865bc74f3ffcc54640b4ea8540b46 \
file://LICENSE.amd-ucode;md5=3c5399dc9148d7f0e1f41e34b69cf14f \
file://LICENCE.atheros_firmware;md5=30a14c7823beedac9fa39c64fdd01a13 \
file://LICENSE.atmel;md5=aa74ac0c60595dee4d4e239107ea77a3 \
file://LICENCE.broadcom_bcm43xx;md5=3160c14df7228891b868060e1951dfbc \
file://LICENCE.ca0132;md5=209b33e66ee5be0461f13d31da392198 \
+ file://LICENCE.cadence;md5=009f46816f6956cfb75ede13d3e1cee0 \
file://LICENCE.cavium;md5=c37aaffb1ebe5939b2580d073a95daea \
file://LICENCE.chelsio_firmware;md5=819aa8c3fa453f1b258ed8d168a9d903 \
file://LICENCE.cw1200;md5=f0f770864e7a8444a5c5aa9d12a3a7ed \
@@ -91,6 +92,7 @@ LIC_FILES_CHKSUM = "\
file://LICENCE.iwlwifi_firmware;md5=3fd842911ea93c29cd32679aa23e1c88 \
file://LICENCE.kaweth;md5=b1d876e562f4b3b8d391ad8395dfe03f \
file://LICENCE.Marvell;md5=9ddea1734a4baf3c78d845151f42a37a \
+ file://LICENCE.mediatek;md5=7c1976b63217d76ce47d0a11d8a79cf2 \
file://LICENCE.moxa;md5=1086614767d8ccf744a923289d3d4261 \
file://LICENCE.myri10ge_firmware;md5=42e32fb89f6b959ca222e25ac8df8fed \
file://LICENCE.Netronome;md5=4add08f2577086d44447996503cddf5f \
@@ -120,7 +122,7 @@ LIC_FILES_CHKSUM = "\
file://LICENCE.xc4000;md5=0ff51d2dc49fce04814c9155081092f0 \
file://LICENCE.xc5000;md5=1e170c13175323c32c7f4d0998d53f66 \
file://LICENCE.xc5000c;md5=12b02efa3049db65d524aeb418dd87ca \
- file://WHENCE;md5=eaaf310bac02fee05ea1b334f58c5caf \
+ file://WHENCE;md5=36ef3e9887bb8b38ff265c602de6740e \
"
# These are not common licenses, set NO_GENERIC_LICENSE for them
@@ -134,6 +136,7 @@ NO_GENERIC_LICENSE[Firmware-atheros_firmware] = "LICENCE.atheros_firmware"
NO_GENERIC_LICENSE[Firmware-atmel] = "LICENSE.atmel"
NO_GENERIC_LICENSE[Firmware-broadcom_bcm43xx] = "LICENCE.broadcom_bcm43xx"
NO_GENERIC_LICENSE[Firmware-ca0132] = "LICENCE.ca0132"
+NO_GENERIC_LICENSE[Firmware-cadence] = "LICENCE.cadence"
NO_GENERIC_LICENSE[Firmware-cavium] = "LICENCE.cavium"
NO_GENERIC_LICENSE[Firmware-chelsio_firmware] = "LICENCE.chelsio_firmware"
NO_GENERIC_LICENSE[Firmware-cw1200] = "LICENCE.cw1200"
@@ -153,6 +156,7 @@ NO_GENERIC_LICENSE[Firmware-it913x] = "LICENCE.it913x"
NO_GENERIC_LICENSE[Firmware-iwlwifi_firmware] = "LICENCE.iwlwifi_firmware"
NO_GENERIC_LICENSE[Firmware-kaweth] = "LICENCE.kaweth"
NO_GENERIC_LICENSE[Firmware-Marvell] = "LICENCE.Marvell"
+NO_GENERIC_LICENSE[Firmware-mediatek] = "LICENCE.mediatek"
NO_GENERIC_LICENSE[Firmware-moxa] = "LICENCE.moxa"
NO_GENERIC_LICENSE[Firmware-myri10ge_firmware] = "LICENCE.myri10ge_firmware"
NO_GENERIC_LICENSE[Firmware-netronome] = "LICENCE.Netronome"
@@ -184,7 +188,7 @@ NO_GENERIC_LICENSE[Firmware-xc5000] = "LICENCE.xc5000"
NO_GENERIC_LICENSE[Firmware-xc5000c] = "LICENCE.xc5000c"
NO_GENERIC_LICENSE[WHENCE] = "WHENCE"
-SRCREV = "d1147327232ec4616a66ab898df84f9700c816c1"
+SRCREV = "44d4fca9922a252a0bd81f6307bcc072a78da54a"
PE = "1"
PV = "0.0+git${SRCPV}"
@@ -232,6 +236,7 @@ PACKAGES =+ "${PN}-ralink-license ${PN}-ralink \
${PN}-radeon-license ${PN}-radeon \
${PN}-marvell-license ${PN}-pcie8897 ${PN}-pcie8997 \
${PN}-sd8686 ${PN}-sd8688 ${PN}-sd8787 ${PN}-sd8797 ${PN}-sd8801 ${PN}-sd8887 ${PN}-sd8897 \
+ ${PN}-usb8997 \
${PN}-ti-connectivity-license ${PN}-wl12xx ${PN}-wl18xx \
${PN}-vt6656-license ${PN}-vt6656 \
${PN}-rtl-license ${PN}-rtl8188 ${PN}-rtl8192cu ${PN}-rtl8192ce ${PN}-rtl8192su ${PN}-rtl8723 ${PN}-rtl8821 \
@@ -409,6 +414,7 @@ LICENSE_${PN}-sd8797 = "Firmware-Marvell"
LICENSE_${PN}-sd8801 = "Firmware-Marvell"
LICENSE_${PN}-sd8887 = "Firmware-Marvell"
LICENSE_${PN}-sd8897 = "Firmware-Marvell"
+LICENSE_${PN}-usb8997 = "Firmware-Marvell"
LICENSE_${PN}-marvell-license = "Firmware-Marvell"
FILES_${PN}-marvell-license = "${nonarch_base_libdir}/firmware/LICENCE.Marvell"
@@ -443,6 +449,9 @@ FILES_${PN}-sd8887 = " \
FILES_${PN}-sd8897 = " \
${nonarch_base_libdir}/firmware/mrvl/sd8897_uapsta.bin \
"
+FILES_${PN}-usb8997 = " \
+ ${nonarch_base_libdir}/firmware/mrvl/usbusb8997_combo_v4.bin \
+"
RDEPENDS_${PN}-sd8686 += "${PN}-marvell-license"
RDEPENDS_${PN}-sd8688 += "${PN}-marvell-license"
@@ -451,6 +460,7 @@ RDEPENDS_${PN}-sd8797 += "${PN}-marvell-license"
RDEPENDS_${PN}-sd8801 += "${PN}-marvell-license"
RDEPENDS_${PN}-sd8887 += "${PN}-marvell-license"
RDEPENDS_${PN}-sd8897 += "${PN}-marvell-license"
+RDEPENDS_${PN}-usb8997 += "${PN}-marvell-license"
# For netronome
LICENSE_${PN}-netronome = "Firmware-netronome"
@@ -801,9 +811,9 @@ LICENSE_${PN}-ibt-misc = "Firmware-ibt_firmware"
FILES_${PN}-ibt-license = "${nonarch_base_libdir}/firmware/LICENCE.ibt_firmware"
FILES_${PN}-ibt-hw-37-7 = "${nonarch_base_libdir}/firmware/intel/ibt-hw-37.7*.bseq"
FILES_${PN}-ibt-hw-37-8 = "${nonarch_base_libdir}/firmware/intel/ibt-hw-37.8*.bseq"
-FILES_${PN}-ibt-11-5 = "${nonarch_base_libdir}/firmware/intel/ibt-11-5.sfi /lib/firmware/intel/ibt-11-5.ddc"
-FILES_${PN}-ibt-12-16 = "${nonarch_base_libdir}/firmware/intel/ibt-12-16.sfi /lib/firmware/intel/ibt-12-16.ddc"
-FILES_${PN}-ibt-17 = "${nonarch_base_libdir}/firmware/intel/ibt-17-*.sfi /lib/firmware/intel/ibt-17-*.ddc"
+FILES_${PN}-ibt-11-5 = "${nonarch_base_libdir}/firmware/intel/ibt-11-5.sfi ${nonarch_base_libdir}/firmware/intel/ibt-11-5.ddc"
+FILES_${PN}-ibt-12-16 = "${nonarch_base_libdir}/firmware/intel/ibt-12-16.sfi ${nonarch_base_libdir}/firmware/intel/ibt-12-16.ddc"
+FILES_${PN}-ibt-17 = "${nonarch_base_libdir}/firmware/intel/ibt-17-*.sfi ${nonarch_base_libdir}/firmware/intel/ibt-17-*.ddc"
FILES_${PN}-ibt-misc = "${nonarch_base_libdir}/firmware/ibt-*"
RDEPENDS_${PN}-ibt-hw-37-7 = "${PN}-ibt-license"
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc
index b5cf96dd4..be215af9b 100644
--- a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc
+++ b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers.inc
@@ -30,7 +30,7 @@ LICENSE = "GPLv2"
#
# -- RP
-LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
python __anonymous () {
major = d.getVar("PV").split('.')[0]
@@ -53,12 +53,9 @@ S = "${WORKDIR}/linux-${PV}"
EXTRA_OEMAKE = " HOSTCC="${BUILD_CC}" HOSTCPP="${BUILD_CPP}""
-do_configure() {
- oe_runmake allnoconfig
-}
+do_configure[noexec] = "1"
-do_compile () {
-}
+do_compile[noexec] = "1"
do_install() {
oe_runmake headers_install INSTALL_HDR_PATH=${D}${exec_prefix}
@@ -92,4 +89,4 @@ RDEPENDS_${PN}-dev = ""
RRECOMMENDS_${PN}-dbg = "${PN}-dev (= ${EXTENDPKGV})"
INHIBIT_DEFAULT_DEPS = "1"
-DEPENDS += "unifdef-native"
+DEPENDS += "unifdef-native bison-native"
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch
new file mode 100644
index 000000000..9d17daa70
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers/0001-include-linux-stddef.h-in-swab.h-uapi-header.patch
@@ -0,0 +1,44 @@
+From 9708dc74d9f49488d669e070982f6224a888d61a Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Wed, 12 Sep 2018 17:08:58 -0700
+Subject: [PATCH] include linux/stddef.h in swab.h uapi header
+
+swab.h uses __always_inline without including the header where it is
+defined, this is exposed by musl based distributions where this macro is
+not defined by system C library headers unlike glibc where it is defined
+in sys/cdefs.h and that header gets pulled in indirectly via
+
+features.h -> sys/cdefs.h
+
+and features.h gets pulled in a lot of headers. Therefore it may work in
+cases where features.h is includes but not otherwise.
+
+Adding linux/stddef.h here ensures that __always_inline is always
+defined independent of which C library is used in userspace
+
+Upstream-Status: Submitted [https://lkml.org/lkml/2018/9/13/78]
+
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+Cc: Philippe Ombredanne <pombredanne@nexb.com>
+Cc: Kate Stewart <kstewart@linuxfoundation.org>
+Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Cc: Thomas Gleixner <tglx@linutronix.de>
+---
+ include/uapi/linux/swab.h | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/include/uapi/linux/swab.h b/include/uapi/linux/swab.h
+index 23cd84868cc3..acddbe50a20d 100644
+--- a/include/uapi/linux/swab.h
++++ b/include/uapi/linux/swab.h
+@@ -3,6 +3,7 @@
+ #define _UAPI_LINUX_SWAB_H
+
+ #include <linux/types.h>
++#include <linux/stddef.h>
+ #include <linux/compiler.h>
+ #include <asm/swab.h>
+
+--
+2.19.0
+
diff --git a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.15.7.bb b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.18.bb
index a7db4c9c0..eb7bee72b 100644
--- a/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.15.7.bb
+++ b/poky/meta/recipes-kernel/linux-libc-headers/linux-libc-headers_4.18.bb
@@ -6,8 +6,8 @@ SRC_URI_append_libc-musl = "\
file://0003-remove-inclusion-of-sysinfo.h-in-kernel.h.patch \
file://0001-libc-compat.h-musl-_does_-define-IFF_LOWER_UP-DORMAN.patch \
file://0001-if_ether-move-muslc-ethhdr-protection-to-uapi-file.patch \
+ file://0001-include-linux-stddef.h-in-swab.h-uapi-header.patch \
"
-
-SRC_URI[md5sum] = "8186ce63c489199b58b6a58ad2a24a94"
-SRC_URI[sha256sum] = "cd44df4b23a3e0edc14be63df95d768b9600b31c35be05fb89f93226907fc8c6"
+SRC_URI[md5sum] = "bee5fe53ee1c3142b8f0c12c0d3348f9"
+SRC_URI[sha256sum] = "19d8bcf49ef530cd4e364a45b4a22fa70714b70349c8100e7308488e26f1eaf1"
diff --git a/poky/meta/recipes-kernel/linux/kernel-devsrc.bb b/poky/meta/recipes-kernel/linux/kernel-devsrc.bb
index 8bbfa23e4..361ad21e1 100644
--- a/poky/meta/recipes-kernel/linux/kernel-devsrc.bb
+++ b/poky/meta/recipes-kernel/linux/kernel-devsrc.bb
@@ -25,62 +25,214 @@ do_unpack[noexec] = "1"
do_patch[noexec] = "1"
do_configure[noexec] = "1"
do_compile[noexec] = "1"
-do_populate_sysroot[noexec] = "1"
+deltask do_populate_sysroot
S = "${STAGING_KERNEL_DIR}"
B = "${STAGING_KERNEL_BUILDDIR}"
-KERNEL_VERSION = "${@get_kernelversion_headers('${S}')}"
-
PACKAGE_ARCH = "${MACHINE_ARCH}"
+KERNEL_BUILD_ROOT="/lib/modules/"
+
do_install() {
- kerneldir=${D}${KERNEL_SRC_PATH}
- install -d $kerneldir
-
- #
- # Copy the staging dir source (and module build support) into the devsrc structure.
- # We can keep this copy simple and take everything, since a we'll clean up any build
- # artifacts afterwards, and the extra i/o is not significant
- #
- cd ${B}
- find . -type d -name '.git*' -prune -o -path '.debug' -prune -o -type f -print0 | cpio --null -pdlu $kerneldir
- cd ${S}
- find . -type d -name '.git*' -prune -o -type d -name '.kernel-meta' -prune -o -type f -print0 | cpio --null -pdlu $kerneldir
-
- # Explicitly set KBUILD_OUTPUT to ensure that the image directory is cleaned and not
- # The main build artifacts. We clean the directory to avoid QA errors on mismatched
- # architecture (since scripts and helpers are native format).
- KBUILD_OUTPUT="$kerneldir"
- oe_runmake -C $kerneldir CC="${KERNEL_CC}" LD="${KERNEL_LD}" clean _mrproper_scripts
- # make clean generates an absolute path symlink called "source"
- # in $kerneldir points to $kerneldir, which doesn't make any
- # sense, so remove it.
- if [ -L $kerneldir/source ]; then
- bbnote "Removing $kerneldir/source symlink"
- rm -f $kerneldir/source
- fi
-
- # As of Linux kernel version 3.0.1, the clean target removes
- # arch/powerpc/lib/crtsavres.o which is present in
- # KBUILD_LDFLAGS_MODULE, making it required to build external modules.
- if [ ${ARCH} = "powerpc" ]; then
- mkdir -p $kerneldir/arch/powerpc/lib/
- cp ${B}/arch/powerpc/lib/crtsavres.o $kerneldir/arch/powerpc/lib/crtsavres.o
- fi
-
- # Remove fixdep/objtool as they won't be target binaries
- for i in fixdep objtool; do
- if [ -e $kerneldir/tools/objtool/$i ]; then
- rm -rf $kerneldir/tools/objtool/$i
- fi
- done
-
- chown -R root:root ${D}
+ kerneldir=${D}${KERNEL_BUILD_ROOT}${KERNEL_VERSION}
+ install -d $kerneldir
+
+ # create the directory structure
+ rm -f $kerneldir/build
+ rm -f $kerneldir/source
+ mkdir -p $kerneldir/build
+
+ # for compatibility with some older variants of this package, we
+ # create a /usr/src/kernel symlink to /lib/modules/<version>/source
+ mkdir -p ${D}/usr/src
+ (
+ cd ${D}/usr/src
+ ln -s ${KERNEL_BUILD_ROOT}${KERNEL_VERSION}/source kernel
+ )
+
+ # for on target purposes, we unify build and source
+ (
+ cd $kerneldir
+ ln -s build source
+ )
+
+ # first copy everything
+ (
+ cd ${S}
+ cp --parents $(find -type f -name "Makefile*" -o -name "Kconfig*") $kerneldir/build
+ cp --parents $(find -type f -name "Build" -o -name "Build.include") $kerneldir/build
+ )
+
+ # then drop all but the needed Makefiles/Kconfig files
+ rm -rf $kerneldir/build/Documentation
+ rm -rf $kerneldir/build/scripts
+ rm -rf $kerneldir/build/include
+
+ # now copy in parts from the build that we'll need later
+ (
+ cd ${B}
+
+ cp Module.symvers $kerneldir/build
+ cp System.map* $kerneldir/build
+ if [ -s Module.markers ]; then
+ cp Module.markers $kerneldir/build
+ fi
+
+ cp .config $kerneldir/build
+
+ # This scripts copy blow up QA, so for now, we require a more
+ # complex 'make scripts' to restore these, versus copying them
+ # here. Left as a reference to indicate that we know the scripts must
+ # be dealt with.
+ # cp -a scripts $kerneldir/build
+
+ if [ -d arch/${ARCH}/scripts ]; then
+ cp -a arch/${ARCH}/scripts $kerneldir/build/arch/${ARCH}
+ fi
+ if [ -f arch/${ARCH}/*lds ]; then
+ cp -a arch/${ARCH}/*lds $kerneldir/build/arch/${ARCH}
+ fi
+
+ rm -f $kerneldir/build/scripts/*.o
+ rm -f $kerneldir/build/scripts/*/*.o
+
+ if [ "${ARCH}" = "powerpc" ]; then
+ if [ -e arch/powerpc/lib/crtsavres.S ] ||
+ [ -e arch/powerpc/lib/crtsavres.o ]; then
+ cp -a --parents arch/powerpc/lib/crtsavres.[So] $kerneldir/build/
+ fi
+ fi
+
+ if [ "${ARCH}" = "arm64" ]; then
+ cp -a --parents arch/arm64/kernel/vdso/vdso.lds $kerneldir/build/
+ fi
+
+ cp -a include $kerneldir/build/include
+ )
+
+ # now grab the chunks from the source tree that we need
+ (
+ cd ${S}
+
+ cp -a scripts $kerneldir/build
+
+ # if our build dir had objtool, it will also be rebuilt on target, so
+ # we copy what is required for that build
+ if [ -f ${B}/tools/objtool/objtool ]; then
+ # these are a few files associated with objtool, since we'll need to
+ # rebuild it
+ cp -a --parents tools/build/Build.include $kerneldir/build/
+ cp -a --parents tools/build/Build $kerneldir/build/
+ cp -a --parents tools/build/fixdep.c $kerneldir/build/
+ cp -a --parents tools/scripts/utilities.mak $kerneldir/build/
+
+ # extra files, just in case
+ cp -a --parents tools/objtool/* $kerneldir/build/
+ cp -a --parents tools/lib/str_error_r.c $kerneldir/build/
+ cp -a --parents tools/lib/string.c $kerneldir/build/
+ cp -a --parents tools/lib/subcmd/* $kerneldir/build/
+
+ cp -a --parents tools/include/* $kerneldir/build/
+ fi
+
+ if [ "${ARCH}" = "arm64" ]; then
+ # arch/arm64/include/asm/xen references arch/arm
+ cp -a --parents arch/arm/include/asm/xen $kerneldir/build/
+ # arch/arm64/include/asm/opcodes.h references arch/arm
+ cp -a --parents arch/arm/include/asm/opcodes.h $kerneldir/build/
+
+ cp -a --parents arch/arm64/kernel/vdso/gettimeofday.S $kerneldir/build/
+ cp -a --parents arch/arm64/kernel/vdso/sigreturn.S $kerneldir/build/
+ cp -a --parents arch/arm64/kernel/vdso/note.S $kerneldir/build/
+ cp -a --parents arch/arm64/kernel/vdso/gen_vdso_offsets.sh $kerneldir/build/
+
+ cp -a --parents arch/arm64/kernel/module.lds $kerneldir/build/
+ fi
+
+ # include the machine specific headers for ARM variants, if available.
+ if [ "${ARCH}" = "arm" ]; then
+ cp -a --parents arch/${ARCH}/mach-*/include $kerneldir/build/
+
+ # include a few files for 'make prepare'
+ cp -a --parents arch/arm/tools/gen-mach-types $kerneldir/build/
+ cp -a --parents arch/arm/tools/mach-types $kerneldir/build/
+ cp -a --parents arch/arm/tools/syscall* $kerneldir/build/
+
+ cp -a --parents arch/arm/kernel/module.lds $kerneldir/build/
+ fi
+
+ if [ -d arch/${ARCH}/include ]; then
+ cp -a --parents arch/${ARCH}/include $kerneldir/build/
+ fi
+
+ cp -a include $kerneldir/build
+
+ cp -a --parents tools/include/tools/le_byteshift.h $kerneldir/build/
+ cp -a --parents tools/include/tools/be_byteshift.h $kerneldir/build/
+
+ # required for generate missing syscalls prepare phase
+ cp -a --parents arch/x86/entry/syscalls/syscall_32.tbl $kerneldir/build
+
+ if [ "${ARCH}" = "x86" ]; then
+ # files for 'make prepare' to succeed with kernel-devel
+ cp -a --parents arch/x86/entry/syscalls/syscall_32.tbl $kerneldir/build/
+ cp -a --parents arch/x86/entry/syscalls/syscalltbl.sh $kerneldir/build/
+ cp -a --parents arch/x86/entry/syscalls/syscallhdr.sh $kerneldir/build/
+ cp -a --parents arch/x86/entry/syscalls/syscall_64.tbl $kerneldir/build/
+ cp -a --parents arch/x86/tools/relocs_32.c $kerneldir/build/
+ cp -a --parents arch/x86/tools/relocs_64.c $kerneldir/build/
+ cp -a --parents arch/x86/tools/relocs.c $kerneldir/build/
+ cp -a --parents arch/x86/tools/relocs_common.c $kerneldir/build/
+ cp -a --parents arch/x86/tools/relocs.h $kerneldir/build/
+ cp -a --parents arch/x86/purgatory/purgatory.c $kerneldir/build/
+
+ # 4.18 + have unified the purgatory files, so we ignore any errors if
+ # these files are not present
+ cp -a --parents arch/x86/purgatory/sha256.h $kerneldir/build/ 2>/dev/null || :
+ cp -a --parents arch/x86/purgatory/sha256.c $kerneldir/build/ 2>/dev/null || :
+
+ cp -a --parents arch/x86/purgatory/stack.S $kerneldir/build/
+ cp -a --parents arch/x86/purgatory/string.c $kerneldir/build/
+ cp -a --parents arch/x86/purgatory/setup-x86_64.S $kerneldir/build/
+ cp -a --parents arch/x86/purgatory/entry64.S $kerneldir/build/
+ cp -a --parents arch/x86/boot/string.h $kerneldir/build/
+ cp -a --parents arch/x86/boot/string.c $kerneldir/build/
+ cp -a --parents arch/x86/boot/ctype.h $kerneldir/build/
+ fi
+
+ if [ "${ARCH}" = "mips" ]; then
+ cp -a --parents arch/mips/Kbuild.platforms $kerneldir/build/
+ cp --parents $(find -type f -name "Platform") $kerneldir/build
+ cp --parents arch/mips/boot/tools/relocs* $kerneldir/build
+ cp -a --parents arch/mips/kernel/asm-offsets.c $kerneldir/build
+ cp -a --parents kernel/time/timeconst.bc $kerneldir/build
+ cp -a --parents kernel/bounds.c $kerneldir/build
+ cp -a --parents Kbuild $kerneldir/build
+ fi
+
+ # required to build scripts/selinux/genheaders/genheaders
+ cp -a --parents security/selinux/include/* $kerneldir/build/
+ )
+
+ # Make sure the Makefile and version.h have a matching timestamp so that
+ # external modules can be built
+ touch -r $kerneldir/build/Makefile $kerneldir/build/include/generated/uapi/linux/version.h
+
+ # Copy .config to include/config/auto.conf so "make prepare" is unnecessary.
+ cp $kerneldir/build/.config $kerneldir/build/include/config/auto.conf
+
+ chown -R root:root ${D}
}
+
# Ensure we don't race against "make scripts" during cpio
do_install[lockfiles] = "${TMPDIR}/kernel-scripts.lock"
-PACKAGES = "kernel-devsrc"
-FILES_${PN} = "${KERNEL_SRC_PATH}"
-RDEPENDS_${PN} = "bc"
+FILES_${PN} = "${KERNEL_BUILD_ROOT} ${KERNEL_SRC_PATH}"
+FILES_${PN}-dbg += "${KERNEL_BUILD_ROOT}*/build/scripts/*/.debug/*"
+
+RDEPENDS_${PN} = "bc python flex bison ${TCLIBC}-utils"
+# 4.15+ needs these next two RDEPENDS
+RDEPENDS_${PN} += "openssl-dev util-linux"
+# and x86 needs a bit more for 4.15+
+RDEPENDS_${PN} += "${@bb.utils.contains('ARCH', 'x86', 'elfutils', '', d)}"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb b/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb
index 4201faf67..23cb355b5 100644
--- a/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb
+++ b/poky/meta/recipes-kernel/linux/linux-yocto-dev.bb
@@ -10,6 +10,8 @@
inherit kernel
require recipes-kernel/linux/linux-yocto.inc
+# for ncurses tests
+inherit pkgconfig
# provide this .inc to set specific revisions
include recipes-kernel/linux/linux-yocto-dev-revisions.inc
@@ -28,10 +30,12 @@ SRC_URI = "git://git.yoctoproject.org/linux-yocto-dev.git;branch=${KBRANCH};name
SRCREV_machine ?= '${@oe.utils.conditional("PREFERRED_PROVIDER_virtual/kernel", "linux-yocto-dev", "${AUTOREV}", "29594404d7fe73cd80eaa4ee8c43dcc53970c60e", d)}'
SRCREV_meta ?= '${@oe.utils.conditional("PREFERRED_PROVIDER_virtual/kernel", "linux-yocto-dev", "${AUTOREV}", "29594404d7fe73cd80eaa4ee8c43dcc53970c60e", d)}'
-LINUX_VERSION ?= "4.16-rc+"
+LINUX_VERSION ?= "4.19-rc+"
LINUX_VERSION_EXTENSION ?= "-yoctodev-${LINUX_KERNEL_TYPE}"
PV = "${LINUX_VERSION}+git${SRCPV}"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+
DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
DEPENDS += "openssl-native util-linux-native"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb
deleted file mode 100644
index a6a8b60e1..000000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.12.bb
+++ /dev/null
@@ -1,38 +0,0 @@
-KBRANCH ?= "standard/preempt-rt/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# Skip processing of this recipe if it is not explicitly specified as the
-# PREFERRED_PROVIDER for virtual/kernel. This avoids errors when trying
-# to build multiple virtual/kernel providers, e.g. as dependency of
-# core-image-rt-sdk, core-image-rt.
-python () {
- if d.getVar("KERNEL_PACKAGE_NAME") == "kernel" and d.getVar("PREFERRED_PROVIDER_virtual/kernel") != "linux-yocto-rt":
- raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it")
-}
-
-SRCREV_machine ?= "ef88c3326f62cec4b98340324ddbe7f7f7704fd5"
-SRCREV_meta ?= "2ae65226f64ed5c888d60eef76b6249db678d060"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.12.git;branch=${KBRANCH};name=machine \
- git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.12;destsuffix=${KMETA}"
-
-LINUX_VERSION ?= "4.12.28"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-LINUX_KERNEL_TYPE = "preempt-rt"
-
-COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/taskstats.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.15.bb b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.18.bb
index d166a4098..f77de3a05 100644
--- a/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.15.bb
+++ b/poky/meta/recipes-kernel/linux/linux-yocto-rt_4.18.bb
@@ -1,4 +1,4 @@
-KBRANCH ?= "v4.15/standard/preempt-rt/base"
+KBRANCH ?= "v4.18/standard/preempt-rt/base"
require recipes-kernel/linux/linux-yocto.inc
@@ -11,13 +11,15 @@ python () {
raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it")
}
-SRCREV_machine ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_meta ?= "45c256a5ca6f9478bce212fec19e2bc273472631"
+SRCREV_machine ?= "8e00c30ce22f378ecb7f243b1df3d209b8ee29bc"
+SRCREV_meta ?= "bf98e195a4cf2404a064056b3593e83a7de84f25"
SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \
- git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.15;destsuffix=${KMETA}"
+ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.18;destsuffix=${KMETA}"
-LINUX_VERSION ?= "4.15.18"
+LINUX_VERSION ?= "4.18.14"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
DEPENDS += "openssl-native util-linux-native"
@@ -29,7 +31,7 @@ KCONF_BSP_AUDIT_LEVEL = "2"
LINUX_KERNEL_TYPE = "preempt-rt"
-COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuppc|qemumips)"
+COMPATIBLE_MACHINE = "(qemux86|qemux86-64|qemuarm|qemuarm64|qemuppc|qemumips)"
KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
@@ -38,4 +40,4 @@ KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc features/taskstats/ta
KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc"
+KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb
deleted file mode 100644
index cb4ef3a65..000000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.12.bb
+++ /dev/null
@@ -1,25 +0,0 @@
-KBRANCH ?= "standard/tiny/common-pc"
-LINUX_KERNEL_TYPE = "tiny"
-KCONFIG_MODE = "--allnoconfig"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-LINUX_VERSION ?= "4.12.28"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-SRCREV_machine ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_meta ?= "2ae65226f64ed5c888d60eef76b6249db678d060"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.12.git;branch=${KBRANCH};name=machine \
- git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.12;destsuffix=${KMETA}"
-
-COMPATIBLE_MACHINE = "qemux86|qemux86-64"
-
-# Functionality flags
-KERNEL_FEATURES = ""
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.15.bb b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.18.bb
index 5f9b3c7fb..591d41bd1 100644
--- a/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.15.bb
+++ b/poky/meta/recipes-kernel/linux/linux-yocto-tiny_4.18.bb
@@ -1,21 +1,25 @@
-KBRANCH ?= "v4.15/standard/tiny/common-pc"
+KBRANCH ?= "v4.18/standard/tiny/common-pc"
LINUX_KERNEL_TYPE = "tiny"
KCONFIG_MODE = "--allnoconfig"
require recipes-kernel/linux/linux-yocto.inc
-LINUX_VERSION ?= "4.15.18"
+LINUX_VERSION ?= "4.18.14"
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+
+DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
+DEPENDS += "openssl-native util-linux-native"
KMETA = "kernel-meta"
KCONF_BSP_AUDIT_LEVEL = "2"
-SRCREV_machine ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_meta ?= "45c256a5ca6f9478bce212fec19e2bc273472631"
+SRCREV_machine ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_meta ?= "bf98e195a4cf2404a064056b3593e83a7de84f25"
PV = "${LINUX_VERSION}+git${SRCPV}"
SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \
- git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.15;destsuffix=${KMETA}"
+ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.18;destsuffix=${KMETA}"
COMPATIBLE_MACHINE = "qemux86|qemux86-64"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto.inc b/poky/meta/recipes-kernel/linux/linux-yocto.inc
index 3bb872a32..1ebfb606d 100644
--- a/poky/meta/recipes-kernel/linux/linux-yocto.inc
+++ b/poky/meta/recipes-kernel/linux/linux-yocto.inc
@@ -2,7 +2,7 @@ SUMMARY = "Linux kernel"
SECTION = "kernel"
LICENSE = "GPLv2"
-LIC_FILES_CHKSUM = "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
+LIC_FILES_CHKSUM ?= "file://COPYING;md5=d7810fab7487fb0aad327b76f1be7cd7"
UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>\d+\.\d+(\.\d+)*)"
@@ -28,6 +28,8 @@ KERNEL_LD_append_nios2 = " ${TOOLCHAIN_OPTIONS}"
KERNEL_FEATURES_append_qemuall=" features/debug/printk.scc"
+KERNEL_FEATURES_append = " ${@bb.utils.contains('MACHINE_FEATURES', 'numa', 'features/numa/numa.scc', '', d)}"
+
# A KMACHINE is the mapping of a yocto $MACHINE to what is built
# by the kernel. This is typically the branch that should be built,
# and it can be specific to the machine or shared
@@ -67,3 +69,6 @@ do_install_append(){
addtask kernel_version_sanity_check after do_kernel_metadata do_kernel_checkout before do_compile
addtask validate_branches before do_patch after do_kernel_checkout
addtask kernel_configcheck after do_configure before do_compile
+
+# enable kernel-sample for oeqa/runtime/cases's ksample.py test
+KERNEL_FEATURES_append_qemuall=" features/kernel-sample/kernel-sample.scc"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb b/poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb
deleted file mode 100644
index 0aea05b83..000000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto_4.12.bb
+++ /dev/null
@@ -1,46 +0,0 @@
-KBRANCH ?= "standard/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# board specific branches
-KBRANCH_qemuarm ?= "standard/arm-versatile-926ejs"
-KBRANCH_qemuarm64 ?= "standard/qemuarm64"
-KBRANCH_qemumips ?= "standard/mti-malta32"
-KBRANCH_qemuppc ?= "standard/qemuppc"
-KBRANCH_qemux86 ?= "standard/base"
-KBRANCH_qemux86-64 ?= "standard/base"
-KBRANCH_qemumips64 ?= "standard/mti-malta64"
-
-SRCREV_machine_qemuarm ?= "b84ecefc243a6ed67d8b6020394963de1240a9f0"
-SRCREV_machine_qemuarm64 ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemumips ?= "15b1ab68f73fa60dd95a74c640e87e05fad1716d"
-SRCREV_machine_qemuppc ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemux86 ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemux86-64 ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_machine_qemumips64 ?= "57a3f72a020fc84f2da5b0b4c5de4cdbc22b3284"
-SRCREV_machine ?= "e562267bae5b518acca880c929fbbdf6be047e0a"
-SRCREV_meta ?= "2ae65226f64ed5c888d60eef76b6249db678d060"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto-4.12.git;name=machine;branch=${KBRANCH}; \
- git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.12;destsuffix=${KMETA}"
-
-DEPENDS += "openssl-native util-linux-native"
-
-LINUX_VERSION ?= "4.12.28"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb b/poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb
deleted file mode 100644
index 693670c61..000000000
--- a/poky/meta/recipes-kernel/linux/linux-yocto_4.15.bb
+++ /dev/null
@@ -1,47 +0,0 @@
-KBRANCH ?= "v4.15/standard/base"
-
-require recipes-kernel/linux/linux-yocto.inc
-
-# board specific branches
-KBRANCH_qemuarm ?= "v4.15/standard/arm-versatile-926ejs"
-KBRANCH_qemuarm64 ?= "v4.15/standard/qemuarm64"
-KBRANCH_qemumips ?= "v4.15/standard/mti-malta32"
-KBRANCH_qemuppc ?= "v4.15/standard/qemuppc"
-KBRANCH_qemux86 ?= "v4.15/standard/base"
-KBRANCH_qemux86-64 ?= "v4.15/standard/base"
-KBRANCH_qemumips64 ?= "v4.15/standard/mti-malta64"
-
-SRCREV_machine_qemuarm ?= "d16b10fb69974f1804a02f2678f40d22c80526cf"
-SRCREV_machine_qemuarm64 ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemumips ?= "182eaefab712f4360126e044c758e75d763d05c4"
-SRCREV_machine_qemuppc ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemux86 ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemux86-64 ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_machine_qemumips64 ?= "ce3876a091477260fcb1197e3c6565dfbf9c6e80"
-SRCREV_machine ?= "e25dbfe95302eeaa1a03a828d05c09479574488a"
-SRCREV_meta ?= "45c256a5ca6f9478bce212fec19e2bc273472631"
-
-SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \
- git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.15;destsuffix=${KMETA}"
-
-LINUX_VERSION ?= "4.15.18"
-
-DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
-DEPENDS += "openssl-native util-linux-native"
-
-PV = "${LINUX_VERSION}+git${SRCPV}"
-
-KMETA = "kernel-meta"
-KCONF_BSP_AUDIT_LEVEL = "2"
-
-KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
-
-COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
-
-# Functionality flags
-KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
-KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
-KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
-KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
-KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
diff --git a/poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb b/poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb
new file mode 100644
index 000000000..81160ca50
--- /dev/null
+++ b/poky/meta/recipes-kernel/linux/linux-yocto_4.18.bb
@@ -0,0 +1,48 @@
+KBRANCH ?= "v4.18/standard/base"
+
+require recipes-kernel/linux/linux-yocto.inc
+
+# board specific branches
+KBRANCH_qemuarm ?= "v4.18/standard/arm-versatile-926ejs"
+KBRANCH_qemuarm64 ?= "v4.18/standard/qemuarm64"
+KBRANCH_qemumips ?= "v4.18/standard/mti-malta32"
+KBRANCH_qemuppc ?= "v4.18/standard/qemuppc"
+KBRANCH_qemux86 ?= "v4.18/standard/base"
+KBRANCH_qemux86-64 ?= "v4.18/standard/base"
+KBRANCH_qemumips64 ?= "v4.18/standard/mti-malta64"
+
+SRCREV_machine_qemuarm ?= "0573ed3c737c82b24fd661cc5ea961cac07ea2fe"
+SRCREV_machine_qemuarm64 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemumips ?= "465252ba0ec00ae10397cb4623c3d77c89e542a5"
+SRCREV_machine_qemuppc ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemux86 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemux86-64 ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_machine_qemumips64 ?= "6d91dc62811f4688efc67845185858645b4ccfb8"
+SRCREV_machine ?= "33859b3077c83d8a024946ba06a59990546fcbc7"
+SRCREV_meta ?= "bf98e195a4cf2404a064056b3593e83a7de84f25"
+
+SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \
+ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-4.18;destsuffix=${KMETA}"
+
+LIC_FILES_CHKSUM = "file://COPYING;md5=bbea815ee2795b2f4230826c0c6b8814"
+LINUX_VERSION ?= "4.18.14"
+
+DEPENDS += "${@bb.utils.contains('ARCH', 'x86', 'elfutils-native', '', d)}"
+DEPENDS += "openssl-native util-linux-native"
+
+PV = "${LINUX_VERSION}+git${SRCPV}"
+
+KMETA = "kernel-meta"
+KCONF_BSP_AUDIT_LEVEL = "2"
+
+KERNEL_DEVICETREE_qemuarm = "versatile-pb.dtb"
+
+COMPATIBLE_MACHINE = "qemuarm|qemuarm64|qemux86|qemuppc|qemumips|qemumips64|qemux86-64"
+
+# Functionality flags
+KERNEL_EXTRA_FEATURES ?= "features/netfilter/netfilter.scc"
+KERNEL_FEATURES_append = " ${KERNEL_EXTRA_FEATURES}"
+KERNEL_FEATURES_append_qemuall=" cfg/virtio.scc"
+KERNEL_FEATURES_append_qemux86=" cfg/sound.scc cfg/paravirt_kvm.scc"
+KERNEL_FEATURES_append_qemux86-64=" cfg/sound.scc cfg/paravirt_kvm.scc"
+KERNEL_FEATURES_append = " ${@bb.utils.contains("TUNE_FEATURES", "mx32", " cfg/x32.scc", "" ,d)}"
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"
diff --git a/poky/meta/recipes-kernel/perf/perf-perl.inc b/poky/meta/recipes-kernel/perf/perf-perl.inc
new file mode 100644
index 000000000..ae77319b2
--- /dev/null
+++ b/poky/meta/recipes-kernel/perf/perf-perl.inc
@@ -0,0 +1,7 @@
+inherit perlnative cpan-base
+
+# Env var which tells perl if it should use host (no) or target (yes) settings
+export PERLCONFIGTARGET = "${@is_target(d)}"
+export PERL_INC = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}/CORE"
+export PERL_LIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
+export PERL_ARCHLIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
diff --git a/poky/meta/recipes-kernel/perf/perf.bb b/poky/meta/recipes-kernel/perf/perf.bb
index 90bbed25c..bae494875 100644
--- a/poky/meta/recipes-kernel/perf/perf.bb
+++ b/poky/meta/recipes-kernel/perf/perf.bb
@@ -12,6 +12,7 @@ LICENSE = "GPLv2"
PR = "r9"
PACKAGECONFIG ??= "scripting tui libunwind"
+PACKAGECONFIG[dwarf] = ",NO_DWARF=1"
PACKAGECONFIG[scripting] = ",NO_LIBPERL=1 NO_LIBPYTHON=1,perl python"
# gui support was added with kernel 3.6.35
# since 3.10 libnewt was replaced by slang
@@ -21,24 +22,26 @@ PACKAGECONFIG[libunwind] = ",NO_LIBUNWIND=1 NO_LIBDW_DWARF_UNWIND=1,libunwind"
PACKAGECONFIG[libnuma] = ",NO_LIBNUMA=1"
PACKAGECONFIG[systemtap] = ",NO_SDT=1,systemtap"
PACKAGECONFIG[jvmti] = ",NO_JVMTI=1"
-
# libaudit support would need scripting to be enabled
PACKAGECONFIG[audit] = ",NO_LIBAUDIT=1,audit"
+PACKAGECONFIG[manpages] = ",,xmlto-native asciidoc-native"
+
+# libunwind is not yet ported for some architectures
+PACKAGECONFIG_remove_arc = "libunwind"
+PACKAGECONFIG_remove_riscv64 = "libunwind"
DEPENDS = " \
virtual/${MLPREFIX}libc \
${MLPREFIX}elfutils \
${MLPREFIX}binutils \
bison-native flex-native xz \
- xmlto-native \
- asciidoc-native \
"
do_configure[depends] += "virtual/kernel:do_shared_workdir"
PROVIDES = "virtual/perf"
-inherit linux-kernel-base kernel-arch
+inherit linux-kernel-base kernel-arch manpages
# needed for building the tools/perf Python bindings
inherit ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'pythonnative', '', d)}
@@ -51,13 +54,7 @@ export WERROR = "0"
do_populate_lic[depends] += "virtual/kernel:do_patch"
# needed for building the tools/perf Perl binding
-inherit ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'perlnative', '', d)}
-inherit cpan-base
-# Env var which tells perl if it should use host (no) or target (yes) settings
-export PERLCONFIGTARGET = "${@is_target(d)}"
-export PERL_INC = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}/CORE"
-export PERL_LIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
-export PERL_ARCHLIB = "${STAGING_LIBDIR}${PERL_OWN_DIR}/perl/${@get_perl_version(d)}"
+include ${@bb.utils.contains('PACKAGECONFIG', 'scripting', 'perf-perl.inc', '', d)}
inherit kernelsrc
@@ -80,8 +77,9 @@ EXTRA_OEMAKE = '\
EXTRA_CFLAGS="-ldw" \
EXTRA_LDFLAGS="${PERF_EXTRA_LDFLAGS}" \
perfexecdir=${libexecdir} \
- NO_GTK2=1 NO_DWARF=1 \
+ NO_GTK2=1 \
${PACKAGECONFIG_CONFARGS} \
+ TMPDIR="${B}" \
'
EXTRA_OEMAKE += "\
@@ -146,6 +144,8 @@ python copy_perf_source_from_kernel() {
for s in sources:
src = oe.path.join(src_dir, s)
dest = oe.path.join(dest_dir, s)
+ if not os.path.exists(src):
+ bb.fatal("Path does not exist: %s. Maybe PERF_SRC does not match the kernel version." % src)
if os.path.isdir(src):
oe.path.copyhardlinktree(src, dest)
else:
@@ -246,7 +246,6 @@ PACKAGE_ARCH = "${MACHINE_ARCH}"
PACKAGES =+ "${PN}-archive ${PN}-tests ${PN}-perl ${PN}-python"
RDEPENDS_${PN} += "elfutils bash"
-RDEPENDS_${PN}-doc += "man"
RDEPENDS_${PN}-archive =+ "bash"
RDEPENDS_${PN}-python =+ "bash python python-modules ${@bb.utils.contains('PACKAGECONFIG', 'audit', 'audit-python', '', d)}"
RDEPENDS_${PN}-perl =+ "bash perl perl-modules"
diff --git a/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch b/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch
index e28fdcad9..ade51cf86 100644
--- a/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch
+++ b/poky/meta/recipes-kernel/sysprof/files/0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch
@@ -1,26 +1,27 @@
-From c2495a4c042e6a675da69bab20cc3669391e8e2a Mon Sep 17 00:00:00 2001
+From d332b480257aa98b63d39c3c94896a111536f937 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Wed, 23 Aug 2017 18:38:26 +0300
-Subject: [PATCH 1/2] Do not build anything in help/ as it requires itstool.
+Subject: [PATCH 2/2] Do not build anything in help/ as it requires itstool.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
---
meson.build | 1 -
1 file changed, 1 deletion(-)
diff --git a/meson.build b/meson.build
-index 4ac3934..8c4369a 100644
+index 3986273..ae2f65e 100644
--- a/meson.build
+++ b/meson.build
-@@ -116,7 +116,6 @@ subdir('tools')
+@@ -164,7 +164,6 @@ subdir('tools')
subdir('tests')
subdir('data')
-subdir('help')
subdir('po')
- meson.add_install_script('build-aux/meson_post_install.sh')
+ meson.add_install_script('build-aux/meson/post_install.sh')
--
-2.14.1
+2.7.4
diff --git a/poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch b/poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch
new file mode 100644
index 000000000..38f9f5f66
--- /dev/null
+++ b/poky/meta/recipes-kernel/sysprof/files/0001-fix-non-literal-format-string-issues.patch
@@ -0,0 +1,34 @@
+From de13d1f908335cc882c447e4d7c4360b9e5da190 Mon Sep 17 00:00:00 2001
+From: Khem Raj <raj.khem@gmail.com>
+Date: Thu, 6 Sep 2018 17:49:44 -0700
+Subject: [PATCH] fix non-literal format string issues
+
+clang errors out when using -Werror=format-nonliteral
+since the definition of g_strdup_vprintf() from glib-2.0
+is using va_list and clangs still warns where as
+gcc doesn't do that for va_list arguments
+
+Fixes
+src/sp-window.c:96:27: error: format string is not a string literal [-Werror,-Wformat-nonliteral]
+| str = g_strdup_vprintf (format, args);
+| ^~~~~~
+
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/sysprof/merge_requests/6]
+Signed-off-by: Khem Raj <raj.khem@gmail.com>
+---
+ src/sp-window.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/sp-window.c b/src/sp-window.c
+index 4dfac2d..aff4779 100644
+--- a/src/sp-window.c
++++ b/src/sp-window.c
+@@ -80,7 +80,7 @@ static guint signals [N_SIGNALS];
+ static void sp_window_set_profiler (SpWindow *self,
+ SpProfiler *profiler);
+
+-static void
++static G_GNUC_PRINTF(3, 4) void
+ sp_window_notify_user (SpWindow *self,
+ GtkMessageType message_type,
+ const gchar *format,
diff --git a/poky/meta/recipes-kernel/sysprof/files/wordsize.patch b/poky/meta/recipes-kernel/sysprof/files/wordsize.patch
new file mode 100644
index 000000000..d65b13a68
--- /dev/null
+++ b/poky/meta/recipes-kernel/sysprof/files/wordsize.patch
@@ -0,0 +1,38 @@
+Upstream-Status: Submitted [https://gitlab.gnome.org/GNOME/sysprof/merge_requests/5]
+Signed-off-by: Ross Burton <ross.burton@intel.com>
+
+From bc7e3e27c28d0bab8bea72f2314191532b2e7840 Mon Sep 17 00:00:00 2001
+From: Ross Burton <ross.burton@intel.com>
+Date: Fri, 7 Sep 2018 01:30:09 +0100
+Subject: [PATCH] capture: use size of void* instead of glibc-specific
+ __WORDSIZE
+
+__WORDSIZE is glibc-specific so sp-capture-types.h doesn't work with musl.
+---
+ lib/capture/sp-capture-types.h | 6 ++++--
+ 1 file changed, 4 insertions(+), 2 deletions(-)
+
+diff --git a/lib/capture/sp-capture-types.h b/lib/capture/sp-capture-types.h
+index 48fcfb8..1d6cd1d 100644
+--- a/lib/capture/sp-capture-types.h
++++ b/lib/capture/sp-capture-types.h
+@@ -32,12 +32,14 @@ G_BEGIN_DECLS
+ #define SP_CAPTURE_MAGIC (GUINT32_TO_LE(0xFDCA975E))
+ #define SP_CAPTURE_ALIGN (sizeof(SpCaptureAddress))
+
+-#if __WORDSIZE == 64
++#if GLIB_SIZEOF_VOID_P == 8
+ # define SP_CAPTURE_JITMAP_MARK G_GUINT64_CONSTANT(0xE000000000000000)
+ # define SP_CAPTURE_ADDRESS_FORMAT "0x%016lx"
+-#else
++#elif GLIB_SIZEOF_VOID_P == 4
+ # define SP_CAPTURE_JITMAP_MARK G_GUINT64_CONSTANT(0xE0000000)
+ # define SP_CAPTURE_ADDRESS_FORMAT "0x%016llx"
++#else
++#error Unknown GLIB_SIZEOF_VOID_P
+ #endif
+
+ #define SP_CAPTURE_CURRENT_TIME (sp_clock_get_current_time())
+--
+2.11.0
+
diff --git a/poky/meta/recipes-kernel/sysprof/sysprof_3.26.1.bb b/poky/meta/recipes-kernel/sysprof/sysprof_3.30.0.bb
index 1989b52a7..19dcf25a5 100644
--- a/poky/meta/recipes-kernel/sysprof/sysprof_3.26.1.bb
+++ b/poky/meta/recipes-kernel/sysprof/sysprof_3.30.0.bb
@@ -9,12 +9,15 @@ inherit gnomebase gettext systemd upstream-version-is-even
DEPENDS = "glib-2.0 libxml2-native glib-2.0-native"
-SRC_URI[archive.md5sum] = "6f9f947960ba79bb1269d8ee49b7db78"
-SRC_URI[archive.sha256sum] = "d8b9d5c2246696e4a3776a312731dc7c014fbd33478bb14d5512c6f1f35a3b11"
+SRC_URI[archive.md5sum] = "ae896a8a2364e18c07fafa9573202f59"
+SRC_URI[archive.sha256sum] = "29cd2c4be277f00698dce48259219557c4fddc2c01254b8fac95900a8c663f63"
SRC_URI += " \
file://define-NT_GNU_BUILD_ID.patch \
file://0001-Do-not-build-anything-in-help-as-it-requires-itstool.patch \
+ file://wordsize.patch \
+ file://0001-fix-non-literal-format-string-issues.patch \
"
+RECIPE_NO_UPDATE_REASON = "Waiting for resolution of https://bugzilla.gnome.org/show_bug.cgi?id=794625"
PACKAGECONFIG ?= "${@bb.utils.contains_any('DISTRO_FEATURES', '${GTK3DISTROFEATURES}', 'gtk', '', d)}"
PACKAGECONFIG[gtk] = "-Denable_gtk=true,-Denable_gtk=false,gtk+3"
@@ -25,10 +28,8 @@ FILES_SOLIBSDEV = ""
SYSTEMD_SERVICE_${PN} = "${@bb.utils.contains('PACKAGECONFIG', 'sysprofd', 'sysprof2.service', '', d)}"
-# We do not yet work for aarch64.
-COMPATIBLE_HOST = "^(?!aarch64).*"
-
FILES_${PN} += " \
${datadir}/dbus-1/system-services \
${datadir}/dbus-1/system.d \
+ ${datadir}/metainfo \
"
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch
deleted file mode 100644
index c0ceb5a41..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Added-a-couple-of-small-sysroot-fixes.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From a714658727206d2a98a7194b7e6d29dbd3e27b8d Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Mon, 19 Mar 2018 16:50:05 -0500
-Subject: [PATCH] Added a couple of small sysroot fixes.
-
-* tapsets.cxx (dwarf_builder::build): Fix commit 4ffecddf5.
- (path_remove_sysroot): Fix extra '/' present at start of paths.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- tapsets.cxx | 10 +++++++---
- 1 file changed, 7 insertions(+), 3 deletions(-)
-
-Index: git/tapsets.cxx
-===================================================================
---- git.orig/tapsets.cxx
-+++ git/tapsets.cxx
-@@ -1395,7 +1395,8 @@ string path_remove_sysroot(const systemt
- string retval = path;
- if (!sess.sysroot.empty() &&
- (pos = retval.find(sess.sysroot)) != string::npos)
-- retval.replace(pos, sess.sysroot.length(), "/");
-+ retval.replace(pos, sess.sysroot.length(),
-+ (sess.sysroot.back() == '/' ? "/": ""));
- return retval;
- }
-
-@@ -8412,8 +8413,11 @@ dwarf_builder::build(systemtap_session &
-
- // PR13338: unquote glob results
- module_name = unescape_glob_chars (module_name);
-- user_path = find_executable (module_name, "", sess.sysenv); // canonicalize it
-- if (!is_fully_resolved(user_path, sess.sysroot, sess.sysenv))
-+ user_path = find_executable (module_name, sess.sysroot, sess.sysenv); // canonicalize it
-+ // Note we don't need to pass the sysroot to
-+ // is_fully_resolved(), since we just passed it to
-+ // find_executable().
-+ if (!is_fully_resolved(user_path, "", sess.sysenv))
- throw SEMANTIC_ERROR(_F("cannot find executable '%s'",
- user_path.to_string().c_str()));
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch
deleted file mode 100644
index 89951a2f1..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch
+++ /dev/null
@@ -1,61 +0,0 @@
-From 4ffecddf5433d65a6f01241990c9d516586b1c79 Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Mon, 19 Mar 2018 08:53:51 -0500
-Subject: [PATCH] Delay adding sysroot path to module name in case of non
- absolute executable
-
-Current stap code adds sysroot prematurely for probes that specify non
-absolute path name, i.e like "foo", so when find_executable called it
-receives full path as <sysroot>/foo and find_executable does not search
-PATH while applying sysroot.
-
-Fix delays adding sysroot till path inside of sysroot is searched first.
-
-Also fix missing sysroot addition in glob expansion case.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- tapsets.cxx | 8 ++++----
- 1 file changed, 4 insertions(+), 4 deletions(-)
-
-Index: git/tapsets.cxx
-===================================================================
---- git.orig/tapsets.cxx
-+++ git/tapsets.cxx
-@@ -746,7 +746,7 @@ base_query::base_query(dwflpp & dw, lite
- pid_val = 0;
- get_string_param(params, TOK_PROCESS, module_val);
- }
-- module_val = find_executable (module_val, "", sess.sysenv);
-+ module_val = find_executable (module_val, sess.sysroot, sess.sysenv);
- if (!is_fully_resolved(module_val, "", sess.sysenv))
- throw SEMANTIC_ERROR(_F("cannot find executable '%s'",
- module_val.to_string().c_str()));
-@@ -8287,7 +8287,6 @@ dwarf_builder::build(systemtap_session &
- }
- else
- {
-- module_name = (string)sess.sysroot + (string)module_name;
- filled_parameters[TOK_PROCESS] = new literal_string(module_name);
- }
- }
-@@ -8321,7 +8320,8 @@ dwarf_builder::build(systemtap_session &
- assert (lit);
-
- // Evaluate glob here, and call derive_probes recursively with each match.
-- const auto& globs = glob_executable (module_name);
-+ const auto& globs = glob_executable (sess.sysroot
-+ + string(module_name));
- unsigned results_pre = finished_results.size();
- for (auto it = globs.begin(); it != globs.end(); ++it)
- {
-@@ -8413,7 +8413,7 @@ dwarf_builder::build(systemtap_session &
- // PR13338: unquote glob results
- module_name = unescape_glob_chars (module_name);
- user_path = find_executable (module_name, "", sess.sysenv); // canonicalize it
-- if (!is_fully_resolved(user_path, "", sess.sysenv))
-+ if (!is_fully_resolved(user_path, sess.sysroot, sess.sysenv))
- throw SEMANTIC_ERROR(_F("cannot find executable '%s'",
- user_path.to_string().c_str()));
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch
deleted file mode 100644
index 460c3b760..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch
+++ /dev/null
@@ -1,277 +0,0 @@
-From fbb26e17a4c026f05a497fc5d584516bad3b6950 Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Wed, 6 Dec 2017 14:37:42 -0600
-Subject: [PATCH] Fix PR22551 by updating the use of timers for the 4.15
- kernel.
-
-* runtime/linux/timer_compatibility.h: New file.
-* runtime/time.c: Update timer callback function parameter type. Update
- timer initialization.
-* runtime/transport/relay_v2.c: Ditto.
-* runtime/transport/transport.c: Ditto.
-* tapset-timers.cxx (timer_derived_probe_group::emit_module_decls):
- Ditto. Handle old and new timer callback interface.
-* runtime/linux/runtime.h: Include timer_compatibility.h instead of timer.h.
-* tapset/linux/scsi.stp: Ditto.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
-
----
- runtime/linux/runtime.h | 2 +-
- runtime/linux/timer_compatibility.h | 76 +++++++++++++++++++++++++++++++++++++
- runtime/time.c | 7 ++--
- runtime/transport/relay_v2.c | 8 ++--
- runtime/transport/transport.c | 13 +++----
- tapset-timers.cxx | 14 +++++--
- tapset/linux/scsi.stp | 2 +-
- 7 files changed, 100 insertions(+), 22 deletions(-)
- create mode 100644 runtime/linux/timer_compatibility.h
-
-diff --git a/runtime/linux/runtime.h b/runtime/linux/runtime.h
-index 9c585a2..df9b74c 100644
---- a/runtime/linux/runtime.h
-+++ b/runtime/linux/runtime.h
-@@ -34,7 +34,7 @@
- #include <linux/compat.h>
- #include <linux/sched.h>
- #include <linux/mm.h>
--#include <linux/timer.h>
-+#include "timer_compatibility.h"
- #include <linux/delay.h>
- #include <linux/profile.h>
- #include <linux/rcupdate.h>
-diff --git a/runtime/linux/timer_compatibility.h b/runtime/linux/timer_compatibility.h
-new file mode 100644
-index 0000000..ac03de9
---- /dev/null
-+++ b/runtime/linux/timer_compatibility.h
-@@ -0,0 +1,76 @@
-+/*
-+ * linux/timer.h compatibility defines and inlines
-+ * Copyright (C) 2017 Red Hat Inc.
-+ *
-+ * This file is part of systemtap, and is free software. You can
-+ * redistribute it and/or modify it under the terms of the GNU General
-+ * Public License (GPL); either version 2, or (at your option) any
-+ * later version.
-+ */
-+
-+#ifndef _TIMER_COMPATIBILITY_H_
-+#define _TIMER_COMPATIBILITY_H_
-+
-+#include <linux/timer.h>
-+
-+/*
-+ * Starting with the 4.15 kernel, the timer interface
-+ * changed. Originally, you'd do something like:
-+ *
-+ * static void timer_func(unsigned long val);
-+ *
-+ * init_timer(&timer);
-+ * timer.expires = jiffies + STP_RELAY_TIMER_INTERVAL;
-+ * timer.function = timer_func;
-+ * timer.data = 0;
-+ * add_timer(&timer);
-+ *
-+ * The 'data' parameter would get passed to the callback
-+ * function. Starting with 4.15, you'd do something like this:
-+ *
-+ * static void timer_func(struct timer_list *val);
-+ *
-+ * timer_setup(&timer, timer_func, 0);
-+ * timer.expires = jiffies + STP_RELAY_TIMER_INTERVAL;
-+ * add_timer(&timer);
-+ *
-+ * With the new code, the timer that caused the callback gets passed
-+ * to the timer callback function. The 'data' field has been removed.
-+ *
-+ * So, we're going to use the new interface. To hide the differences
-+ * between the callback function parameter type, we'll define a new
-+ * type, 'stp_timer_callback_parameter_t'.
-+ *
-+ * If code needs to figure out the difference between the old and new
-+ * interface, it should test the TIMER_TRACE_FLAGMASK define (which
-+ * only exists in the new interface).
-+ */
-+
-+#if defined(TIMER_TRACE_FLAGMASK)
-+/* This is the >= 4.15 kernel interface. */
-+
-+typedef struct timer_list * stp_timer_callback_parameter_t;
-+
-+#else
-+/* This is the < 4.15 kernel interface. */
-+
-+typedef unsigned long stp_timer_callback_parameter_t;
-+
-+/**
-+ * timer_setup - prepare a timer for first use
-+ * @timer: the timer in question
-+ * @callback: the function to call when timer expires
-+ * @flags: any TIMER_* flags (note that anything other than 0 is an
-+ * error, since this compatibility function can't support any
-+ * of the TIMER_* flags)
-+ */
-+#define timer_setup(timer, callback, flags) \
-+ { \
-+ init_timer((timer)); \
-+ (timer)->function = callback; \
-+ (timer)->data = 0; \
-+ BUILD_BUG_ON_ZERO((flags) != 0); \
-+ }
-+#endif
-+
-+#endif /* _TIMER_COMPATIBILITY_H_ */
-diff --git a/runtime/time.c b/runtime/time.c
-index 2e666d5..91ceafa 100644
---- a/runtime/time.c
-+++ b/runtime/time.c
-@@ -168,10 +168,10 @@ __stp_time_smp_callback(void *val)
-
- /* The timer callback is in a softIRQ -- interrupts enabled. */
- static void
--__stp_time_timer_callback(unsigned long val)
-+__stp_time_timer_callback(stp_timer_callback_parameter_t unused)
- {
- stp_time_t *time =__stp_time_local_update();
-- (void) val;
-+ (void) unused;
-
- /* PR6481: make sure IRQs are enabled before resetting the timer
- (IRQs are disabled and then reenabled in
-@@ -200,9 +200,8 @@ __stp_init_time(void *info)
- time->freq = __stp_get_freq();
- __stp_time_local_update();
-
-- init_timer(&time->timer);
-+ timer_setup(&time->timer, __stp_time_timer_callback, 0);
- time->timer.expires = jiffies + STP_TIME_SYNC_INTERVAL;
-- time->timer.function = __stp_time_timer_callback;
-
- #ifndef STAPCONF_ADD_TIMER_ON
- add_timer(&time->timer);
-diff --git a/runtime/transport/relay_v2.c b/runtime/transport/relay_v2.c
-index f81d75d..135951a 100644
---- a/runtime/transport/relay_v2.c
-+++ b/runtime/transport/relay_v2.c
-@@ -30,7 +30,7 @@
- #include <linux/debugfs.h>
- #include <linux/mm.h>
- #include <linux/relay.h>
--#include <linux/timer.h>
-+#include "../linux/timer_compatibility.h"
- #include "../uidgid_compatibility.h"
- #include "relay_compat.h"
-
-@@ -120,7 +120,7 @@ static void __stp_relay_wakeup_readers(struct rchan_buf *buf)
- wake_up_interruptible(&buf->read_wait);
- }
-
--static void __stp_relay_wakeup_timer(unsigned long val)
-+static void __stp_relay_wakeup_timer(stp_timer_callback_parameter_t unused)
- {
- #ifdef STP_BULKMODE
- int i;
-@@ -151,10 +151,8 @@ static void __stp_relay_wakeup_timer(unsigned long val)
- static void __stp_relay_timer_init(void)
- {
- atomic_set(&_stp_relay_data.wakeup, 0);
-- init_timer(&_stp_relay_data.timer);
-+ timer_setup(&_stp_relay_data.timer, __stp_relay_wakeup_timer, 0);
- _stp_relay_data.timer.expires = jiffies + STP_RELAY_TIMER_INTERVAL;
-- _stp_relay_data.timer.function = __stp_relay_wakeup_timer;
-- _stp_relay_data.timer.data = 0;
- add_timer(&_stp_relay_data.timer);
- smp_mb();
- }
-diff --git a/runtime/transport/transport.c b/runtime/transport/transport.c
-index 3400f22..320fd18 100644
---- a/runtime/transport/transport.c
-+++ b/runtime/transport/transport.c
-@@ -311,7 +311,7 @@ static void _stp_detach(void)
- }
-
-
--static void _stp_ctl_work_callback(unsigned long val);
-+static void _stp_ctl_work_callback(stp_timer_callback_parameter_t unused);
-
- /*
- * Called when stapio opens the control channel.
-@@ -320,13 +320,12 @@ static void _stp_attach(void)
- {
- dbug_trans(1, "attach\n");
- _stp_pid = current->pid;
-- if (_stp_namespaces_pid < 1)
-- _stp_namespaces_pid = _stp_pid;
-+ if (_stp_namespaces_pid < 1)
-+ _stp_namespaces_pid = _stp_pid;
- _stp_transport_data_fs_overwrite(0);
-- init_timer(&_stp_ctl_work_timer);
-+
-+ timer_setup(&_stp_ctl_work_timer, _stp_ctl_work_callback, 0);
- _stp_ctl_work_timer.expires = jiffies + STP_CTL_TIMER_INTERVAL;
-- _stp_ctl_work_timer.function = _stp_ctl_work_callback;
-- _stp_ctl_work_timer.data= 0;
- add_timer(&_stp_ctl_work_timer);
- }
-
-@@ -341,7 +340,7 @@ static void _stp_attach(void)
- * notified. Reschedules itself if someone is still attached
- * to the cmd channel.
- */
--static void _stp_ctl_work_callback(unsigned long val)
-+static void _stp_ctl_work_callback(stp_timer_callback_parameter_t unused)
- {
- int do_io = 0;
- unsigned long flags;
-diff --git a/tapset-timers.cxx b/tapset-timers.cxx
-index 1a40bcd..0ab4d69 100644
---- a/tapset-timers.cxx
-+++ b/tapset-timers.cxx
-@@ -122,9 +122,13 @@ timer_derived_probe_group::emit_module_decls (systemtap_session& s)
- s.op->newline(-1) << "};";
- s.op->newline();
-
-- s.op->newline() << "static void enter_timer_probe (unsigned long val) {";
-+ s.op->newline() << "static void enter_timer_probe (stp_timer_callback_parameter_t val) {";
-+ s.op->newline() << "#if defined(TIMER_TRACE_FLAGMASK)";
-+ s.op->newline(1) << "struct stap_timer_probe* stp = container_of(val, struct stap_timer_probe, timer_list);";
-+ s.op->newline(-1) << "#else";
- s.op->newline(1) << "struct stap_timer_probe* stp = & stap_timer_probes [val];";
-- s.op->newline() << "if ((atomic_read (session_state()) == STAP_SESSION_STARTING) ||";
-+ s.op->newline(-1) << "#endif";
-+ s.op->newline(1) << "if ((atomic_read (session_state()) == STAP_SESSION_STARTING) ||";
- s.op->newline() << " (atomic_read (session_state()) == STAP_SESSION_RUNNING))";
- s.op->newline(1) << "mod_timer (& stp->timer_list, jiffies + ";
- emit_interval (s.op);
-@@ -148,9 +152,11 @@ timer_derived_probe_group::emit_module_init (systemtap_session& s)
- s.op->newline() << "for (i=0; i<" << probes.size() << "; i++) {";
- s.op->newline(1) << "struct stap_timer_probe* stp = & stap_timer_probes [i];";
- s.op->newline() << "probe_point = stp->probe->pp;";
-- s.op->newline() << "init_timer (& stp->timer_list);";
-- s.op->newline() << "stp->timer_list.function = & enter_timer_probe;";
-+
-+ s.op->newline() << "timer_setup (& stp->timer_list, enter_timer_probe, 0);";
-+ s.op->newline() << "#if !defined(TIMER_TRACE_FLAGMASK)";
- s.op->newline() << "stp->timer_list.data = i;"; // NB: important!
-+ s.op->newline() << "#endif";
- // copy timer renew calculations from above :-(
- s.op->newline() << "stp->timer_list.expires = jiffies + ";
- emit_interval (s.op);
-diff --git a/tapset/linux/scsi.stp b/tapset/linux/scsi.stp
-index 44f686c..3577942 100644
---- a/tapset/linux/scsi.stp
-+++ b/tapset/linux/scsi.stp
-@@ -14,7 +14,7 @@
- #include <scsi/scsi_cmnd.h>
- #include <scsi/scsi_device.h>
- #include <scsi/scsi_host.h>
--#include <linux/timer.h>
-+#include "linux/timer_compatibility.h"
- #include <linux/blkdev.h>
- %}
-
---
-2.7.4
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch
deleted file mode 100644
index a1b0bff02..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Fixes-for-gcc-8.patch
+++ /dev/null
@@ -1,215 +0,0 @@
-From 4ffe00f1d9eac332d928f7dc01fe250dc32b1bb8 Mon Sep 17 00:00:00 2001
-From: Stan Cox <scox@redhat.com>
-Date: Tue, 13 Feb 2018 22:38:03 -0500
-Subject: [PATCH] Fixes for gcc 8
-
-* includes/sys/sdt.h (__SDT_COND_SIGNED): Add CT, cast type argument
-
-Author: Will Cohen <wcohen.redhat.com>
-
-* stap-serverd.cxx (generate_mok, handleRequest, handle_connection):
- Catch format overflow
-
-* translate.cxx (translate_pass): Use ref in catch.
----
-Upstream-Status: Backport
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
-
- includes/sys/sdt.h | 20 ++++++++--------
- stap-serverd.cxx | 67 +++++++++++++++++++++++++++++++++++++++++++++++-------
- translate.cxx | 2 +-
- 3 files changed, 70 insertions(+), 19 deletions(-)
-
-diff --git a/includes/sys/sdt.h b/includes/sys/sdt.h
-index 940f74483..c0c5a492c 100644
---- a/includes/sys/sdt.h
-+++ b/includes/sys/sdt.h
-@@ -119,8 +119,8 @@ struct __sdt_type
-
- #define __SDT_ALWAYS_SIGNED(T) \
- template<> struct __sdt_type<T> { static const bool __sdt_signed = true; };
--#define __SDT_COND_SIGNED(T) \
--template<> struct __sdt_type<T> { static const bool __sdt_signed = ((T)(-1) < 1); };
-+#define __SDT_COND_SIGNED(T,CT) \
-+template<> struct __sdt_type<T> { static const bool __sdt_signed = ((CT)(-1) < 1); };
- __SDT_ALWAYS_SIGNED(signed char)
- __SDT_ALWAYS_SIGNED(short)
- __SDT_ALWAYS_SIGNED(int)
-@@ -141,14 +141,14 @@ __SDT_ALWAYS_SIGNED(const volatile short)
- __SDT_ALWAYS_SIGNED(const volatile int)
- __SDT_ALWAYS_SIGNED(const volatile long)
- __SDT_ALWAYS_SIGNED(const volatile long long)
--__SDT_COND_SIGNED(char)
--__SDT_COND_SIGNED(wchar_t)
--__SDT_COND_SIGNED(volatile char)
--__SDT_COND_SIGNED(volatile wchar_t)
--__SDT_COND_SIGNED(const char)
--__SDT_COND_SIGNED(const wchar_t)
--__SDT_COND_SIGNED(const volatile char)
--__SDT_COND_SIGNED(const volatile wchar_t)
-+__SDT_COND_SIGNED(char, char)
-+__SDT_COND_SIGNED(wchar_t, wchar_t)
-+__SDT_COND_SIGNED(volatile char, char)
-+__SDT_COND_SIGNED(volatile wchar_t, wchar_t)
-+__SDT_COND_SIGNED(const char, char)
-+__SDT_COND_SIGNED(const wchar_t, wchar_t)
-+__SDT_COND_SIGNED(const volatile char, char)
-+__SDT_COND_SIGNED(const volatile wchar_t, wchar_t)
- #if defined (__GNUC__) && (__GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 4))
- /* __SDT_COND_SIGNED(char16_t) */
- /* __SDT_COND_SIGNED(char32_t) */
-diff --git a/stap-serverd.cxx b/stap-serverd.cxx
-index 7cf76c617..41f77ee9e 100644
---- a/stap-serverd.cxx
-+++ b/stap-serverd.cxx
-@@ -1607,6 +1607,7 @@ generate_mok(string &mok_fingerprint)
- char tmpdir[PATH_MAX] = { '\0' };
- string public_cert_path, private_cert_path, destdir;
- mode_t old_umask;
-+ int retlen;
-
- mok_fingerprint.clear ();
-
-@@ -1631,7 +1632,14 @@ generate_mok(string &mok_fingerprint)
- }
-
- // Make a temporary directory to store results in.
-- snprintf (tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", mok_path.c_str ());
-+ retlen = snprintf (tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", mok_path.c_str ());
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Could not create %s name", "temporary directory"));
-+ tmpdir[0] = '\0';
-+ goto cleanup;
-+ }
-+
- if (mkdtemp (tmpdir) == NULL)
- {
- server_error (_F("Could not create temporary directory %s: %s", tmpdir,
-@@ -1704,6 +1712,7 @@ handleRequest (const string &requestDirName, const string &responseDirName, stri
- unsigned u;
- unsigned i;
- FILE* f;
-+ int retlen;
-
- // Save the server version. Do this early, so the client knows what version of the server
- // it is dealing with, even if the request is not fully completed.
-@@ -1782,7 +1791,12 @@ handleRequest (const string &requestDirName, const string &responseDirName, stri
- struct stat st;
- char *arg;
-
-- snprintf (stapargfile, PATH_MAX, "%s/argv%d", requestDirName.c_str (), i);
-+ retlen = snprintf (stapargfile, PATH_MAX, "%s/argv%d", requestDirName.c_str (), i);
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "path"));
-+ return;
-+ }
-
- rc = stat(stapargfile, & st);
- if (rc) break;
-@@ -1888,7 +1902,15 @@ handleRequest (const string &requestDirName, const string &responseDirName, stri
- {
- glob_t globber;
- char pattern[PATH_MAX];
-- snprintf (pattern, PATH_MAX, "%s/*.ko", new_staptmpdir.c_str());
-+ int retlen;
-+
-+ retlen = snprintf (pattern, PATH_MAX, "%s/*.ko", new_staptmpdir.c_str());
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "pattern"));
-+ return;
-+ }
-+
- rc = glob (pattern, GLOB_ERR, NULL, &globber);
- if (rc)
- server_error (_F("Unable to find a module in %s", new_staptmpdir.c_str()));
-@@ -2164,6 +2186,7 @@ handle_connection (void *arg)
- copy for each connection.*/
- vector<string> argv;
- PRInt32 bytesRead;
-+ int retlen;
-
- /* Detatch to avoid a memory leak */
- if(max_threads > 0)
-@@ -2213,7 +2236,13 @@ handle_connection (void *arg)
- #endif
-
- secStatus = SECFailure;
-- snprintf(tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", getenv("TMPDIR") ?: "/tmp");
-+ retlen = snprintf(tmpdir, PATH_MAX, "%s/stap-server.XXXXXX", getenv("TMPDIR") ?: "/tmp");
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "temporary directory"));
-+ tmpdir[0]=0; /* prevent /bin/rm */
-+ goto cleanup;
-+ }
- rc1 = mkdtemp(tmpdir);
- if (! rc1)
- {
-@@ -2223,9 +2252,20 @@ handle_connection (void *arg)
- }
-
- /* Create a temporary files names and directories. */
-- snprintf (requestFileName, PATH_MAX, "%s/request.zip", tmpdir);
-+ retlen = snprintf (requestFileName, PATH_MAX, "%s/request.zip", tmpdir);
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "request.zip path"));
-+ goto cleanup;
-+ }
-+
-+ retlen = snprintf (requestDirName, PATH_MAX, "%s/request", tmpdir);
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "request directory path"));
-+ goto cleanup;
-+ }
-
-- snprintf (requestDirName, PATH_MAX, "%s/request", tmpdir);
- rc = mkdir(requestDirName, 0700);
- if (rc)
- {
-@@ -2233,7 +2273,13 @@ handle_connection (void *arg)
- goto cleanup;
- }
-
-- snprintf (responseDirName, PATH_MAX, "%s/response", tmpdir);
-+ retlen = snprintf (responseDirName, PATH_MAX, "%s/response", tmpdir);
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "response directory path"));
-+ goto cleanup;
-+ }
-+
- rc = mkdir(responseDirName, 0700);
- if (rc)
- {
-@@ -2243,7 +2289,12 @@ handle_connection (void *arg)
- // Set this early, since it gets used for errors to be returned to the client.
- stapstderr = string(responseDirName) + "/stderr";
-
-- snprintf (responseFileName, PATH_MAX, "%s/response.zip", tmpdir);
-+ retlen = snprintf (responseFileName, PATH_MAX, "%s/response.zip", tmpdir);
-+ if (retlen < 0 || retlen >= PATH_MAX)
-+ {
-+ server_error (_F("Error creating %s name", "response.zip path"));
-+ goto cleanup;
-+ }
-
- /* Read data from the socket.
- * If the user is requesting/requiring authentication, authenticate
-diff --git a/translate.cxx b/translate.cxx
-index 1240a80ec..4ade06fdd 100644
---- a/translate.cxx
-+++ b/translate.cxx
-@@ -7860,7 +7860,7 @@ translate_pass (systemtap_session& s)
- if (versions.size() >= 3 && s.verbose > 1)
- clog << _F("ignoring extra parts of compat version: %s", s.compatible.c_str()) << endl;
- }
-- catch (const runtime_error)
-+ catch (const runtime_error&)
- {
- throw SEMANTIC_ERROR(_F("parse error in compatibility version: %s", s.compatible.c_str()));
- }
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch
index 528864cc9..48cf4aee8 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch
+++ b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Install-python-modules-to-correct-library-dir.patch
@@ -5,32 +5,52 @@ Subject: [PATCH] Install python modules to correct library dir.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Add OE's CFLAGS which contains `-fdebug-prefix-map' options to
+setup.py
+
+Supply "--root" directory to the "install" command, and use
+it as a prefix to strip off the purported filename encoded
+in bytecode files. (It strips build path prefix from .pyc files)
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
---
- python/Makefile.am | 4 ++--
- 1 file changed, 2 insertions(+), 2 deletions(-)
+ python/Makefile.am | 8 ++++++--
+ 1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/python/Makefile.am b/python/Makefile.am
-index a254480f9..efe9f3c01 100644
+index a254480..578602f 100644
--- a/python/Makefile.am
+++ b/python/Makefile.am
-@@ -47,7 +47,7 @@ install-exec-local:
+@@ -8,6 +8,10 @@ AUTOMAKE_OPTIONS = subdir-objects
+ AM_CPPFLAGS = -I$(srcdir)/../includes
+ AM_CPPFLAGS += -I$(abs_builddir)/../includes/sys
+
++# Add OE's CFLAGS which contains `-fdebug-prefix-map' options to
++# fix build path issue
++AM_CPPFLAGS += $(CFLAGS)
++
+ # Any script in the following variable will get byte-compiled at
+ # install time.
+ pkglibexecpython_PYTHON =
+@@ -47,7 +51,7 @@ install-exec-local:
if HAVE_PYTHON2_PROBES
(cd $(srcdir); CFLAGS="$(AM_CPPFLAGS)" $(PYTHON) setup.py build \
--build-base $(shell readlink -f $(builddir))/py2build \
- install --prefix $(DESTDIR)$(prefix) \
-+ install --prefix $(DESTDIR)$(prefix) --install-lib=$(DESTDIR)${pythondir} \
++ install --root $(DESTDIR) --prefix $(prefix) --prefix $(prefix) --install-lib=${pythondir} \
--single-version-externally-managed \
--record $(shell readlink -f $(builddir))/py2build/install_files.txt \
--verbose)
-@@ -55,7 +55,7 @@ endif
+@@ -55,7 +59,7 @@ endif
if HAVE_PYTHON3_PROBES
(cd $(srcdir); CFLAGS="$(AM_CPPFLAGS)" $(PYTHON3) setup.py build \
--build-base $(shell readlink -f $(builddir))/py3build \
- install --prefix $(DESTDIR)$(prefix) \
-+ install --prefix $(DESTDIR)$(prefix) --install-lib=$(DESTDIR)${python3dir} \
++ install --root $(DESTDIR) --prefix $(prefix) --install-lib=${python3dir} \
--single-version-externally-managed \
--record $(shell readlink -f $(builddir))/py3build/install_files.txt \
--verbose)
--
-2.11.0
+2.7.4
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch
deleted file mode 100644
index 7cd9030ea..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch
+++ /dev/null
@@ -1,128 +0,0 @@
-From 41efad04730be89889d1483719f9a6c9396dc250 Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Wed, 14 Mar 2018 17:05:25 -0500
-Subject: [PATCH] Make sure sysroot paths don't end with a slash.
-
-* session.cxx (parse_cmdline): Make sure a sysroot path does not end with
- a '/', since we build paths like: sysroot + "/lib/modules". If the
- sysroot path ends with a '/', we end up with paths like
- '/SYSROOT//lib/modules'.
- (setup_kernel_release): Take a string parameter, not a character pointer.
-* session.h: Update setup_kernel_release() prototype.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- session.cxx | 34 ++++++++++++++++++++++++++--------
- session.h | 2 +-
- 2 files changed, 27 insertions(+), 9 deletions(-)
-
-Index: git/session.cxx
-===================================================================
---- git.orig/session.cxx
-+++ git/session.cxx
-@@ -722,6 +722,9 @@ systemtap_session::parse_cmdline (int ar
- client_options_disallowed_for_unprivileged = "";
- std::set<std::string> additional_unwindsym_modules;
- struct rlimit our_rlimit;
-+ bool sysroot_option_seen = false;
-+ string kernel_release_value;
-+
- while (true)
- {
- char * num_endptr;
-@@ -887,7 +890,7 @@ systemtap_session::parse_cmdline (int ar
- // Note that '-' must come last in a regex bracket expression.
- assert_regexp_match("-r parameter from client", optarg, "^[a-z0-9_.+-]+$");
- server_args.push_back (string ("-") + (char)grc + optarg);
-- setup_kernel_release(optarg);
-+ kernel_release_value = optarg;
- break;
-
- case 'a':
-@@ -1473,7 +1476,7 @@ systemtap_session::parse_cmdline (int ar
- if (client_options) {
- cerr << _F("ERROR: %s invalid with %s", "--sysroot", "--client-options") << endl;
- return 1;
-- } else if (!sysroot.empty()) {
-+ } else if (sysroot_option_seen) {
- cerr << "ERROR: multiple --sysroot options not supported" << endl;
- return 1;
- } else {
-@@ -1487,11 +1490,17 @@ systemtap_session::parse_cmdline (int ar
-
- sysroot = string(spath);
- free (spath);
-- if (sysroot[sysroot.size() - 1] != '/')
-- sysroot.append("/");
-
-- break;
-+ // We do path creation like this:
-+ // sysroot + "/lib/modules"
-+ // So, we don't want the sysroot path to end with a '/',
-+ // otherwise we'll end up with '/foo//lib/modules'.
-+ if (sysroot.back() == '/') {
-+ sysroot.pop_back();
-+ }
- }
-+ sysroot_option_seen = true;
-+ break;
-
- case LONG_OPT_SYSENV:
- if (client_options) {
-@@ -1501,7 +1510,7 @@ systemtap_session::parse_cmdline (int ar
- string sysenv_str = optarg;
- string value;
- size_t pos;
-- if (sysroot.empty()) {
-+ if (! sysroot_option_seen) {
- cerr << "ERROR: --sysenv must follow --sysroot" << endl;
- return 1;
- }
-@@ -1646,6 +1655,15 @@ systemtap_session::parse_cmdline (int ar
- }
- }
-
-+ if (! kernel_release_value.empty())
-+ {
-+ setup_kernel_release(kernel_release_value);
-+ }
-+ else if (! sysroot.empty())
-+ {
-+ kernel_build_tree = sysroot + "/lib/modules/" + kernel_release + "/build";
-+ }
-+
- return 0;
- }
-
-@@ -2152,7 +2170,7 @@ void systemtap_session::insert_loaded_mo
- }
-
- void
--systemtap_session::setup_kernel_release (const char* kstr)
-+systemtap_session::setup_kernel_release (const string& kstr)
- {
- // Sometimes we may get dupes here... e.g. a server may have a full
- // -r /path/to/kernel followed by a client's -r kernel.
-@@ -2183,7 +2201,7 @@ systemtap_session::setup_kernel_release
- else
- {
- update_release_sysroot = true;
-- kernel_release = string (kstr);
-+ kernel_release = kstr;
- if (!kernel_release.empty())
- kernel_build_tree = "/lib/modules/" + kernel_release + "/build";
-
-Index: git/session.h
-===================================================================
---- git.orig/session.h
-+++ git/session.h
-@@ -144,7 +144,7 @@ public:
-
- // NB: It is very important for all of the above (and below) fields
- // to be cleared in the systemtap_session ctor (session.cxx).
-- void setup_kernel_release (const char* kstr);
-+ void setup_kernel_release (const std::string& kstr);
- void insert_loaded_modules ();
-
- // command line parsing
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch
deleted file mode 100644
index b2820b31e..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-Use-sysroot-when-looking-for-the-System.map-file.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-From 436063d5e4738a9b03535d330a2242be5118e745 Mon Sep 17 00:00:00 2001
-From: David Smith <dsmith@redhat.com>
-Date: Thu, 8 Mar 2018 16:01:58 -0600
-Subject: [PATCH] Use sysroot when looking for the System.map file.
-
-Add sysroot to system_map_path + "/boot/System.map" case. Otherwise
-stap tries to look symbols on host system and it produce error like this:
-
-> Kernel symbol table /boot/System.map-4.9.78-yocto-standard unavailable, (No such file or directory)
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- session.cxx | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-Index: git/session.cxx
-===================================================================
---- git.orig/session.cxx
-+++ git/session.cxx
-@@ -2013,7 +2013,7 @@ systemtap_session::parse_kernel_function
- clog << _F("Kernel symbol table %s unavailable, (%s)",
- system_map_path.c_str(), strerror(errno)) << endl;
-
-- system_map_path = "/boot/System.map-" + kernel_release;
-+ system_map_path = sysroot + "/boot/System.map-" + kernel_release;
- system_map.clear();
- system_map.open(system_map_path.c_str(), ifstream::in);
- if (! system_map.is_open())
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch
deleted file mode 100644
index 98181a129..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch
+++ /dev/null
@@ -1,39 +0,0 @@
-From 183c7a7a8167333c873525f7908913837b8dc3cb Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Tue, 20 Mar 2018 12:41:05 -0500
-Subject: [PATCH] _stp_umodule_relocate needs target file path, not host file
- path
-
-Strip of sysroot from module name is required when _stp_umodule_relocate
-call is generated. Otherwise path won't match path on target and could
-will fail to calculated address within the file.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- loc2stap.cxx | 5 ++++-
- 1 file changed, 4 insertions(+), 1 deletion(-)
-
-diff --git a/loc2stap.cxx b/loc2stap.cxx
-index 4818ee0..e09954f 100644
---- a/loc2stap.cxx
-+++ b/loc2stap.cxx
-@@ -17,6 +17,7 @@
-
- #include "loc2stap.h"
- #include "dwflpp.h"
-+#include "tapsets.h"
-
- #if ! _ELFUTILS_PREREQ(0, 153)
- #define DW_OP_GNU_entry_value 0xf3
-@@ -106,7 +107,9 @@ location_context::translate_address(Dwarf_Addr addr)
- c = "/* pragma:vma */ "
- "({ unsigned long addr = 0; "
- "addr = _stp_umodule_relocate (\""
-- + resolve_path(dw->module_name.c_str()) + "\", "
-+ + path_remove_sysroot(dw->sess,
-+ resolve_path(dw->module_name.c_str()))
-+ + "\", "
- + lex_cast_hex (addr)
- + ", current); addr; })";
- }
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
deleted file mode 100644
index 7996fdde7..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-buildrun-remove-quotes-around-I-include-line.patch
+++ /dev/null
@@ -1,38 +0,0 @@
-From 75c4aec6de3a615909f3283eac585760de101b8c Mon Sep 17 00:00:00 2001
-From: Saul Wold <sgw@linux.intel.com>
-Date: Tue, 7 Mar 2017 10:46:12 -0800
-Subject: [PATCH] buildrun: remove quotes around -I include line
-
-By having the quotes, the kernel Makefile addtree macro adds the
-kernel $srctree directory as a prefix and causes compilation failures.
-Removing the quotes resolves the issue.
-
-This is trimmed from the verbose output of the GCC command line
-Before:
- -I/srv/sdb/builds/4.9/tmp/work-shared/qemux86-64/kernel-source/"/srv/sdb/releases/jethro/builds/4.1/tmp/sysroots/x86_64-linux/usr/share/systemtap/runtime"
-
-After:
- -I/srv/sdb/builds/4.9/tmp/sysroots/x86_64-linux/usr/share/systemtap/runtime
-
-Upstream-Status: Pending
-Signed-off-by: Saul Wold <sgw@linux.intel.com>
----
- buildrun.cxx | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/buildrun.cxx b/buildrun.cxx
-index aaea64c..8a8ee9f 100644
---- a/buildrun.cxx
-+++ b/buildrun.cxx
-@@ -495,7 +495,7 @@ compile_pass (systemtap_session& s)
- #if CHECK_POINTER_ARITH_PR5947
- o << "EXTRA_CFLAGS += -Wpointer-arith" << endl;
- #endif
-- o << "EXTRA_CFLAGS += -I\"" << s.runtime_path << "\"" << endl;
-+ o << "EXTRA_CFLAGS += -I" << s.runtime_path << endl;
- // XXX: this may help ppc toc overflow
- // o << "CFLAGS := $(subst -Os,-O2,$(CFLAGS)) -fminimal-toc" << endl;
- o << "obj-m := " << s.module_name << ".o" << endl;
---
-2.7.4
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch
deleted file mode 100644
index 160642db0..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From b29e448e12040ed8f4d83743a14db0f138a7cc67 Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Wed, 14 Mar 2018 16:54:08 -0500
-Subject: [PATCH] debuginfo lookup with sysroot case do not remove sysroot from
- file_name
-
-If sysroot option is passed, and debug symbols reside in sysroot along
-with executable <foo> in <foo_dir>/.debug/<foo_file> directory,
-stap fails to find debuginfo because it strips out sysroot path
-from file_name so dwfl_standard_find_debuginfo ends up looking at
-host <foo_dir>/.debug/<foo_file> rather then checking
-<sysroot>/<foo_dir>/.debug/<foo_file>.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- setupdwfl.cxx | 12 ------------
- 1 file changed, 12 deletions(-)
-
-diff --git a/setupdwfl.cxx b/setupdwfl.cxx
-index 11e0bb2..2a87982 100644
---- a/setupdwfl.cxx
-+++ b/setupdwfl.cxx
-@@ -627,18 +627,6 @@ internal_find_debuginfo (Dwfl_Module *mod,
-
- call_dwfl_standard_find_debuginfo:
-
-- if (current_session_for_find_debuginfo)
-- {
-- string sysroot = current_session_for_find_debuginfo->sysroot + "/*";
-- int found = fnmatch(sysroot.c_str(), file_name, 0);
--
-- if (found)
-- {
-- file_name = file_name
-- + current_session_for_find_debuginfo->sysroot.length() - 1;
-- }
-- }
--
- /* Call the original dwfl_standard_find_debuginfo */
- return dwfl_standard_find_debuginfo(mod, userdata, modname, base,
- file_name, debuglink_file,
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch
new file mode 100644
index 000000000..15a6f2a9a
--- /dev/null
+++ b/poky/meta/recipes-kernel/systemtap/systemtap/0001-improve-reproducibility-for-c-compiling.patch
@@ -0,0 +1,31 @@
+From 6288ba5df0a8c73ef842b609081449ac4de86123 Mon Sep 17 00:00:00 2001
+From: Hongxu Jia <hongxu.jia@windriver.com>
+Date: Wed, 18 Jul 2018 16:58:33 +0800
+Subject: [PATCH] improve reproducibility for c++ compiling
+
+Use relative dir to include header string_ref to
+strip build path prefix in c++ object file
+
+Upstream-Status: Inappropriate [oe specific]
+
+Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com>
+---
+ stringtable.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/stringtable.h b/stringtable.h
+index 5fc42e7..6fd8a1e 100644
+--- a/stringtable.h
++++ b/stringtable.h
+@@ -19,7 +19,7 @@
+
+ #if defined(HAVE_BOOST_UTILITY_STRING_REF_HPP)
+ #include <boost/version.hpp>
+-#include <boost/utility/string_ref.hpp> //header with string_ref
++#include "@RELATIVE_STAGING_INCDIR@/boost/utility/string_ref.hpp" //header with string_ref
+
+ // XXX: experimental tunables
+ #define INTERNED_STRING_FIND_MEMMEM 1 /* perf stat indicates a very slight benefit */
+--
+2.7.4
+
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch
deleted file mode 100644
index 6fe7d4d1c..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling-follow-u.patch
+++ /dev/null
@@ -1,40 +0,0 @@
-From 7e11f129ff370ce5f39812ce2ae6ce40818a347f Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Thu, 22 Mar 2018 16:02:02 -0500
-Subject: [PATCH] sysroot: fix short release -r option handling follow up
-
-In case of sysroot set and short release -r option it does not make sense
-to pass short release name into dwfl_linux_kernel_report_offline
-function. This function is not aware about sysroot and it won't look for
-kernel modules under sysroot directory.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- setupdwfl.cxx | 10 +++++++++-
- 1 file changed, 9 insertions(+), 1 deletion(-)
-
-diff --git a/setupdwfl.cxx b/setupdwfl.cxx
-index c419afa..0cf5810 100644
---- a/setupdwfl.cxx
-+++ b/setupdwfl.cxx
-@@ -367,7 +367,15 @@ setup_dwfl_kernel (unsigned *modules_found, systemtap_session &s)
- // hard-code this magic here.
- string lib_path = s.sysroot + "/lib/modules/" + s.kernel_release + "/build";
- if (s.kernel_build_tree == lib_path)
-- elfutils_kernel_path = s.kernel_release;
-+ {
-+ if (s.sysroot != "")
-+ // If we have sysroot set does not make sense to pass
-+ // short release to dwfl, it won't take a sysroot into
-+ // account. Let's construct full path in such case.
-+ elfutils_kernel_path = string(s.sysroot + "/lib/modules/" + s.kernel_release);
-+ else
-+ elfutils_kernel_path = s.kernel_release;
-+ }
- else
- elfutils_kernel_path = s.kernel_build_tree;
- offline_modules_found = 0;
---
-2.7.4
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch
deleted file mode 100644
index b31d6274e..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-fix-short-release-r-option-handling.patch
+++ /dev/null
@@ -1,53 +0,0 @@
-From a9ce89bcd2d78728faef59bda60e75510972cd56 Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Wed, 14 Mar 2018 17:09:44 -0500
-Subject: [PATCH] sysroot: fix short release -r option handling
-
-* setupdwfl.cxx (debuginfo_path_insert_sysroot): Add a '/' to the end of
- the sysroot for path_insert_sysroot().
- (setup_dwfl_kernel): Simplify logic when finding the kernel path to send
- to elfutils.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- setupdwfl.cxx | 19 ++++++++++++-------
- 1 file changed, 12 insertions(+), 7 deletions(-)
-
-diff --git a/setupdwfl.cxx b/setupdwfl.cxx
-index 2a87982..f6c3157 100644
---- a/setupdwfl.cxx
-+++ b/setupdwfl.cxx
-@@ -339,6 +339,13 @@ static char * path_insert_sysroot(string sysroot, string path)
-
- void debuginfo_path_insert_sysroot(string sysroot)
- {
-+ // FIXME: This is a short-term fix, until we expect sysroot paths to
-+ // always end with a '/' (and never be empty).
-+ //
-+ // The path_insert_sysroot() function assumes that sysroot has a '/'
-+ // on the end. Make sure that is true.
-+ if (sysroot.back() != '/')
-+ sysroot.push_back('/');
- debuginfo_path = path_insert_sysroot(sysroot, debuginfo_path);
- debuginfo_usr_path = path_insert_sysroot(sysroot, debuginfo_usr_path);
- }
-@@ -358,13 +365,11 @@ setup_dwfl_kernel (unsigned *modules_found, systemtap_session &s)
- // no way to set the dwfl_callback.debuginfo_path and always
- // passs the plain kernel_release here. So instead we have to
- // hard-code this magic here.
-- string lib_path = "/lib/modules/" + s.kernel_release + "/build";
-- if (s.kernel_build_tree == string(s.sysroot + lib_path) ||
-- (s.kernel_build_tree == lib_path
-- && s.sysroot == "/"))
-- elfutils_kernel_path = s.kernel_release;
-- else
-- elfutils_kernel_path = s.kernel_build_tree;
-+ string lib_path = s.sysroot + "/lib/modules/" + s.kernel_release + "/build";
-+ if (s.kernel_build_tree == lib_path)
-+ elfutils_kernel_path = s.kernel_release;
-+ else
-+ elfutils_kernel_path = s.kernel_build_tree;
- offline_modules_found = 0;
-
- // First try to report full path modules.
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch b/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch
deleted file mode 100644
index 8a3d39a5b..000000000
--- a/poky/meta/recipes-kernel/systemtap/systemtap/0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch
+++ /dev/null
@@ -1,117 +0,0 @@
-From 2041085d1a700201dc088991ca8136e7935bf42f Mon Sep 17 00:00:00 2001
-From: Victor Kamensky <kamensky@cisco.com>
-Date: Wed, 21 Mar 2018 11:35:26 -0500
-Subject: [PATCH] sysroot: handle symbolic links with absolute name relative to
- sysroot
-
-In case of symbolic link found under sysroot point to absolute path,
-instead of trying to look for such absolute path in host system,
-apply sysroot prefix first.
-
-Upstream-Status: Backport
-Signed-off-by: Victor Kamensky <kamensky@cisco.com>
----
- util.cxx | 76 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
- 1 file changed, 76 insertions(+)
-
-Index: git/util.cxx
-===================================================================
---- git.orig/util.cxx
-+++ git/util.cxx
-@@ -441,6 +441,64 @@ split_lines(const char *buf, size_t n)
- return lines;
- }
-
-+static string
-+follow_link(const string& name, const string& sysroot)
-+{
-+ char *linkname;
-+ ssize_t r;
-+ string retpath;
-+ struct stat st;
-+
-+ const char *f = name.c_str();
-+
-+ lstat(f, &st);
-+
-+ linkname = (char *) malloc(st.st_size + 1);
-+
-+ if (linkname)
-+ {
-+ r = readlink(f, linkname, st.st_size + 1);
-+ linkname[st.st_size] = '\0';
-+ /*
-+ * If we have non-empty sysroot and we got link that
-+ * points to absolute path name, we need to look at
-+ * this path relative to sysroot itself. access and
-+ * stat will follow symbolic links correctly only in
-+ * case with empty sysroot.
-+ */
-+ while (r != -1 && linkname && linkname[0] == '/')
-+ {
-+ string fname1 = sysroot + linkname;
-+ const char *f1 = fname1.c_str();
-+ if (access(f1, X_OK) == 0
-+ && stat(f1, &st) == 0
-+ && S_ISREG(st.st_mode))
-+ {
-+ retpath = fname1;
-+ break;
-+ }
-+ else if (lstat(f1, &st) == 0
-+ && S_ISLNK(st.st_mode))
-+ {
-+ free(linkname);
-+ linkname = (char *) malloc(st.st_size + 1);
-+ if (linkname)
-+ {
-+ r = readlink(f1, linkname, st.st_size + 1);
-+ linkname[st.st_size] = '\0';
-+ }
-+ }
-+ else
-+ {
-+ break;
-+ }
-+ }
-+ }
-+ free(linkname);
-+
-+ return retpath;
-+}
-+
- // Resolve an executable name to a canonical full path name, with the
- // same policy as execvp(). A program name not containing a slash
- // will be searched along the $PATH.
-@@ -465,6 +523,14 @@ string find_executable(const string& nam
- if (name.find('/') != string::npos) // slash in the path already?
- {
- retpath = sysroot + name;
-+
-+ const char *f = retpath.c_str();
-+ if (sysroot != ""
-+ && lstat(f, &st) == 0
-+ && S_ISLNK(st.st_mode))
-+ {
-+ retpath = follow_link(f, sysroot);
-+ }
- }
- else // Nope, search $PATH.
- {
-@@ -493,6 +559,16 @@ string find_executable(const string& nam
- retpath = fname;
- break;
- }
-+ else if (sysroot != ""
-+ && lstat(f, &st) == 0
-+ && S_ISLNK(st.st_mode))
-+ {
-+ retpath = follow_link(f, sysroot);
-+ if (retpath != "")
-+ {
-+ break;
-+ }
-+ }
- }
- }
- }
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch b/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch
index b7ee0701b..9313a5aba 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch
+++ b/poky/meta/recipes-kernel/systemtap/systemtap/monitor-option.patch
@@ -13,18 +13,18 @@ Signed-off-by: Ross Burton <ross.burton@intel.com>
configure.ac | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
-diff --git a/configure.ac b/configure.ac
-index 6bd0c5fc4..2ea9b3cbf 100644
---- a/configure.ac
-+++ b/configure.ac
-@@ -752,13 +752,16 @@ dnl We want either (or both) python probe support.
+Index: git/configure.ac
+===================================================================
+--- git.orig/configure.ac
++++ git/configure.ac
+@@ -766,13 +766,16 @@ dnl We want either (or both) python prob
AM_CONDITIONAL([HAVE_PYTHON_PROBES],
[test "x$have_python2_support" = "xyes" -o "x$have_python3_support" = "xyes"])
+AC_ARG_ENABLE([monitor], AS_HELP_STRING([--disable-monitor],[Disable monitor]))
+if test "$enable_monitor" != "no"; then
dnl Check for presence of json-c and ncurses for use in monitor mode
- PKG_CHECK_MODULES([jsonc], [json-c >= 0.12], [have_jsonc=yes], [have_jsonc=no])
+ PKG_CHECK_MODULES([jsonc], [json-c >= 0.11], [have_jsonc=yes], [have_jsonc=no])
PKG_CHECK_MODULES([ncurses], [ncurses], [have_ncurses=yes], [have_ncurses=no])
-AM_CONDITIONAL([HAVE_MONITOR_LIBS], [test "${have_jsonc}" == "yes" -a "${have_ncurses}" == "yes"])
if test "${have_jsonc}" == "yes" -a "${have_ncurses}" == yes; then
@@ -35,6 +35,3 @@ index 6bd0c5fc4..2ea9b3cbf 100644
AC_CACHE_CHECK([for assembler .section "?" flags support], stap_cv_sectionq, [
old_CFLAGS="$CFLAGS"
---
-2.11.0
-
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap_git.bb b/poky/meta/recipes-kernel/systemtap/systemtap_git.bb
index b280f583e..6ee3e1c0f 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap_git.bb
+++ b/poky/meta/recipes-kernel/systemtap/systemtap_git.bb
@@ -3,6 +3,8 @@ HOMEPAGE = "https://sourceware.org/systemtap/"
require systemtap_git.inc
+SRC_URI += "file://0001-improve-reproducibility-for-c-compiling.patch"
+
DEPENDS = "elfutils"
EXTRA_OECONF += "--with-libelf=${STAGING_DIR_TARGET} --without-rpm \
@@ -23,7 +25,24 @@ PACKAGECONFIG[sqlite] = "--enable-sqlite,--disable-sqlite,sqlite3"
PACKAGECONFIG[monitor] = "--enable-monitor,--disable-monitor,ncurses json-c"
PACKAGECONFIG[python3-probes] = "--with-python3-probes,--without-python3-probes,python3-setuptools-native"
-inherit autotools gettext pkgconfig distutils3-base
+inherit autotools gettext pkgconfig distutils3-base systemd
+
+PACKAGES =+ "${PN}-exporter"
+
+FILES_${PN}-exporter = "${sysconfdir}/stap-exporter/* \
+ ${sysconfdir}/sysconfig/stap-exporter \
+ ${systemd_unitdir}/system/stap-exporter.service \
+ ${sbindir}/stap-exporter"
+
+RDEPENDS_${PN}-exporter = "${PN} python3-core python3-netclient"
+
+SYSTEMD_SERVICE_${PN}-exporter = "stap-exporter.service"
+
+do_configure_prepend () {
+ # Improve reproducibility for c++ object files
+ reltivepath="${@os.path.relpath(d.getVar('STAGING_INCDIR'), d.getVar('S'))}"
+ sed -i "s:@RELATIVE_STAGING_INCDIR@:$reltivepath:g" ${S}/stringtable.h
+}
do_install_append () {
if [ ! -f ${D}${bindir}/stap ]; then
@@ -31,6 +50,14 @@ do_install_append () {
rm -rf ${D}${datadir}/${PN}
rm ${D}${libexecdir}/${PN}/stap-env
fi
+
+ # Fix makefile hardcoded path assumptions for systemd (assumes $prefix)
+ install -d `dirname ${D}${systemd_unitdir}`
+ mv ${D}${prefix}/lib/systemd `dirname ${D}${systemd_unitdir}`
+ rmdir ${D}${prefix}/lib --ignore-fail-on-non-empty
+
+ # Ensure correct ownership for files copied in
+ chown root:root ${D}${sysconfdir}/stap-exporter/* -R
}
BBCLASSEXTEND = "nativesdk"
diff --git a/poky/meta/recipes-kernel/systemtap/systemtap_git.inc b/poky/meta/recipes-kernel/systemtap/systemtap_git.inc
index e2f5204a0..274fcde5c 100644
--- a/poky/meta/recipes-kernel/systemtap/systemtap_git.inc
+++ b/poky/meta/recipes-kernel/systemtap/systemtap_git.inc
@@ -1,7 +1,7 @@
LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
-SRCREV = "4051c70c9318c837981384cbb23f3e9eb1bd0892"
-PV = "3.2"
+SRCREV = "428f84e9e656bce71018e8902e4edb8aacafcc0e"
+PV = "4.0"
SRC_URI = "git://sourceware.org/git/systemtap.git \
file://configure-allow-to-disable-libvirt.patch \
@@ -10,19 +10,7 @@ SRC_URI = "git://sourceware.org/git/systemtap.git \
file://no-msgfmt-check.patch \
file://0001-Do-not-let-configure-write-a-python-location-into-th.patch \
file://0001-Install-python-modules-to-correct-library-dir.patch \
- file://0001-buildrun-remove-quotes-around-I-include-line.patch \
file://0001-staprun-stapbpf-don-t-support-installing-a-non-root.patch \
- file://0001-Fix-PR22551-by-updating-the-use-of-timers-for-the-4..patch \
- file://0001-Fixes-for-gcc-8.patch \
- file://0001-Use-sysroot-when-looking-for-the-System.map-file.patch \
- file://0001-debuginfo-lookup-with-sysroot-case-do-not-remove-sys.patch \
- file://0001-Make-sure-sysroot-paths-don-t-end-with-a-slash.patch \
- file://0001-sysroot-fix-short-release-r-option-handling.patch \
- file://0001-Delay-adding-sysroot-path-to-module-name-in-case-of-.patch \
- file://0001-Added-a-couple-of-small-sysroot-fixes.patch \
- file://0001-_stp_umodule_relocate-needs-target-file-path-not-hos.patch \
- file://0001-sysroot-handle-symbolic-links-with-absolute-name-rel.patch \
- file://0001-sysroot-fix-short-release-r-option-handling-follow-u.patch \
"
COMPATIBLE_HOST = '(x86_64|i.86|powerpc|arm|aarch64|microblazeel|mips).*-linux'
diff --git a/poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb b/poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb
deleted file mode 100644
index 9a5e8006c..000000000
--- a/poky/meta/recipes-kernel/trace-cmd/kernelshark_git.bb
+++ /dev/null
@@ -1,33 +0,0 @@
-SUMMARY = "Graphical trace viewer for Ftrace"
-LICENSE = "GPLv2"
-
-require trace-cmd.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
- file://kernel-shark.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e"
-
-DEPENDS = "gtk+ libxml2"
-RDEPENDS_${PN} = "trace-cmd"
-
-inherit distro_features_check
-ANY_OF_DISTRO_FEATURES = "${GTK2DISTROFEATURES}"
-
-EXTRA_OEMAKE = "\
- 'prefix=${prefix}' \
- 'bindir_relative=${@oe.path.relative(prefix, bindir)}' \
- 'libdir=${libdir}' \
- NO_PYTHON=1 \
- gui \
-"
-do_configure_prepend() {
- # Make sure the recompile is OK
- rm -f ${B}/.*.d
-}
-
-do_install() {
- oe_runmake DESTDIR="${D}" install_gui
- rm ${D}${bindir}/trace-cmd
- rm -rf ${D}${libdir}/trace-cmd
- rm -rf ${D}${sysconfdir}/bash_completion.d/trace-cmd.bash
- rmdir ${D}${libdir}
-}
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc b/poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc
deleted file mode 100644
index 0a1789c45..000000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd.inc
+++ /dev/null
@@ -1,13 +0,0 @@
-SRCREV = "7d0147bbba3ed1d5ef6eea4eec3f0ad4c98f02b5"
-PV = "2.7"
-
-inherit pkgconfig
-
-FILESEXTRAPATHS =. "${FILE_DIRNAME}/trace-cmd:"
-
-SRC_URI = "git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/trace-cmd.git \
- file://blktrace-api-compatibility.patch \
- file://0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch \
-"
-
-S = "${WORKDIR}/git"
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch b/poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch
deleted file mode 100644
index 576308356..000000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/0001-Include-limits.h-so-that-PATH_MAX-is-defined-an-issu.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From 9488f92c1d0c7931c3e17950d1f9eea2aeb3e2bd Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Wed, 14 Jun 2017 15:56:18 +0300
-Subject: [PATCH] Include limits.h so that PATH_MAX is defined (an issue on
- musl).
-
-Upstream-Status: Pending
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- trace-listen.c | 1 +
- 1 file changed, 1 insertion(+)
-
-diff --git a/trace-listen.c b/trace-listen.c
-index 17ff9d8..838d6bc 100644
---- a/trace-listen.c
-+++ b/trace-listen.c
-@@ -31,6 +31,7 @@
- #include <fcntl.h>
- #include <signal.h>
- #include <errno.h>
-+#include <limits.h>
-
- #include "trace-local.h"
- #include "trace-msg.h"
---
-2.11.0
-
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch b/poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
deleted file mode 100644
index 320db6a32..000000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd/blktrace-api-compatibility.patch
+++ /dev/null
@@ -1,29 +0,0 @@
-trace-cmd: Add blktrace_api compatibility for TC_BARRIER
-
-Newer kernels replace TC_BARRIER with TC_FLUSH. Ensure trace-cmd
-can build regardless of the linux-kernel-headers version.
-
-Upstream-Status: Inappropriate [Stop gap]
-
-Signed-off-by: Darren Hart <dvhart@linux.intel.com>
-
-diff --git a/plugin_blk.c b/plugin_blk.c
-index 9327b17..c8e5e1c 100644
---- a/plugin_blk.c
-+++ b/plugin_blk.c
-@@ -44,6 +44,15 @@ struct blk_data {
- unsigned short pdu_len;
- };
-
-+/*
-+ * Newer kernels don't define BLK_TC_BARRIER and have replaced it with
-+ * BLK_TC_FLUSH. In this case, define it here and report FLUSHES as BARRIERS as
-+ * a workaround, as described in:
-+ * http://git.kernel.org/?p=linux/kernel/git/torvalds/linux.git;a=commit;h=c09c47caedc9854d59378d6e34c989e51cfdd2b4
-+ */
-+#ifndef BLK_TC_BARRIER
-+#define BLK_TC_BARRIER 1<<2
-+#endif
- static void fill_rwbs(char *rwbs, int action, unsigned int bytes)
- {
- int i = 0;
diff --git a/poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb b/poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb
deleted file mode 100644
index 27c7c1975..000000000
--- a/poky/meta/recipes-kernel/trace-cmd/trace-cmd_git.bb
+++ /dev/null
@@ -1,34 +0,0 @@
-SUMMARY = "User interface to Ftrace"
-HOMEPAGE = "http://git.kernel.org/"
-LICENSE = "GPLv2 & LGPLv2.1"
-
-require trace-cmd.inc
-
-LIC_FILES_CHKSUM = "file://COPYING;md5=751419260aa954499f7abaabaa882bbe \
- file://trace-cmd.c;beginline=6;endline=8;md5=2c22c965a649ddd7973d7913c5634a5e \
- file://COPYING.LIB;md5=edb195fe538e4552c1f6ca0fd7bf4f0a \
- file://trace-input.c;beginline=5;endline=8;md5=3ec82f43bbe0cfb5951ff414ef4d44d0 \
-"
-
-EXTRA_OEMAKE = "\
- 'prefix=${prefix}' \
- 'bindir=${bindir}' \
- 'man_dir=${mandir}' \
- 'html_install=${datadir}/kernelshark/html' \
- 'img_install=${datadir}/kernelshark/html/images' \
- \
- 'bindir_relative=${@oe.path.relative(prefix, bindir)}' \
- 'libdir=${libdir}' \
- \
- NO_PYTHON=1 \
-"
-
-do_compile_prepend() {
- # Make sure the recompile is OK
- rm -f ${B}/.*.d
-}
-
-do_install() {
- oe_runmake DESTDIR="${D}" install
-}
-
OpenPOWER on IntegriCloud