]> git.ipfire.org Git - thirdparty/glibc.git/commitdiff
aarch64: Ignore GCS property of ld.so
authorSzabolcs Nagy <szabolcs.nagy@arm.com>
Wed, 10 Jan 2024 16:20:24 +0000 (16:20 +0000)
committerYury Khrustalev <yury.khrustalev@arm.com>
Mon, 20 Jan 2025 09:36:19 +0000 (09:36 +0000)
check_gcs is called for each dependency of a DSO, but the GNU property
of the ld.so is not processed so ldso->l_mach.gcs may not be correct.
Just assume ld.so is GCS compatible independently of the ELF marking.

Reviewed-by: Wilco Dijkstra <Wilco.Dijkstra@arm.com>
sysdeps/aarch64/dl-gcs.c

index 28febf93cdc9a632631eaccbfc26e9938ea9cceb..4ac86a5d6fffc2bd63b1c04cfad64cc916d51438 100644 (file)
@@ -53,6 +53,11 @@ unsupported (void)
 static bool
 check_gcs (struct link_map *l, const char *program, bool enforced)
 {
+#ifdef SHARED
+  /* Ignore GCS marking on ld.so: its properties are not processed.  */
+  if (is_rtld_link_map (l->l_real))
+    return true;
+#endif
   /* Binary is marked, all good.  */
   if (l->l_mach.gcs)
     return true;