diff options
author | simplelins <a735862152@163.com> | 2020-01-03 22:56:18 +0800 |
---|---|---|
committer | Pauli <paul.dale@oracle.com> | 2020-02-17 12:13:23 +1000 |
commit | bc8b648f744566031ce84d77333dbbcb9689e975 (patch) | |
tree | 74af2e35351508994d8a8cd584c7bd79698a0080 /crypto/aes | |
parent | af6c6c21e66f5806062def925e6acdf7d1a0c15d (diff) | |
download | openssl-bc8b648f744566031ce84d77333dbbcb9689e975.tar.gz |
Fix a bug for aarch64 BigEndian
FIXES #10692 #10638
a bug for aarch64 bigendian with instructions 'st1' and 'ld1' on AES-GCM mode.
CLA: trivial
Reviewed-by: Richard Levitte <levitte@openssl.org>
Reviewed-by: Tim Hudson <tjh@openssl.org>
Reviewed-by: Paul Dale <paul.dale@oracle.com>
(Merged from https://github.com/openssl/openssl/pull/10751)
Diffstat (limited to 'crypto/aes')
-rwxr-xr-x | crypto/aes/asm/aesv8-armx.pl | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/crypto/aes/asm/aesv8-armx.pl b/crypto/aes/asm/aesv8-armx.pl index f89bba5cfa..6d7cbf09e4 100755 --- a/crypto/aes/asm/aesv8-armx.pl +++ b/crypto/aes/asm/aesv8-armx.pl @@ -211,7 +211,12 @@ $code.=<<___; .Loop192: vtbl.8 $key,{$in1},$mask vext.8 $tmp,$zero,$in0,#12 +#ifdef __ARMEB__ + vst1.32 {$in1},[$out],#16 + sub $out,$out,#8 +#else vst1.32 {$in1},[$out],#8 +#endif aese $key,$zero subs $bits,$bits,#1 @@ -1772,8 +1777,11 @@ $code.=<<___; ldr $rounds,[$key,#240] ldr $ctr, [$ivp, #12] +#ifdef __ARMEB__ + vld1.8 {$dat0},[$ivp] +#else vld1.32 {$dat0},[$ivp] - +#endif vld1.32 {q8-q9},[$key] // load key schedule... sub $rounds,$rounds,#4 mov $step,#16 |