diff options
author | jsing <> | 2023-01-20 10:07:52 +0000 |
---|---|---|
committer | jsing <> | 2023-01-20 10:07:52 +0000 |
commit | f51982659cdb6b0d0b26e0382390ef696868017f (patch) | |
tree | 2cc9ef09c2c6bdf815781f7a57aab455a209419b /src/lib/libcrypto/bn | |
parent | 61025822ea93f6f549e9f7d13b7360c49fd56ac1 (diff) | |
download | openbsd-f51982659cdb6b0d0b26e0382390ef696868017f.tar.gz openbsd-f51982659cdb6b0d0b26e0382390ef696868017f.tar.bz2 openbsd-f51982659cdb6b0d0b26e0382390ef696868017f.zip |
Replace BN_DIV3W with HAVE_BN_DIV_3_WORDS (in bn_arch.h).
ok tb@
Diffstat (limited to 'src/lib/libcrypto/bn')
-rw-r--r-- | src/lib/libcrypto/bn/arch/mips64/bn_arch.h | 4 | ||||
-rw-r--r-- | src/lib/libcrypto/bn/bn_div.c | 7 |
2 files changed, 7 insertions, 4 deletions
diff --git a/src/lib/libcrypto/bn/arch/mips64/bn_arch.h b/src/lib/libcrypto/bn/arch/mips64/bn_arch.h index 4d6571f9cb..6c6212c4a6 100644 --- a/src/lib/libcrypto/bn/arch/mips64/bn_arch.h +++ b/src/lib/libcrypto/bn/arch/mips64/bn_arch.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: bn_arch.h,v 1.1 2023/01/20 10:04:34 jsing Exp $ */ | 1 | /* $OpenBSD: bn_arch.h,v 1.2 2023/01/20 10:07:52 jsing Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2023 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2023 Joel Sing <jsing@openbsd.org> |
4 | * | 4 | * |
@@ -20,5 +20,7 @@ | |||
20 | 20 | ||
21 | #ifndef OPENSSL_NO_ASM | 21 | #ifndef OPENSSL_NO_ASM |
22 | 22 | ||
23 | #define HAVE_BN_DIV_3_WORDS | ||
24 | |||
23 | #endif | 25 | #endif |
24 | #endif | 26 | #endif |
diff --git a/src/lib/libcrypto/bn/bn_div.c b/src/lib/libcrypto/bn/bn_div.c index 47e491ec46..df4b7517d7 100644 --- a/src/lib/libcrypto/bn/bn_div.c +++ b/src/lib/libcrypto/bn/bn_div.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: bn_div.c,v 1.31 2023/01/18 05:29:48 jsing Exp $ */ | 1 | /* $OpenBSD: bn_div.c,v 1.32 2023/01/20 10:07:52 jsing Exp $ */ |
2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
3 | * All rights reserved. | 3 | * All rights reserved. |
4 | * | 4 | * |
@@ -63,11 +63,12 @@ | |||
63 | #include <openssl/bn.h> | 63 | #include <openssl/bn.h> |
64 | #include <openssl/err.h> | 64 | #include <openssl/err.h> |
65 | 65 | ||
66 | #include "bn_arch.h" | ||
66 | #include "bn_local.h" | 67 | #include "bn_local.h" |
67 | 68 | ||
68 | BN_ULONG bn_div_3_words(const BN_ULONG *m, BN_ULONG d1, BN_ULONG d0); | 69 | BN_ULONG bn_div_3_words(const BN_ULONG *m, BN_ULONG d1, BN_ULONG d0); |
69 | 70 | ||
70 | #ifndef BN_DIV3W | 71 | #ifndef HAVE_BN_DIV_3_WORDS |
71 | 72 | ||
72 | #if !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_NO_INLINE_ASM) | 73 | #if !defined(OPENSSL_NO_ASM) && !defined(OPENSSL_NO_INLINE_ASM) |
73 | # if defined(__GNUC__) && __GNUC__>=2 | 74 | # if defined(__GNUC__) && __GNUC__>=2 |
@@ -199,7 +200,7 @@ bn_div_3_words(const BN_ULONG *m, BN_ULONG d1, BN_ULONG d0) | |||
199 | 200 | ||
200 | return q; | 201 | return q; |
201 | } | 202 | } |
202 | #endif /* !BN_DIV3W */ | 203 | #endif /* !HAVE_BN_DIV_3_WORDS */ |
203 | 204 | ||
204 | /* | 205 | /* |
205 | * BN_div_internal computes quotient := numerator / divisor, rounding towards | 206 | * BN_div_internal computes quotient := numerator / divisor, rounding towards |