From: Zijie Pan <zijie....@6wind.com>

Fix warnings of type "Value stored to 'xxx' is never read".

Acked-by: Ivan Boule <ivan.boule at 6wind.com>
Acked-by: Adrien Mazarguil <adrien.mazarguil at 6wind.com>
Signed-off-by: Zijie Pan <zijie.pan at 6wind.com>
---
 app/test-pmd/config.c |    1 -
 app/test/test.c       |    1 -
 app/test/test_lpm.c   |    4 +---
 app/test/test_ring.c  |    4 +---
 4 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c
index fd62235..10cf699 100644
--- a/app/test-pmd/config.c
+++ b/app/test-pmd/config.c
@@ -520,7 +520,6 @@ setup_fwd_config_of_each_lcore(struct fwd_config *cfg)
                nb_fs_per_lcore = (streamid_t) (nb_fs / nb_fc);
                nb_extra = (lcoreid_t) (nb_fs % nb_fc);
        }
-       nb_extra = (lcoreid_t) (nb_fs % nb_fc);

        nb_lc = (lcoreid_t) (nb_fc - nb_extra);
        sm_id = 0;
diff --git a/app/test/test.c b/app/test/test.c
index f98656c..ef978cf 100644
--- a/app/test/test.c
+++ b/app/test/test.c
@@ -132,7 +132,6 @@ main(int argc, char **argv)

        rte_timer_subsystem_init();

-       argc -= ret;
        argv += ret;

        prgname = argv[0];
diff --git a/app/test/test_lpm.c b/app/test/test_lpm.c
index 3a9400f..5b8118a 100644
--- a/app/test/test_lpm.c
+++ b/app/test/test_lpm.c
@@ -752,7 +752,6 @@ test10(void)

        ip = IPv4(128, 0, 0, 0);
        depth = 24;
-       next_hop_add = 100;

        status = rte_lpm_delete(lpm, ip, depth);
        TEST_LPM_ASSERT(status < 0);
@@ -766,7 +765,6 @@ test10(void)

        ip = IPv4(128, 0, 0, 0);
        depth = 32;
-       next_hop_add = 100;

        status = rte_lpm_delete(lpm, ip, depth);
        TEST_LPM_ASSERT(status < 0);
@@ -976,7 +974,7 @@ test14(void)
        next_hop_add = 100;

        /* Add 256 rules that require a tbl8 extension */
-       for (ip = 0; ip <= IPv4(0, 0, 255, 0); ip += 256) {
+       for (; ip <= IPv4(0, 0, 255, 0); ip += 256) {
                status = rte_lpm_add(lpm, ip, depth, next_hop_add);
                TEST_LPM_ASSERT(status == 0);

diff --git a/app/test/test_ring.c b/app/test/test_ring.c
index d6bb44b..39f69b0 100644
--- a/app/test/test_ring.c
+++ b/app/test/test_ring.c
@@ -518,7 +518,7 @@ test_set_watermark( void ){
        }

        count = 0;
-       setwm = rte_ring_set_water_mark(r, count);
+       rte_ring_set_water_mark(r, count);
        if (r->prod.watermark != r->prod.size) {
                printf("Test failed to detect invalid watermark count value\n");
                goto error;
@@ -759,8 +759,6 @@ test_ring_basic(void)
                printf("data after dequeue is not the same\n");
                goto fail;
        }
-       cur_src = src;
-       cur_dst = dst;

        if (src)
                free(src);
-- 
1.7.2.5


Reply via email to