staging: skein: Removes skein_debug include
PATCH v3 1/1 staging: skein: Removes skein_debug include
Removes skein_debug.h include since skein_debug.h is nonexistent. Removes unneeded debug empty macro defines and their uses.
Signed-off-by Eric Rost <[email protected]>
--- drivers/staging/skein/skein_base.c | 18 ------------- drivers/staging/skein/skein_base.h | 17 ------------- drivers/staging/skein/skein_block.c | 51 +------------------------------------ 3 files changed, 1 insertion(+), 85 deletions(-)
drivers/staging/skein/skein_base.c +0 -18
@@ -124,8 +124,6 @@ int skein_256_init_ext(struct skein_256_ctx *ctx, size_t hash_bit_len,/* tree hash config info (or SKEIN_CFG_TREE_INFO_SEQUENTIAL) */ cfg.w[2 ] =skein_swap64 (tree_info); -skein_show_key (256 , &ctx->h, key, key_bytes); -/* compute the initial chaining values from config block */ skein_256_process_block (ctx, cfg.b,1 ,SKEIN_CFG_STR_LEN );
@@ -232,8 +230,6 @@ int skein_256_final(struct skein_256_ctx *ctx, u8 *hash_val)/* "output" the ctr mode bytes */ skein_put64_lsb_first (hash_val+i*SKEIN_256_BLOCK_BYTES , ctx->x, n); -skein_show_final (256 , &ctx->h, n, - hash_val+i*SKEIN_256_BLOCK_BYTES );/* restore the counter mode key for next time */ memcpy (ctx->x, x,sizeof (x)); }
@@ -353,8 +349,6 @@ int skein_512_init_ext(struct skein_512_ctx *ctx, size_t hash_bit_len,/* tree hash config info (or SKEIN_CFG_TREE_INFO_SEQUENTIAL) */ cfg.w[2 ] =skein_swap64 (tree_info); -skein_show_key (512 , &ctx->h, key, key_bytes); -/* compute the initial chaining values from config block */ skein_512_process_block (ctx, cfg.b,1 ,SKEIN_CFG_STR_LEN );
@@ -461,8 +455,6 @@ int skein_512_final(struct skein_512_ctx *ctx, u8 *hash_val)/* "output" the ctr mode bytes */ skein_put64_lsb_first (hash_val+i*SKEIN_512_BLOCK_BYTES , ctx->x, n); -skein_show_final (512 , &ctx->h, n, - hash_val+i*SKEIN_512_BLOCK_BYTES );/* restore the counter mode key for next time */ memcpy (ctx->x, x,sizeof (x)); }
@@ -577,8 +569,6 @@ int skein_1024_init_ext(struct skein_1024_ctx *ctx, size_t hash_bit_len,/* tree hash config info (or SKEIN_CFG_TREE_INFO_SEQUENTIAL) */ cfg.w[2 ] =skein_swap64 (tree_info); -skein_show_key (1024 , &ctx->h, key, key_bytes); -/* compute the initial chaining values from config block */ skein_1024_process_block (ctx, cfg.b,1 ,SKEIN_CFG_STR_LEN );
@@ -685,8 +675,6 @@ int skein_1024_final(struct skein_1024_ctx *ctx, u8 *hash_val)/* "output" the ctr mode bytes */ skein_put64_lsb_first (hash_val+i*SKEIN_1024_BLOCK_BYTES , ctx->x, n); -skein_show_final (1024 , &ctx->h, n, - hash_val+i*SKEIN_1024_BLOCK_BYTES );/* restore the counter mode key for next time */ memcpy (ctx->x, x,sizeof (x)); }
@@ -794,8 +782,6 @@ int skein_256_output(struct skein_256_ctx *ctx, u8 *hash_val)/* "output" the ctr mode bytes */ skein_put64_lsb_first (hash_val+i*SKEIN_256_BLOCK_BYTES , ctx->x, n); -skein_show_final (256 , &ctx->h, n, - hash_val+i*SKEIN_256_BLOCK_BYTES );/* restore the counter mode key for next time */ memcpy (ctx->x, x,sizeof (x)); }
@@ -833,8 +819,6 @@ int skein_512_output(struct skein_512_ctx *ctx, u8 *hash_val)/* "output" the ctr mode bytes */ skein_put64_lsb_first (hash_val+i*SKEIN_512_BLOCK_BYTES , ctx->x, n); -skein_show_final (256 , &ctx->h, n, - hash_val+i*SKEIN_512_BLOCK_BYTES );/* restore the counter mode key for next time */ memcpy (ctx->x, x,sizeof (x)); }
@@ -872,8 +856,6 @@ int skein_1024_output(struct skein_1024_ctx *ctx, u8 *hash_val)/* "output" the ctr mode bytes */ skein_put64_lsb_first (hash_val+i*SKEIN_1024_BLOCK_BYTES , ctx->x, n); -skein_show_final (256 , &ctx->h, n, - hash_val+i*SKEIN_1024_BLOCK_BYTES );/* restore the counter mode key for next time */ memcpy (ctx->x, x,sizeof (x)); }
drivers/staging/skein/skein_base.h +0 -17
@@ -15,10 +15,6 @@ ** ** The "default" note explains what happens when the switch is not defined. ** -** SKEIN_DEBUG -- make callouts from inside Skein code -** to examine/display intermediate values. -** [default: no callouts (no overhead)] -** ** SKEIN_ERR_CHECK -- how error checking is handled inside Skein ** code. If not defined, most error checking ** is disabled (for performance). Otherwise,
@@ -279,19 +275,6 @@ int skein_1024_output(struct skein_1024_ctx *ctx, u8 *hash_val); (hdr).tweak[1 ] |=SKEIN_T1_TREE_LEVEL (height); \ } -/***************************************************************** -** "Internal" Skein definitions for debugging and error checking -******************************************************************/ -#ifdef SKEIN_DEBUG /* examine/display intermediate values? */ -#include "skein_debug.h" -#else /* default is no callouts */ -#define skein_show_block (bits, ctx, x, blk_ptr, w_ptr, ks_event_ptr, ks_odd_ptr) -#define skein_show_round (bits, ctx, r, x) -#define skein_show_r_ptr (bits, ctx, r, x_ptr) -#define skein_show_final (bits, ctx, cnt, out_ptr) -#define skein_show_key (bits, ctx, key, key_bytes) -#endif -/* ignore all asserts, for performance */ #define skein_assert_ret (x, ret_code)#define skein_assert (x)
drivers/staging/skein/skein_block.c +1 -50
183 lines not on this page · raw message
Signature · 1 line
2.1.1
Quoted 5 lines · Eric Rost
Removes
skein_debug.hinclude sinceskein_debug.his nonexistent. Removes unneeded debug empty macro defines and their uses.Signed-off-by Eric Rost <[email protected]>---
Jason,
I wanted you to take one last look at this before I put reviewed-by on it, as I snipped one more piece of SKEIN_DEBUG that I found in the middle of skein_block.c
thx,
Eric
Quoted 9 lines · Eric Rost
Removes
skein_debug.hinclude sinceskein_debug.his nonexistent. Removes unneeded debug empty macro defines and their uses.Signed-off-by Eric Rost <[email protected]>--- drivers/staging/skein/skein_base.c | 18 ------------- drivers/staging/skein/skein_base.h | 17 ------------- drivers/staging/skein/skein_block.c | 51 +------------------------------------ 3 files changed, 1 insertion(+), 85 deletions(-)
Well done, Eric.
Reviewed-by Jason Cooper <[email protected]>
thx,
Jason.