crypto: amcc - Remove unused function
authorRickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
Thu, 1 Jan 2015 15:13:47 +0000 (16:13 +0100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Mon, 5 Jan 2015 10:36:07 +0000 (21:36 +1100)
Remove the function get_dynamic_sa_offset_iv_field() that is not used anywhere.

This was partially found by using a static code analysis program called cppcheck.

Signed-off-by: Rickard Strandqvist <rickard_strandqvist@spectrumdigital.se>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
drivers/crypto/amcc/crypto4xx_sa.c

index de8a7a48775abe0ad48c4d9883e9680daf8df4e9..69182e2cc3ea8a916f7e24fcf17365c32e242c20 100644 (file)
 #include "crypto4xx_sa.h"
 #include "crypto4xx_core.h"
 
-u32 get_dynamic_sa_offset_iv_field(struct crypto4xx_ctx *ctx)
-{
-       u32 offset;
-       union dynamic_sa_contents cts;
-
-       if (ctx->direction == DIR_INBOUND)
-               cts.w = ((struct dynamic_sa_ctl *)(ctx->sa_in))->sa_contents;
-       else
-               cts.w = ((struct dynamic_sa_ctl *)(ctx->sa_out))->sa_contents;
-       offset = cts.bf.key_size
-               + cts.bf.inner_size
-               + cts.bf.outer_size
-               + cts.bf.spi
-               + cts.bf.seq_num0
-               + cts.bf.seq_num1
-               + cts.bf.seq_num_mask0
-               + cts.bf.seq_num_mask1
-               + cts.bf.seq_num_mask2
-               + cts.bf.seq_num_mask3;
-
-       return sizeof(struct dynamic_sa_ctl) + offset * 4;
-}
-
 u32 get_dynamic_sa_offset_state_ptr_field(struct crypto4xx_ctx *ctx)
 {
        u32 offset;