diff options
author | Keir Fraser <keir.fraser@citrix.com> | 2009-09-30 08:43:34 +0100 |
---|---|---|
committer | Keir Fraser <keir.fraser@citrix.com> | 2009-09-30 08:43:34 +0100 |
commit | 43a134db615db6754d70f72bb1beca7b1e0b30a4 (patch) | |
tree | 6ad098be268fdfebed5203c49e4164b3d4a93d0b /xen/crypto | |
parent | 873563eb5aaf36cb247eb61acdb42cff8383930d (diff) | |
download | xen-43a134db615db6754d70f72bb1beca7b1e0b30a4.tar.gz xen-43a134db615db6754d70f72bb1beca7b1e0b30a4.tar.bz2 xen-43a134db615db6754d70f72bb1beca7b1e0b30a4.zip |
Cleanup: Make local functions static and remove unused functions.
Signed-off-by: Christoph Egger <Christoph.Egger@amd.com>
Diffstat (limited to 'xen/crypto')
-rw-r--r-- | xen/crypto/vmac.c | 56 |
1 files changed, 0 insertions, 56 deletions
diff --git a/xen/crypto/vmac.c b/xen/crypto/vmac.c index e5558ba782..1e9bafa0ba 100644 --- a/xen/crypto/vmac.c +++ b/xen/crypto/vmac.c @@ -843,62 +843,6 @@ void vhash_update(unsigned char *m, /* ----------------------------------------------------------------------- */ -uint64_t xvhash(unsigned char m[], - unsigned int mbytes, - uint64_t *tagl, - vmac_ctx_t *ctx) -{ - uint64_t ch, cl, rh, rl, *mptr; - #if (VMAC_TAG_LEN == 128) - uint64_t ch2, cl2, rh2, rl2; - #endif - const uint64_t *kptr = (uint64_t *)ctx->nhkey; - int i, remaining; - - remaining = mbytes % VMAC_NHBYTES; - i = mbytes-remaining; - mptr = (uint64_t *)(m+i); - if (i) vhash_update(m,i,ctx); - - ch = ctx->polytmp[0]; - cl = ctx->polytmp[1]; - #if (VMAC_TAG_LEN == 128) - ch2 = ctx->polytmp[2]; - cl2 = ctx->polytmp[3]; - #endif - - if (remaining) { - #if (VMAC_TAG_LEN == 128) - nh_16_2(mptr,kptr,2*((remaining+15)/16),rh,rl,rh2,rl2); - rh2 &= m62; - #else - nh_16(mptr,kptr,2*((remaining+15)/16),rh,rl); - #endif - rh &= m62; - if (i) { - poly_step(ch,cl,ctx->polykey[0],ctx->polykey[1],rh,rl); - #if (VMAC_TAG_LEN == 128) - poly_step(ch2,cl2,ctx->polykey[2],ctx->polykey[3],rh2,rl2); - #endif - } else { - ADD128(ch,cl,rh,rl); - #if (VMAC_TAG_LEN == 128) - ADD128(ch2,cl2,rh2,rl2); - #endif - } - } - - #if VMAC_USE_SSE2 - _mm_empty(); /* SSE2 version of poly_step uses mmx instructions */ - #endif - vhash_abort(ctx); - remaining *= 8; -#if (VMAC_TAG_LEN == 128) - *tagl = l3hash(ch2, cl2, ctx->l3key[2], ctx->l3key[3],remaining); -#endif - return l3hash(ch, cl, ctx->l3key[0], ctx->l3key[1],remaining); -} - uint64_t vhash(unsigned char m[], unsigned int mbytes, uint64_t *tagl, |