From: Cameron Gutman Date: Sat, 23 Jul 2022 02:04:46 +0000 (-0500) Subject: armcap: skip probing _armv7_tick() X-Git-Tag: openssl-3.2.0-alpha1~1971 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f2ec24c9e7c3df55fba97336594a5e815c342b01;p=thirdparty%2Fopenssl.git armcap: skip probing _armv7_tick() Detection of this feature is unreliable so only use it if requested. Reviewed-by: Paul Dale Reviewed-by: Dmitry Belyavskiy Reviewed-by: Hugo Landau (Merged from https://github.com/openssl/openssl/pull/18852) --- diff --git a/crypto/armcap.c b/crypto/armcap.c index 7e6cd8fe907..0aa11baed4b 100644 --- a/crypto/armcap.c +++ b/crypto/armcap.c @@ -357,11 +357,11 @@ void OPENSSL_cpuid_setup(void) # endif # endif - /* Things that getauxval didn't tell us */ - if (sigsetjmp(ill_jmp, 1) == 0) { - _armv7_tick(); - OPENSSL_armcap_P |= ARMV7_TICK; - } + /* + * Probing for ARMV7_TICK is known to produce unreliable results, + * so we will only use the feature when the user explicitly enables + * it with OPENSSL_armcap. + */ sigaction(SIGILL, &ill_oact, NULL); sigprocmask(SIG_SETMASK, &oset, NULL);