raw/dpaa2_qdma: fix reset
authorYunjian Wang <wangyunjian@huawei.com>
Wed, 9 Sep 2020 01:11:46 +0000 (09:11 +0800)
committerThomas Monjalon <thomas@monjalon.net>
Sun, 11 Oct 2020 20:02:55 +0000 (22:02 +0200)
This issue detected by coverity, CID#279443(Structurally dead code).

Coverity issue: 279443
Fixes: c22fab9a6c34 ("raw/dpaa2_qdma: support configuration APIs")
Cc: stable@dpdk.org
Signed-off-by: Yunjian Wang <wangyunjian@huawei.com>
Acked-by: Nipun Gupta <nipun.gupta@nxp.com>
drivers/raw/dpaa2_qdma/dpaa2_qdma.c

index 0b9c4e3..4b84749 100644 (file)
@@ -452,9 +452,10 @@ rte_qdma_reset(void)
        /* In case there are pending jobs on any VQ, return -EBUSY */
        for (i = 0; i < qdma_dev.max_vqs; i++) {
                if (qdma_vqs[i].in_use && (qdma_vqs[i].num_enqueues !=
-                   qdma_vqs[i].num_dequeues))
+                   qdma_vqs[i].num_dequeues)) {
                        DPAA2_QDMA_ERR("Jobs are still pending on VQ: %d", i);
                        return -EBUSY;
+               }
        }
 
        /* Reset HW queues */