summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorStephen Warren <swarren@nvidia.com>2014-04-18 10:28:58 -0600
committerTom Rini <trini@ti.com>2014-04-18 16:14:17 -0400
commit53eb768dfb97269ccec60d34321252b1ee1850d9 (patch)
tree40a54e21058a7a3a7b20b12d3e2e60501b996c1a /include
parenta8b993eb81c142a439c24b871a2317f765fe5397 (diff)
downloadblackbird-obmc-uboot-53eb768dfb97269ccec60d34321252b1ee1850d9.tar.gz
blackbird-obmc-uboot-53eb768dfb97269ccec60d34321252b1ee1850d9.zip
aes: make apply_cbc_chain_data non-static
Tegra's crypto.c uses apply_cbc_chain_data() to sign the warm restart code. This function was recently moved into the core aes.c and made static, which prevents the Tegra code from compiling. Make it public again to avoid the compile errors: arch/arm/cpu/tegra20-common/crypto.c: In function ‘sign_object’: arch/arm/cpu/tegra20-common/crypto.c:74:3: warning: implicit declaration of function ‘apply_cbc_chain_data’ [-Wimplicit-function-declaration] arch/arm/cpu/built-in.o: In function `sign_object': .../arch/arm/cpu/tegra20-common/crypto.c:74: undefined reference to `apply_cbc_chain_data' .../arch/arm/cpu/tegra20-common/crypto.c:78: undefined reference to `apply_cbc_chain_data' Fixes: 6e7b9f4fa0ae ("aes: Move the AES-128-CBC encryption function to common code") Signed-off-by: Stephen Warren <swarren@nvidia.com> Reviewed-by: Simon Glass <sjg@chromium.org> Acked-by: Marek Vasut <marex@denx.de>
Diffstat (limited to 'include')
-rw-r--r--include/aes.h11
1 files changed, 11 insertions, 0 deletions
diff --git a/include/aes.h b/include/aes.h
index ee0e6c275f..6315c02aa9 100644
--- a/include/aes.h
+++ b/include/aes.h
@@ -61,6 +61,17 @@ void aes_encrypt(u8 *in, u8 *expkey, u8 *out);
void aes_decrypt(u8 *in, u8 *expkey, u8 *out);
/**
+ * Apply chain data to the destination using EOR
+ *
+ * Each array is of length AES_KEY_LENGTH.
+ *
+ * @cbc_chain_data Chain data
+ * @src Source data
+ * @dst Destination data, which is modified here
+ */
+void aes_apply_cbc_chain_data(u8 *cbc_chain_data, u8 *src, u8 *dst);
+
+/**
* aes_cbc_encrypt_blocks() - Encrypt multiple blocks of data with AES CBC.
*
* @key_exp Expanded key to use
OpenPOWER on IntegriCloud