summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2017-04-26 22:27:49 -0600
committerTom Rini <trini@konsulko.com>2017-04-30 10:29:55 -0400
commitb1a873df0a3fb4e4cac8da5e68263715cf71dd4a (patch)
tree235d332737ae262fe37ffc77de62acafeb775011
parent92572ecf8069858b3bea282cd4ee6010aaa65c21 (diff)
Convert CONFIG_CMD_AES et al to Kconfig
This converts the following to Kconfig: CONFIG_CMD_AES CONFIG_AES Signed-off-by: Simon Glass <sjg@chromium.org> [trini: Add select AES to CMD_AES] Signed-off-by: Tom Rini <trini@konsulko.com>
-rw-r--r--cmd/Kconfig10
-rw-r--r--configs/seaboard_defconfig1
-rw-r--r--include/configs/amcore.h1
-rw-r--r--include/configs/seaboard.h1
-rw-r--r--include/configs/topic_miami.h1
-rw-r--r--lib/Kconfig13
-rw-r--r--scripts/config_whitelist.txt2
7 files changed, 24 insertions, 5 deletions
diff --git a/cmd/Kconfig b/cmd/Kconfig
index 50888236db6..e52af92cb4b 100644
--- a/cmd/Kconfig
+++ b/cmd/Kconfig
@@ -769,6 +769,16 @@ config CMD_REGULATOR
endmenu
menu "Security commands"
+config CMD_AES
+ bool "Enable the 'aes' command"
+ select AES
+ help
+ This provides a means to encrypt and decrypt data using the AES
+ (Advanced Encryption Standard). This algorithm uses a symetric key
+ and is widely used as a streaming cipher. Different key lengths are
+ supported by the algorithm but this command only supports 128 bits
+ at present.
+
config CMD_TPM
bool "Enable the 'tpm' command"
depends on TPM
diff --git a/configs/seaboard_defconfig b/configs/seaboard_defconfig
index 3e5549c0731..9e50f702bfd 100644
--- a/configs/seaboard_defconfig
+++ b/configs/seaboard_defconfig
@@ -38,3 +38,4 @@ CONFIG_USB_KEYBOARD=y
CONFIG_DM_VIDEO=y
CONFIG_VIDEO_TEGRA20=y
CONFIG_CONSOLE_SCROLL_LINES=10
+CONFIG_AES=y
diff --git a/include/configs/amcore.h b/include/configs/amcore.h
index 4f462d61e0a..06d08d44830 100644
--- a/include/configs/amcore.h
+++ b/include/configs/amcore.h
@@ -30,7 +30,6 @@
"erase 0xfff00000 0xffffffff; " \
"cp.b 0x20000 0xfff00000 ${filesize}\0"
-#undef CONFIG_CMD_AES
#define CONFIG_CMD_DIAG
/* undef to save memory */
diff --git a/include/configs/seaboard.h b/include/configs/seaboard.h
index 671afa71ec4..661d1fee6f8 100644
--- a/include/configs/seaboard.h
+++ b/include/configs/seaboard.h
@@ -12,7 +12,6 @@
/* LP0 suspend / resume */
#define CONFIG_TEGRA_LP0
-#define CONFIG_AES
#define CONFIG_TEGRA_PMU
#define CONFIG_TPS6586X_POWER
#define CONFIG_TEGRA_CLOCK_SCALING
diff --git a/include/configs/topic_miami.h b/include/configs/topic_miami.h
index a56ceef85a7..23160bd88d7 100644
--- a/include/configs/topic_miami.h
+++ b/include/configs/topic_miami.h
@@ -142,6 +142,5 @@
/* Further tweaks to reduce image size */
#undef CONFIG_CMD_BOOTZ
#undef CONFIG_CMD_NET
-#undef CONFIG_CMD_AES
#endif /* __CONFIG_TOPIC_MIAMI_H */
diff --git a/lib/Kconfig b/lib/Kconfig
index a0d5d926eb6..db0915153cb 100644
--- a/lib/Kconfig
+++ b/lib/Kconfig
@@ -66,6 +66,17 @@ config RBTREE
source lib/dhry/Kconfig
+menu "Security support"
+
+config AES
+ bool "Support the AES algorithm"
+ help
+ This provides a means to encrypt and decrypt data using the AES
+ (Advanced Encryption Standard). This algorithm uses a symetric key
+ and is widely used as a streaming cipher. Different key lengths are
+ supported by the algorithm but only a 128-bit key is supported at
+ present.
+
source lib/rsa/Kconfig
config TPM
@@ -79,6 +90,8 @@ config TPM
for the low-level TPM interface, but only one TPM is supported at
a time by the TPM library.
+endmenu
+
menu "Hashing Support"
config SHA1
diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt
index b1101484211..f06d384dcdd 100644
--- a/scripts/config_whitelist.txt
+++ b/scripts/config_whitelist.txt
@@ -70,7 +70,6 @@ CONFIG_ADNPESC1
CONFIG_ADP_AG101P
CONFIG_AEABI
CONFIG_AEMIF_CNTRL_BASE
-CONFIG_AES
CONFIG_ALTERA_SDRAM
CONFIG_ALTERA_SPI_IDLE_VAL
CONFIG_ALTIVEC
@@ -394,7 +393,6 @@ CONFIG_CM922T_XA10
CONFIG_CMDLINE_EDITING
CONFIG_CMDLINE_PS_SUPPORT
CONFIG_CMDLINE_TAG
-CONFIG_CMD_AES
CONFIG_CMD_ASKEN
CONFIG_CMD_BAT
CONFIG_CMD_BEDBUG