Signed-off-by: Cristian Stoica <cristian.sto...@nxp.com>
---
 tests/async_hmac.c  | 2 --
 tests/cipher_comp.c | 2 +-
 tests/hash_comp.c   | 5 ++---
 tests/hmac.c        | 2 --
 tests/sha_speed.c   | 1 -
 tests/speed.c       | 1 -
 6 files changed, 3 insertions(+), 10 deletions(-)

diff --git a/tests/async_hmac.c b/tests/async_hmac.c
index 94a02c0..85d19c6 100644
--- a/tests/async_hmac.c
+++ b/tests/async_hmac.c
@@ -185,8 +185,6 @@ test_extras(int cfd)
        struct session_op sess;
        struct crypt_op cryp;
        uint8_t mac[AALG_MAX_RESULT_LEN];
-       uint8_t oldmac[AALG_MAX_RESULT_LEN];
-       uint8_t md5_hmac_out[] = 
"\x75\x0c\x78\x3e\x6a\xb0\xb5\x03\xea\xa8\x6e\x31\x0a\x5d\xb7\x38";
        uint8_t sha1_out[] = 
"\x8f\x82\x03\x94\xf9\x53\x35\x18\x20\x45\xda\x24\xf3\x4d\xe5\x2b\xf8\xbc\x34\x32";
        int i;
 
diff --git a/tests/cipher_comp.c b/tests/cipher_comp.c
index 03f67bf..dbf9977 100644
--- a/tests/cipher_comp.c
+++ b/tests/cipher_comp.c
@@ -33,7 +33,7 @@ test_crypto(int cfd, struct session_op *sess, int datalen)
 
        struct crypt_op cryp;
 
-       int ret = 0, fail = 0;
+       int ret = 0;
 
        data = malloc(datalen);
        encrypted = malloc(datalen);
diff --git a/tests/hash_comp.c b/tests/hash_comp.c
index e6a4346..73f85ed 100644
--- a/tests/hash_comp.c
+++ b/tests/hash_comp.c
@@ -36,7 +36,7 @@ test_crypto(int cfd, struct session_op *sess, int datalen)
 
        struct crypt_op cryp;
 
-       int ret = 0, fail = 0;
+       int ret = 0;
 
        data = malloc(datalen);
        memset(data, datalen & 0xff, datalen);
@@ -66,7 +66,7 @@ test_crypto(int cfd, struct session_op *sess, int datalen)
 
        if (memcmp(mac, mac_comp, AALG_MAX_RESULT_LEN)) {
                printf("fail for datalen %d, MACs do not match!\n", datalen);
-               fail = 1;
+               ret = 1;
                printf("wrong mac: ");
                printhex(mac, 20);
                printf("right mac: ");
@@ -88,7 +88,6 @@ main(int argc, char **argv)
        struct session_op sess;
        int datalen = BLOCK_SIZE;
        int datalen_end = MAX_DATALEN;
-       int i;
 
        if (argc > 1) {
                datalen = min(max(atoi(argv[1]), BLOCK_SIZE), MAX_DATALEN);
diff --git a/tests/hmac.c b/tests/hmac.c
index 80a2c42..3b248f3 100644
--- a/tests/hmac.c
+++ b/tests/hmac.c
@@ -212,8 +212,6 @@ test_extras(int cfd)
 #endif
        struct crypt_op cryp;
        uint8_t mac[AALG_MAX_RESULT_LEN];
-       uint8_t oldmac[AALG_MAX_RESULT_LEN];
-       uint8_t md5_hmac_out[] = 
"\x75\x0c\x78\x3e\x6a\xb0\xb5\x03\xea\xa8\x6e\x31\x0a\x5d\xb7\x38";
        uint8_t sha1_out[] = 
"\x8f\x82\x03\x94\xf9\x53\x35\x18\x20\x45\xda\x24\xf3\x4d\xe5\x2b\xf8\xbc\x34\x32";
        int i;
 
diff --git a/tests/sha_speed.c b/tests/sha_speed.c
index 5034b58..1e67260 100644
--- a/tests/sha_speed.c
+++ b/tests/sha_speed.c
@@ -131,7 +131,6 @@ int main(void)
 {
        int fd, i, fdc = -1, alignmask = 0;
        struct session_op sess;
-       char keybuf[32];
 #ifdef CIOCGSESSINFO
        struct session_info_op siop;
 #endif
diff --git a/tests/speed.c b/tests/speed.c
index 0b40bcf..84a5bf0 100644
--- a/tests/speed.c
+++ b/tests/speed.c
@@ -76,7 +76,6 @@ int encrypt_data(struct session_op *sess, int fdc, int 
chunksize, int alignmask)
 {
        struct crypt_op cop;
        char *buffer, iv[32];
-       uint8_t mac[HASH_MAX_LEN];
        static int val = 23;
        struct timeval start, end;
        double total = 0;
-- 
2.7.3


_______________________________________________
Cryptodev-linux-devel mailing list
Cryptodev-linux-devel@gna.org
https://mail.gna.org/listinfo/cryptodev-linux-devel

Reply via email to