]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
Do not use stitched AES-GCM implementation on PPC32
authorTomas Mraz <tomas@openssl.org>
Wed, 28 Jun 2023 14:55:57 +0000 (16:55 +0200)
committerPauli <pauli@openssl.org>
Thu, 29 Jun 2023 22:31:49 +0000 (08:31 +1000)
The implementation is not usable there at all.
Fixes #21301

Reviewed-by: Hugo Landau <hlandau@openssl.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
Reviewed-by: Paul Dale <pauli@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/21312)

(cherry picked from commit b256d32915d29bdcbc109363d3b05fce6dac30b7)

crypto/modes/build.info
providers/implementations/ciphers/cipher_aes_gcm_hw.c

index 4ba7c24f3e1f008879323e990d4a8a0310475e98..c79f75c5c4085adb2dc6154dce958653dabb8096 100644 (file)
@@ -33,11 +33,11 @@ IF[{- !$disabled{asm} -}]
   $MODESDEF_parisc20_64=$MODESDEF_parisc11
 
   $MODESASM_ppc32=ghashp8-ppc.s
-  IF[{- $target{sys_id} ne "AIX" && $target{sys_id} ne "MACOSX" -}]
-    $MODESASM_ppc32=ghashp8-ppc.s aes-gcm-ppc.s
-  ENDIF
   $MODESDEF_ppc32=
   $MODESASM_ppc64=$MODESASM_ppc32
+  IF[{- $target{sys_id} ne "AIX" && $target{sys_id} ne "MACOSX" -}]
+    $MODESASM_ppc64=$MODESASM_ppc32 aes-gcm-ppc.s
+  ENDIF
   $MODESDEF_ppc64=$MODESDEF_ppc32
 
   $MODESASM_c64xplus=ghash-c64xplus.s
index 3887b4916ec4f4c9bfd91a46cab73eb32f183ad2..38d8115f24e1f48691c5e2eb69ad6f67b1869320 100644 (file)
@@ -140,7 +140,7 @@ static const PROV_GCM_HW aes_gcm = {
 # include "cipher_aes_gcm_hw_t4.inc"
 #elif defined(AES_PMULL_CAPABLE) && defined(AES_GCM_ASM)
 # include "cipher_aes_gcm_hw_armv8.inc"
-#elif defined(PPC_AES_GCM_CAPABLE)
+#elif defined(PPC_AES_GCM_CAPABLE) && defined(_ARCH_PPC64)
 # include "cipher_aes_gcm_hw_ppc.inc"
 #elif defined(__riscv) && __riscv_xlen == 64
 # include "cipher_aes_gcm_hw_rv64i.inc"