From b59b3d7c36ab7b568eba1ab20e5a264957dbe2c7 Mon Sep 17 00:00:00 2001 From: toddouska Date: Mon, 7 Apr 2014 11:35:13 -0700 Subject: [PATCH] remove unused blake2b helper f()s --- ctaocrypt/src/blake2b.c | 79 ----------------------------------------- 1 file changed, 79 deletions(-) diff --git a/ctaocrypt/src/blake2b.c b/ctaocrypt/src/blake2b.c index b7d78812b..fd5526765 100644 --- a/ctaocrypt/src/blake2b.c +++ b/ctaocrypt/src/blake2b.c @@ -75,12 +75,6 @@ static INLINE int blake2b_set_lastnode( blake2b_state *S ) return 0; } -static INLINE int blake2b_clear_lastnode( blake2b_state *S ) -{ - S->f[1] = 0ULL; - return 0; -} - /* Some helper functions, not necessarily useful */ static INLINE int blake2b_set_lastblock( blake2b_state *S ) { @@ -90,14 +84,6 @@ static INLINE int blake2b_set_lastblock( blake2b_state *S ) return 0; } -static INLINE int blake2b_clear_lastblock( blake2b_state *S ) -{ - if( S->last_node ) blake2b_clear_lastnode( S ); - - S->f[0] = 0ULL; - return 0; -} - static INLINE int blake2b_increment_counter( blake2b_state *S, const word64 inc ) { @@ -106,71 +92,6 @@ static INLINE int blake2b_increment_counter( blake2b_state *S, const word64 return 0; } - - -/* Parameter-related functions */ -static INLINE int blake2b_param_set_digest_length( blake2b_param *P, - const byte digest_length ) -{ - P->digest_length = digest_length; - return 0; -} - -static INLINE int blake2b_param_set_fanout( blake2b_param *P, const byte fanout) -{ - P->fanout = fanout; - return 0; -} - -static INLINE int blake2b_param_set_max_depth( blake2b_param *P, - const byte depth ) -{ - P->depth = depth; - return 0; -} - -static INLINE int blake2b_param_set_leaf_length( blake2b_param *P, - const word32 leaf_length ) -{ - store32( &P->leaf_length, leaf_length ); - return 0; -} - -static INLINE int blake2b_param_set_node_offset( blake2b_param *P, - const word64 node_offset ) -{ - store64( &P->node_offset, node_offset ); - return 0; -} - -static INLINE int blake2b_param_set_node_depth( blake2b_param *P, - const byte node_depth ) -{ - P->node_depth = node_depth; - return 0; -} - -static INLINE int blake2b_param_set_inner_length( blake2b_param *P, - const byte inner_length ) -{ - P->inner_length = inner_length; - return 0; -} - -static INLINE int blake2b_param_set_salt( blake2b_param *P, - const byte salt[BLAKE2B_SALTBYTES] ) -{ - XMEMCPY( P->salt, salt, BLAKE2B_SALTBYTES ); - return 0; -} - -static INLINE int blake2b_param_set_personal( blake2b_param *P, - const byte personal[BLAKE2B_PERSONALBYTES] ) -{ - XMEMCPY( P->personal, personal, BLAKE2B_PERSONALBYTES ); - return 0; -} - static INLINE int blake2b_init0( blake2b_state *S ) { int i;