Skip to content

Commit

Permalink
x86: Add build salt to the vDSO
Browse files Browse the repository at this point in the history
The vDSO needs to have a unique build id in a similar manner
to the kernel and modules. Use the build salt macro.

Acked-by: Andy Lutomirski <[email protected]>
Signed-off-by: Laura Abbott <[email protected]>
Signed-off-by: Masahiro Yamada <[email protected]>
  • Loading branch information
labbott authored and masahir0y committed Jul 17, 2018
1 parent 9afb719 commit d623f60
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 0 deletions.
3 changes: 3 additions & 0 deletions arch/x86/entry/vdso/vdso-note.S
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@
* Here we can supply some information useful to userland.
*/

#include <linux/build-salt.h>
#include <linux/uts.h>
#include <linux/version.h>
#include <linux/elfnote.h>

ELFNOTE_START(Linux, 0, "a")
.long LINUX_VERSION_CODE
ELFNOTE_END

BUILD_SALT
3 changes: 3 additions & 0 deletions arch/x86/entry/vdso/vdso32/note.S
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
* Here we can supply some information useful to userland.
*/

#include <linux/build-salt.h>
#include <linux/version.h>
#include <linux/elfnote.h>

Expand All @@ -14,6 +15,8 @@ ELFNOTE_START(Linux, 0, "a")
.long LINUX_VERSION_CODE
ELFNOTE_END

BUILD_SALT

#ifdef CONFIG_XEN
/*
* Add a special note telling glibc's dynamic linker a fake hardware
Expand Down

0 comments on commit d623f60

Please sign in to comment.