diff options
author | Tianjia Zhang <tianjia.zhang@linux.alibaba.com> | 2021-07-20 11:46:39 +0800 |
---|---|---|
committer | Herbert Xu <herbert@gondor.apana.org.au> | 2021-07-30 10:58:30 +0800 |
commit | 2b31277af577b1b2da62c3ad7d3315b422869102 (patch) | |
tree | 198253c3073b746bd7e3e0921d8e16647695bff5 /lib/crypto/Makefile | |
parent | 821720b9f34ec54106ebf012a712ba73bbcf47c2 (diff) | |
download | linux-stable-2b31277af577b1b2da62c3ad7d3315b422869102.tar.gz linux-stable-2b31277af577b1b2da62c3ad7d3315b422869102.tar.bz2 linux-stable-2b31277af577b1b2da62c3ad7d3315b422869102.zip |
crypto: sm4 - create SM4 library based on sm4 generic code
Take the existing small footprint and mostly time invariant C code
and turn it into a SM4 library that can be used for non-performance
critical, casual use of SM4, and as a fallback for, e.g., SIMD code
that needs a secondary path that can be taken in contexts where the
SIMD unit is off limits.
Secondly, some codes have been optimized, such as unrolling small
times loop, removing unnecessary memory shifts, exporting sbox, fk,
ck arrays, and basic encryption and decryption functions.
Signed-off-by: Tianjia Zhang <tianjia.zhang@linux.alibaba.com>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
Diffstat (limited to 'lib/crypto/Makefile')
-rw-r--r-- | lib/crypto/Makefile | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/crypto/Makefile b/lib/crypto/Makefile index 3a435629d9ce..73205ed269ba 100644 --- a/lib/crypto/Makefile +++ b/lib/crypto/Makefile @@ -38,6 +38,9 @@ libpoly1305-y += poly1305.o obj-$(CONFIG_CRYPTO_LIB_SHA256) += libsha256.o libsha256-y := sha256.o +obj-$(CONFIG_CRYPTO_LIB_SM4) += libsm4.o +libsm4-y := sm4.o + ifneq ($(CONFIG_CRYPTO_MANAGER_DISABLE_TESTS),y) libblake2s-y += blake2s-selftest.o libchacha20poly1305-y += chacha20poly1305-selftest.o |