about summary refs log tree commit diff
path: root/sysdeps/x86
diff options
context:
space:
mode:
authorH.J. Lu <hjl.tools@gmail.com>2023-12-19 16:01:33 -0800
committerH.J. Lu <hjl.tools@gmail.com>2023-12-19 16:01:33 -0800
commit50bef9bd63e7fb94f1d2cc8b7809256ffc73b2ef (patch)
treedcbc520df5ff423cffbf6d9693f4815b529592e0 /sysdeps/x86
parent46432be2f1d4de962b51ca6b9f80fc37744be9f7 (diff)
downloadglibc-50bef9bd63e7fb94f1d2cc8b7809256ffc73b2ef.tar.gz
glibc-50bef9bd63e7fb94f1d2cc8b7809256ffc73b2ef.tar.xz
glibc-50bef9bd63e7fb94f1d2cc8b7809256ffc73b2ef.zip
Fix elf: Do not duplicate the GLIBC_TUNABLES string
commit 2a969b53c0b02fed7e43473a92f219d737fd217a
Author: Adhemerval Zanella <adhemerval.zanella@linaro.org>
Date:   Wed Dec 6 10:24:01 2023 -0300

    elf: Do not duplicate the GLIBC_TUNABLES string

has

@@ -38,7 +39,7 @@
    which isn't available.  */
 #define CHECK_GLIBC_IFUNC_PREFERRED_OFF(f, cpu_features, name, len) \
   _Static_assert (sizeof (#name) - 1 == len, #name " != " #len); \
-  if (memcmp (f, #name, len) == 0)             \
+  if (tunable_str_comma_strcmp_cte (&f, #name) == 0)       \
     {                           \
       cpu_features->preferred[index_arch_##name]        \
   &= ~bit_arch_##name;                \
@@ -46,12 +47,11 @@

Fix it by removing "== 0" after tunable_str_comma_strcmp_cte.
Diffstat (limited to 'sysdeps/x86')
-rw-r--r--sysdeps/x86/cpu-tunables.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/x86/cpu-tunables.c b/sysdeps/x86/cpu-tunables.c
index ef96148d30..142c6b9240 100644
--- a/sysdeps/x86/cpu-tunables.c
+++ b/sysdeps/x86/cpu-tunables.c
@@ -39,7 +39,7 @@
    which isn't available.  */
 #define CHECK_GLIBC_IFUNC_PREFERRED_OFF(f, cpu_features, name, len)	\
   _Static_assert (sizeof (#name) - 1 == len, #name " != " #len);	\
-  if (tunable_str_comma_strcmp_cte (&f, #name) == 0)			\
+  if (tunable_str_comma_strcmp_cte (&f, #name))				\
     {									\
       cpu_features->preferred[index_arch_##name]			\
 	&= ~bit_arch_##name;						\