aboutsummaryrefslogtreecommitdiff
path: root/csu
diff options
context:
space:
mode:
authorAdhemerval Zanella <adhemerval.zanella@linaro.org>2022-02-21 08:32:32 -0300
committerAdhemerval Zanella <adhemerval.zanella@linaro.org>2022-05-16 15:03:49 -0300
commitb46d250656794e63a2946c481fda29271342dd1a (patch)
treec2e056aa6ae5eb18f79a356b4bbd2f645446291c /csu
parent97a912f7a832a662960749948049e15f3aecb2a7 (diff)
downloadglibc-b46d250656794e63a2946c481fda29271342dd1a.tar
glibc-b46d250656794e63a2946c481fda29271342dd1a.tar.gz
glibc-b46d250656794e63a2946c481fda29271342dd1a.tar.bz2
glibc-b46d250656794e63a2946c481fda29271342dd1a.zip
Remove kernel version check
The kernel version check is used to avoid glibc to run on older kernels where some syscall are not available and fallback code are not enabled to handle graciously fail. However, it does not prevent if the kernel does not correctly advertise its version through vDSO note, uname or procfs. Also kernel version checks are sometime not desirable by users, where they want to deploy on different system with different kernel version knowing the minimum set of syscall is always presented on such systems. The kernel version check has been removed along with the LD_ASSUME_KERNEL environment variable. The minimum kernel used to built glibc is still provided through NT_GNU_ABI_TAG ELF note and also printed when libc.so is issued. Checked on x86_64-linux-gnu.
Diffstat (limited to 'csu')
-rw-r--r--csu/libc-start.c8
-rw-r--r--csu/version.c3
2 files changed, 3 insertions, 8 deletions
diff --git a/csu/libc-start.c b/csu/libc-start.c
index b34bb6dbbc..543560f36c 100644
--- a/csu/libc-start.c
+++ b/csu/libc-start.c
@@ -313,14 +313,6 @@ LIBC_START_MAIN (int (*main) (int, char **, char ** MAIN_AUXVEC_DECL),
__stack_chk_guard = stack_chk_guard;
# endif
-# ifdef DL_SYSDEP_OSCHECK
- {
- /* This needs to run to initiliaze _dl_osversion before TLS
- setup might check it. */
- DL_SYSDEP_OSCHECK (__libc_fatal);
- }
-# endif
-
/* Initialize libpthread if linked in. */
if (__pthread_initialize_minimal != NULL)
__pthread_initialize_minimal ();
diff --git a/csu/version.c b/csu/version.c
index 0de4df5b3f..8c0ed79c01 100644
--- a/csu/version.c
+++ b/csu/version.c
@@ -33,6 +33,9 @@ Compiled by GNU CC version "__VERSION__".\n"
#ifdef LIBC_ABIS_STRING
LIBC_ABIS_STRING
#endif
+#ifdef __LINUX_KERNEL_VERSION_STR
+"Minimum supported kernel: " __LINUX_KERNEL_VERSION_STR "\n"
+#endif
"For bug reporting instructions, please see:\n\
"REPORT_BUGS_TO".\n";