Lines 2-10
Link Here
|
2 |
|
2 |
|
3 |
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=240037 |
3 |
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=240037 |
4 |
|
4 |
|
5 |
--- lib/freebl/blinit.c.orig 2019-08-30 15:46:32 UTC |
5 |
--- lib/freebl/blinit.c.orig 2019-12-09 09:42:55 UTC |
6 |
+++ lib/freebl/blinit.c |
6 |
+++ lib/freebl/blinit.c |
7 |
@@ -163,12 +163,14 @@ CheckARMSupport() |
7 |
@@ -164,12 +164,14 @@ CheckARMSupport() |
8 |
#ifndef ID_AA64ISAR0_SHA2_VAL |
8 |
#ifndef ID_AA64ISAR0_SHA2_VAL |
9 |
#define ID_AA64ISAR0_SHA2_VAL ID_AA64ISAR0_SHA2 |
9 |
#define ID_AA64ISAR0_SHA2_VAL ID_AA64ISAR0_SHA2 |
10 |
#endif |
10 |
#endif |
Lines 25-27
Link Here
|
25 |
#endif /* defined(__linux__) */ |
25 |
#endif /* defined(__linux__) */ |
26 |
/* aarch64 must support NEON. */ |
26 |
/* aarch64 must support NEON. */ |
27 |
arm_neon_support_ = disable_arm_neon == NULL; |
27 |
arm_neon_support_ = disable_arm_neon == NULL; |
|
|
28 |
@@ -405,7 +407,12 @@ CheckPPCSupport() |
29 |
{ |
30 |
char *disable_hw_crypto = PR_GetEnvSecure("NSS_DISABLE_PPC_GHASH"); |
31 |
|
32 |
+#if defined(__linux__) |
33 |
long hwcaps = getauxval(AT_HWCAP2); |
34 |
+#elif defined(__FreeBSD__) |
35 |
+ long hwcaps; |
36 |
+ elf_aux_info(AT_HWCAP2, &hwcaps, sizeof(hwcaps)); |
37 |
+#endif |
38 |
|
39 |
ppc_crypto_support_ = hwcaps & PPC_FEATURE2_VEC_CRYPTO && disable_hw_crypto == NULL; |
40 |
} |