summaryrefslogtreecommitdiffstats
path: root/drivers/staging/skein/threefish256Block.c
diff options
context:
space:
mode:
authorAnton Saraev2014-05-19 10:09:55 +0200
committerGreg Kroah-Hartman2014-05-19 23:18:14 +0200
commit95f1840a7e761a86931f08c6e84f6df33333c217 (patch)
tree03509b8b8c7f4b00810ab1a7ce03718d47f8f7af /drivers/staging/skein/threefish256Block.c
parentstaging: crypto: skein: rename camelcase functions (diff)
downloadkernel-qcow2-linux-95f1840a7e761a86931f08c6e84f6df33333c217.tar.gz
kernel-qcow2-linux-95f1840a7e761a86931f08c6e84f6df33333c217.tar.xz
kernel-qcow2-linux-95f1840a7e761a86931f08c6e84f6df33333c217.zip
staging: crypto: skein: rename camelcase vars
camelCase is not accepted in the Linux Kernel. To prepare skein driver for mainline inclusion, we rename all vars to non-camelCase equivalents. Signed-off-by: Anton Saraev <antonysaraev@gmail.com> Reviewed-by: Jake Edge <jake@lwn.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/skein/threefish256Block.c')
-rw-r--r--drivers/staging/skein/threefish256Block.c28
1 files changed, 14 insertions, 14 deletions
diff --git a/drivers/staging/skein/threefish256Block.c b/drivers/staging/skein/threefish256Block.c
index ee21aef24573..1329c71697ed 100644
--- a/drivers/staging/skein/threefish256Block.c
+++ b/drivers/staging/skein/threefish256Block.c
@@ -2,16 +2,16 @@
#include <threefishApi.h>
-void threefish_encrypt_256(struct threefish_key *keyCtx, u64 *input,
+void threefish_encrypt_256(struct threefish_key *key_ctx, u64 *input,
u64 *output)
{
u64 b0 = input[0], b1 = input[1],
- b2 = input[2], b3 = input[3];
- u64 k0 = keyCtx->key[0], k1 = keyCtx->key[1],
- k2 = keyCtx->key[2], k3 = keyCtx->key[3],
- k4 = keyCtx->key[4];
- u64 t0 = keyCtx->tweak[0], t1 = keyCtx->tweak[1],
- t2 = keyCtx->tweak[2];
+ b2 = input[2], b3 = input[3];
+ u64 k0 = key_ctx->key[0], k1 = key_ctx->key[1],
+ k2 = key_ctx->key[2], k3 = key_ctx->key[3],
+ k4 = key_ctx->key[4];
+ u64 t0 = key_ctx->tweak[0], t1 = key_ctx->tweak[1],
+ t2 = key_ctx->tweak[2];
b1 += k1 + t0;
b0 += b1 + k0;
@@ -495,16 +495,16 @@ void threefish_encrypt_256(struct threefish_key *keyCtx, u64 *input,
output[3] = b3 + k1 + 18;
}
-void threefish_decrypt_256(struct threefish_key *keyCtx, u64 *input,
+void threefish_decrypt_256(struct threefish_key *key_ctx, u64 *input,
u64 *output)
{
u64 b0 = input[0], b1 = input[1],
- b2 = input[2], b3 = input[3];
- u64 k0 = keyCtx->key[0], k1 = keyCtx->key[1],
- k2 = keyCtx->key[2], k3 = keyCtx->key[3],
- k4 = keyCtx->key[4];
- u64 t0 = keyCtx->tweak[0], t1 = keyCtx->tweak[1],
- t2 = keyCtx->tweak[2];
+ b2 = input[2], b3 = input[3];
+ u64 k0 = key_ctx->key[0], k1 = key_ctx->key[1],
+ k2 = key_ctx->key[2], k3 = key_ctx->key[3],
+ k4 = key_ctx->key[4];
+ u64 t0 = key_ctx->tweak[0], t1 = key_ctx->tweak[1],
+ t2 = key_ctx->tweak[2];
u64 tmp;