2014-06-10 12:43:15

by Corentin Labbe

[permalink] [raw]
Subject: [PATCH v3 2/4] crypto: Update makefile and Kconfig for Security System

Add necessary changes for configuring and compiling the Security System driver.

Signed-off-by: LABBE Corentin <[email protected]>
---
drivers/crypto/Kconfig | 91 +++++++++++++++++++++++++++++++++++++++++++++++++
drivers/crypto/Makefile | 1 +
2 files changed, 92 insertions(+)

diff --git a/drivers/crypto/Kconfig b/drivers/crypto/Kconfig
index 03ccdb0..ed1c918 100644
--- a/drivers/crypto/Kconfig
+++ b/drivers/crypto/Kconfig
@@ -418,4 +418,95 @@ config CRYPTO_DEV_MXS_DCP
To compile this driver as a module, choose M here: the module
will be called mxs-dcp.

+config CRYPTO_DEV_SUNXI_SS
+ tristate "Support for Allwinner Security System cryptographic accelerator"
+ depends on ARCH_SUNXI
+ help
+ Some Allwinner SoC have a crypto accelerator named
+ Security System. Select this if you want to use it.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss.
+
+if CRYPTO_DEV_SUNXI_SS
+config CRYPTO_DEV_SUNXI_SS_PRNG
+ tristate "Security System PRNG"
+ select CRYPTO_RNG2
+ help
+ If you enable this option, the SS will provide a pseudo random
+ number generator.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss-prng.
+
+config CRYPTO_DEV_SUNXI_SS_HASH
+ tristate "Security System hash common"
+ help
+ Common parts of Security System shared by hash algorithms.
+
+config CRYPTO_DEV_SUNXI_SS_CIPHER
+ tristate "Security System cipher common"
+ help
+ Common parts of Security System shared by cipher algorithms.
+
+config CRYPTO_DEV_SUNXI_SS_MD5
+ tristate "Security System MD5"
+ select CRYPTO_MD5
+ select CRYPTO_DEV_SUNXI_SS_HASH
+ help
+ If you enable this option, the SS will provide MD5 hardware
+ acceleration.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss-md5.
+
+config CRYPTO_DEV_SUNXI_SS_SHA1
+ tristate "Security System SHA1"
+ select CRYPTO_SHA1
+ select CRYPTO_DEV_SUNXI_SS_HASH
+ help
+ If you enable this option, the SS will provide SHA1 hardware
+ acceleration.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss-sha1.
+
+config CRYPTO_DEV_SUNXI_SS_AES
+ tristate "Security System AES"
+ select CRYPTO_AES
+ select CRYPTO_BLKCIPHER
+ select CRYPTO_DEV_SUNXI_SS_CIPHER
+ help
+ If you enable this option, the SS will provide AES hardware
+ acceleration.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss-aes.
+
+config CRYPTO_DEV_SUNXI_SS_DES
+ tristate "Security System DES"
+ select CRYPTO_DES
+ select CRYPTO_BLKCIPHER
+ select CRYPTO_DEV_SUNXI_SS_CIPHER
+ help
+ If you enable this option, the SS will provide DES hardware
+ acceleration.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss-des.
+
+config CRYPTO_DEV_SUNXI_SS_3DES
+ tristate "Security System 3DES"
+ select CRYPTO_DES
+ select CRYPTO_BLKCIPHER
+ select CRYPTO_DEV_SUNXI_SS_CIPHER
+ help
+ If you enable this option, the SS will provide 3DES hardware
+ acceleration.
+
+ To compile this driver as a module, choose M here: the module
+ will be called sunxi-ss-3des.
+
+endif #CRYPTO_DEV_SUNXI_SS
+
endif # CRYPTO_HW
diff --git a/drivers/crypto/Makefile b/drivers/crypto/Makefile
index 482f090..855292a 100644
--- a/drivers/crypto/Makefile
+++ b/drivers/crypto/Makefile
@@ -23,3 +23,4 @@ obj-$(CONFIG_CRYPTO_DEV_S5P) += s5p-sss.o
obj-$(CONFIG_CRYPTO_DEV_SAHARA) += sahara.o
obj-$(CONFIG_CRYPTO_DEV_TALITOS) += talitos.o
obj-$(CONFIG_CRYPTO_DEV_UX500) += ux500/
+obj-$(CONFIG_CRYPTO_DEV_SUNXI_SS) += sunxi-ss/
--
1.8.5.5


2014-06-14 19:01:30

by Marek Vasut

[permalink] [raw]
Subject: Re: [PATCH v3 2/4] crypto: Update makefile and Kconfig for Security System

On Tuesday, June 10, 2014 at 02:43:15 PM, LABBE Corentin wrote:
> Add necessary changes for configuring and compiling the Security System
> driver.
>
> Signed-off-by: LABBE Corentin <[email protected]>
> ---
> drivers/crypto/Kconfig | 91
> +++++++++++++++++++++++++++++++++++++++++++++++++ drivers/crypto/Makefile
> | 1 +
> 2 files changed, 92 insertions(+)

This should be part of 1/4, otherwise 1/4 just adds dead code.

Best regards,
Marek Vasut

2014-06-22 11:58:38

by Corentin Labbe

[permalink] [raw]
Subject: Re: [PATCH v3 2/4] crypto: Update makefile and Kconfig for Security System

Le 14/06/2014 21:01, Marek Vasut a ?crit :
> On Tuesday, June 10, 2014 at 02:43:15 PM, LABBE Corentin wrote:
>> Add necessary changes for configuring and compiling the Security System
>> driver.
>>
>> Signed-off-by: LABBE Corentin <[email protected]>
>> ---
>> drivers/crypto/Kconfig | 91
>> +++++++++++++++++++++++++++++++++++++++++++++++++ drivers/crypto/Makefile
>> | 1 +
>> 2 files changed, 92 insertions(+)
>
> This should be part of 1/4, otherwise 1/4 just adds dead code.
>

If I do that 1/4 add to the makefile a path that do not exists.

But as you like I will change that.

--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected]
For more options, visit https://groups.google.com/d/optout.

2014-06-22 12:25:36

by Marek Vasut

[permalink] [raw]
Subject: Re: [PATCH v3 2/4] crypto: Update makefile and Kconfig for Security System

On Sunday, June 22, 2014 at 01:58:38 PM, Corentin LABBE wrote:
> Le 14/06/2014 21:01, Marek Vasut a ?crit :
> > On Tuesday, June 10, 2014 at 02:43:15 PM, LABBE Corentin wrote:
> >> Add necessary changes for configuring and compiling the Security System
> >> driver.
> >>
> >> Signed-off-by: LABBE Corentin <[email protected]>
> >> ---
> >>
> >> drivers/crypto/Kconfig | 91
> >>
> >> +++++++++++++++++++++++++++++++++++++++++++++++++
> >> drivers/crypto/Makefile
> >>
> >> | 1 +
> >>
> >> 2 files changed, 92 insertions(+)
> >
> > This should be part of 1/4, otherwise 1/4 just adds dead code.
>
> If I do that 1/4 add to the makefile a path that do not exists.
>
> But as you like I will change that.

Well, the point is to add stuff which is logically coupled together (code,
Makefile entry, Kconfig entry) in a single patch if possible.

Best regards,
Marek Vasut

--
You received this message because you are subscribed to the Google Groups "linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to linux-sunxi+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/[email protected]
For more options, visit https://groups.google.com/d/optout.