From: Sebastian Siewior Date: Sun, 30 Mar 2008 08:36:09 +0000 (+0800) Subject: [CRYPTO] api: Make the crypto subsystem fully modular X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c3715cb90f722b1cf5f6f073be02cc8a49659b90;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git [CRYPTO] api: Make the crypto subsystem fully modular Signed-off-by: Sebastian Siewior Signed-off-by: Herbert Xu --- diff --git a/crypto/Kconfig b/crypto/Kconfig index e14ff127501..edd00c5307a 100644 --- a/crypto/Kconfig +++ b/crypto/Kconfig @@ -13,7 +13,7 @@ source "crypto/async_tx/Kconfig" # Cryptographic API Configuration # menuconfig CRYPTO - bool "Cryptographic API" + tristate "Cryptographic API" help This option provides the core Cryptographic API. diff --git a/crypto/Makefile b/crypto/Makefile index 6d34bf7ecf8..ca024418f4f 100644 --- a/crypto/Makefile +++ b/crypto/Makefile @@ -2,7 +2,8 @@ # Cryptographic API # -obj-$(CONFIG_CRYPTO) += api.o cipher.o digest.o compress.o +obj-$(CONFIG_CRYPTO) += crypto.o +crypto-objs := api.o cipher.o digest.o compress.o crypto_algapi-$(CONFIG_PROC_FS) += proc.o crypto_algapi-objs := algapi.o scatterwalk.o $(crypto_algapi-y) diff --git a/crypto/api.c b/crypto/api.c index a2496d1bc6d..0a0f41ef255 100644 --- a/crypto/api.c +++ b/crypto/api.c @@ -445,3 +445,6 @@ int crypto_has_alg(const char *name, u32 type, u32 mask) return ret; } EXPORT_SYMBOL_GPL(crypto_has_alg); + +MODULE_DESCRIPTION("Cryptographic core API"); +MODULE_LICENSE("GPL"); diff --git a/include/linux/crypto.h b/include/linux/crypto.h index 5e02d1b4637..425824bd49f 100644 --- a/include/linux/crypto.h +++ b/include/linux/crypto.h @@ -317,14 +317,7 @@ int crypto_unregister_alg(struct crypto_alg *alg); /* * Algorithm query interface. */ -#ifdef CONFIG_CRYPTO int crypto_has_alg(const char *name, u32 type, u32 mask); -#else -static inline int crypto_has_alg(const char *name, u32 type, u32 mask) -{ - return 0; -} -#endif /* * Transforms: user-instantiated objects which encapsulate algorithms