diff options
author | jsing <> | 2024-10-17 14:09:29 +0000 |
---|---|---|
committer | jsing <> | 2024-10-17 14:09:29 +0000 |
commit | 3f67c2a09f63d9b79af4479ddb350c665f82747f (patch) | |
tree | 077fc09a38f262447f8f4afb6e037df98692cf43 /src | |
parent | 46b9e823a03f4d0f680a05c9f7d55e5277120920 (diff) | |
download | openbsd-3f67c2a09f63d9b79af4479ddb350c665f82747f.tar.gz openbsd-3f67c2a09f63d9b79af4479ddb350c665f82747f.tar.bz2 openbsd-3f67c2a09f63d9b79af4479ddb350c665f82747f.zip |
Remove run once code from OPENSSL_cpuid_setup().
OPENSSL_cpuid_setup() is no longer exported and is now only ever run under
pthread_once().
ok joshua@ tb@
Diffstat (limited to 'src')
-rw-r--r-- | src/lib/libcrypto/cryptlib.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/lib/libcrypto/cryptlib.c b/src/lib/libcrypto/cryptlib.c index 59e6456bbb..fe15135ed9 100644 --- a/src/lib/libcrypto/cryptlib.c +++ b/src/lib/libcrypto/cryptlib.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: cryptlib.c,v 1.54 2024/09/06 09:57:32 tb Exp $ */ | 1 | /* $OpenBSD: cryptlib.c,v 1.55 2024/10/17 14:09:29 jsing Exp $ */ |
2 | /* ==================================================================== | 2 | /* ==================================================================== |
3 | * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. | 3 | * Copyright (c) 1998-2006 The OpenSSL Project. All rights reserved. |
4 | * | 4 | * |
@@ -345,12 +345,8 @@ crypto_cpu_caps_ia32(void) | |||
345 | void | 345 | void |
346 | OPENSSL_cpuid_setup(void) | 346 | OPENSSL_cpuid_setup(void) |
347 | { | 347 | { |
348 | static int trigger = 0; | ||
349 | uint64_t OPENSSL_ia32_cpuid(void); | 348 | uint64_t OPENSSL_ia32_cpuid(void); |
350 | 349 | ||
351 | if (trigger) | ||
352 | return; | ||
353 | trigger = 1; | ||
354 | OPENSSL_ia32cap_P = OPENSSL_ia32_cpuid(); | 350 | OPENSSL_ia32cap_P = OPENSSL_ia32_cpuid(); |
355 | 351 | ||
356 | if ((OPENSSL_ia32cap_P & CPUCAP_MASK_AESNI) != 0) | 352 | if ((OPENSSL_ia32cap_P & CPUCAP_MASK_AESNI) != 0) |