diff options
author | Bruce Ashfield <bruce.ashfield@gmail.com> | 2019-08-14 11:31:31 -0400 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2019-08-21 15:29:01 +0100 |
commit | 00ad844fe9279cc5c9005e3d096a9f4de0f33a4c (patch) | |
tree | aaf8b2736c6cb44274e4cd38d8b0a983bd31a186 /meta/recipes-kernel | |
parent | ad525ae2ddb68cd550ac5e888f63c70953ae6940 (diff) | |
download | poky-00ad844fe9279cc5c9005e3d096a9f4de0f33a4c.tar.gz |
linux-yocto: arch/x86/boot: use prefix map to avoid embedded paths
>From the kernel patch:
[
It was observed that the kernel embeds the path in the x86 boot
artifacts.
From https://bugzilla.yoctoproject.org/show_bug.cgi?id=13458:
[
If you turn on the buildpaths QA test, or try a reproducible build, you
discover that the kernel image contains build paths.
$ strings bzImage-5.0.19-yocto-standard |grep tmp/
out of pgt_buf in
/data/poky-tmp/reproducible/tmp/work-shared/qemux86-64/kernel-source/arch/x86/boot/compressed/kaslr_64.c!?
But what's this in the top-level Makefile:
$ git grep prefix-map
Makefile:KBUILD_CFLAGS += $(call
cc-option,-fmacro-prefix-map=$(srctree)/=)
So the __FILE__ shouldn't be using the full path. However
arch/x86/boot/compressed/Makefile has this:
KBUILD_CFLAGS := -m$(BITS) -O2
So that clears KBUILD_FLAGS, removing the -fmacro-prefix-map option.
]
Other architectures do not clear the flags, but instead prune before
adding boot or specific options. There's no obvious reason why x86 isn't
doing the same thing (pruning vs clearing) and no build or boot issues
have been observed.
So we make x86 can do the same thing, and we no longer have embedded paths.
]
This issue has been reported upstream, and a patch submission is
pending, but for now, we'll soak the proposed patch in linux-yocto to
see if any issues are found
[YOCTO: #13458]
(From OE-Core rev: 78b0ff5960814af935a8089ec49c51d76f148149)
Signed-off-by: Bruce Ashfield <bruce.ashfield@gmail.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-kernel')
-rw-r--r-- | meta/recipes-kernel/linux/linux-yocto-rt_5.0.bb | 4 | ||||
-rw-r--r-- | meta/recipes-kernel/linux/linux-yocto-tiny_5.0.bb | 6 | ||||
-rw-r--r-- | meta/recipes-kernel/linux/linux-yocto_5.0.bb | 18 |
3 files changed, 14 insertions, 14 deletions
diff --git a/meta/recipes-kernel/linux/linux-yocto-rt_5.0.bb b/meta/recipes-kernel/linux/linux-yocto-rt_5.0.bb index 9e822f2e7f..f66ee6f4ad 100644 --- a/meta/recipes-kernel/linux/linux-yocto-rt_5.0.bb +++ b/meta/recipes-kernel/linux/linux-yocto-rt_5.0.bb | |||
@@ -11,8 +11,8 @@ python () { | |||
11 | raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it") | 11 | raise bb.parse.SkipRecipe("Set PREFERRED_PROVIDER_virtual/kernel to linux-yocto-rt to enable it") |
12 | } | 12 | } |
13 | 13 | ||
14 | SRCREV_machine ?= "9c1e84c9b81b6bf1df55f26f2e0517266c37f7eb" | 14 | SRCREV_machine ?= "e6cb812b5532630b6fc6dfd7778d57a4907d3180" |
15 | SRCREV_meta ?= "c2e34d9ab2894edc6abc6be9ac89907bf4348447" | 15 | SRCREV_meta ?= "96c82f3d7ab25a3f44e517f9dbbb53e2c4c45729" |
16 | 16 | ||
17 | SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \ | 17 | SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;branch=${KBRANCH};name=machine \ |
18 | git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.0;destsuffix=${KMETA}" | 18 | git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.0;destsuffix=${KMETA}" |
diff --git a/meta/recipes-kernel/linux/linux-yocto-tiny_5.0.bb b/meta/recipes-kernel/linux/linux-yocto-tiny_5.0.bb index a1719651b6..42e0dcd603 100644 --- a/meta/recipes-kernel/linux/linux-yocto-tiny_5.0.bb +++ b/meta/recipes-kernel/linux/linux-yocto-tiny_5.0.bb | |||
@@ -15,9 +15,9 @@ DEPENDS += "openssl-native util-linux-native" | |||
15 | KMETA = "kernel-meta" | 15 | KMETA = "kernel-meta" |
16 | KCONF_BSP_AUDIT_LEVEL = "2" | 16 | KCONF_BSP_AUDIT_LEVEL = "2" |
17 | 17 | ||
18 | SRCREV_machine_qemuarm ?= "fabee455f397ba8054f35a3ad5f2250bbad93bef" | 18 | SRCREV_machine_qemuarm ?= "b9001287984b0066814c8739f38d629de73739b7" |
19 | SRCREV_machine ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 19 | SRCREV_machine ?= "55dd15336b7301b686a0c183f5372b49c1003d03" |
20 | SRCREV_meta ?= "c2e34d9ab2894edc6abc6be9ac89907bf4348447" | 20 | SRCREV_meta ?= "96c82f3d7ab25a3f44e517f9dbbb53e2c4c45729" |
21 | 21 | ||
22 | PV = "${LINUX_VERSION}+git${SRCPV}" | 22 | PV = "${LINUX_VERSION}+git${SRCPV}" |
23 | 23 | ||
diff --git a/meta/recipes-kernel/linux/linux-yocto_5.0.bb b/meta/recipes-kernel/linux/linux-yocto_5.0.bb index 0e4a372d2d..ea4b6f5b33 100644 --- a/meta/recipes-kernel/linux/linux-yocto_5.0.bb +++ b/meta/recipes-kernel/linux/linux-yocto_5.0.bb | |||
@@ -12,16 +12,16 @@ KBRANCH_qemux86 ?= "v5.0/standard/base" | |||
12 | KBRANCH_qemux86-64 ?= "v5.0/standard/base" | 12 | KBRANCH_qemux86-64 ?= "v5.0/standard/base" |
13 | KBRANCH_qemumips64 ?= "v5.0/standard/mti-malta64" | 13 | KBRANCH_qemumips64 ?= "v5.0/standard/mti-malta64" |
14 | 14 | ||
15 | SRCREV_machine_qemuarm ?= "9161b2fa2f1cec0ba02976c389c788445858e0de" | 15 | SRCREV_machine_qemuarm ?= "d1ed980ad989252d42386c8bc63b2f5f11985ea4" |
16 | SRCREV_machine_qemuarm64 ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 16 | SRCREV_machine_qemuarm64 ?= "55dd15336b7301b686a0c183f5372b49c1003d03" |
17 | SRCREV_machine_qemumips ?= "7de9b8f0db98e51a666477c8e2b64f1964b45410" | 17 | SRCREV_machine_qemumips ?= "1520e78195e64f27be46a46a8d6711c8470fb083" |
18 | SRCREV_machine_qemuppc ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 18 | SRCREV_machine_qemuppc ?= "55dd15336b7301b686a0c183f5372b49c1003d03" |
19 | SRCREV_machine_qemuriscv64 ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 19 | SRCREV_machine_qemuriscv64 ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" |
20 | SRCREV_machine_qemux86 ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 20 | SRCREV_machine_qemux86 ?= "55dd15336b7301b686a0c183f5372b49c1003d03" |
21 | SRCREV_machine_qemux86-64 ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 21 | SRCREV_machine_qemux86-64 ?= "55dd15336b7301b686a0c183f5372b49c1003d03" |
22 | SRCREV_machine_qemumips64 ?= "5a8b27bcc0b16077ab8edfcd3fb25c80dc2c652e" | 22 | SRCREV_machine_qemumips64 ?= "9d4105b32cf123a861bc754377d2f2e156278a7e" |
23 | SRCREV_machine ?= "00638cdd8f92869a0f89ebe3289fdbd856ba9458" | 23 | SRCREV_machine ?= "55dd15336b7301b686a0c183f5372b49c1003d03" |
24 | SRCREV_meta ?= "c2e34d9ab2894edc6abc6be9ac89907bf4348447" | 24 | SRCREV_meta ?= "96c82f3d7ab25a3f44e517f9dbbb53e2c4c45729" |
25 | 25 | ||
26 | # remap qemuarm to qemuarma15 for the 5.0 kernel | 26 | # remap qemuarm to qemuarma15 for the 5.0 kernel |
27 | # KMACHINE_qemuarm ?= "qemuarma15" | 27 | # KMACHINE_qemuarm ?= "qemuarma15" |