ld.so: Add architecture specific fields

System Internals / glibc - H.J. Lu [gmail.com] - 13 November 2017 16:02 EST

To support Intel Control-flow Enforcement Technology (CET) run-time control:

1. An architecture specific field in the writable ld.so namespace is needed to indicate if CET features are enabled at run-time. 2. An architecture specific field in struct link_map is needed if CET features are enabled in an ELF module.

This patch adds dl-procruntime.c to the writable ld.so namespace and link_map.h to struct link_map.

Tested with build-many-glibcs.py.

- elf/dl-support.c: Include .
- include/link.h: Include .
- sysdeps/generic/dl-procruntime.c: New file.
- sysdeps/generic/link_map.h: Likewise.
- sysdeps/generic/ldsodefs.h: Include in the writable ld.so namespace.

4a306ef1c8 ld.so: Add architecture specific fields
ChangeLog | 9 +++++++++
elf/dl-support.c | 1 +
include/link.h | 2 ++
sysdeps/generic/dl-procruntime.c | 1 +
sysdeps/generic/ldsodefs.h | 11 +++++++----
sysdeps/generic/link_map.h | 1 +
6 files changed, 21 insertions(+), 4 deletions(-)

Upstream: sourceware.org


  • Share