diff options
author | Laura Abbott <labbott@redhat.com> | 2018-07-06 02:49:37 +0200 |
---|---|---|
committer | Masahiro Yamada <yamada.masahiro@socionext.com> | 2018-07-17 18:18:05 +0200 |
commit | 9afb719e7046c4f2462278862ab3db2961cc141c (patch) | |
tree | 1c80da67479e528cddc6db97a0ed7397e2afc1a0 /init/version.c | |
parent | kbuild: verify that $DEPMOD is installed (diff) | |
download | linux-9afb719e7046c4f2462278862ab3db2961cc141c.tar.xz linux-9afb719e7046c4f2462278862ab3db2961cc141c.zip |
kbuild: Add build salt to the kernel and modules
In Fedora, the debug information is packaged separately (foo-debuginfo) and
can be installed separately. There's been a long standing issue where only
one version of a debuginfo info package can be installed at a time. There's
been an effort for Fedora for parallel debuginfo to rectify this problem.
Part of the requirement to allow parallel debuginfo to work is that build ids
are unique between builds. The existing upstream rpm implementation ensures
this by re-calculating the build-id using the version and release as a
seed. This doesn't work 100% for the kernel because of the vDSO which is
its own binary and doesn't get updated when embedded.
Fix this by adding some data in an ELF note for both the kernel and modules.
The data is controlled via a Kconfig option so distributions can set it
to an appropriate value to ensure uniqueness between builds.
Suggested-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Signed-off-by: Laura Abbott <labbott@redhat.com>
Signed-off-by: Masahiro Yamada <yamada.masahiro@socionext.com>
Diffstat (limited to 'init/version.c')
-rw-r--r-- | init/version.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/init/version.c b/init/version.c index bfb4e3f4955e..ef4012ec4375 100644 --- a/init/version.c +++ b/init/version.c @@ -7,6 +7,7 @@ */ #include <generated/compile.h> +#include <linux/build-salt.h> #include <linux/export.h> #include <linux/uts.h> #include <linux/utsname.h> @@ -49,3 +50,5 @@ const char linux_proc_banner[] = "%s version %s" " (" LINUX_COMPILE_BY "@" LINUX_COMPILE_HOST ")" " (" LINUX_COMPILER ") %s\n"; + +BUILD_SALT; |