From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jingjing Wu Subject: [PATCH] app/testpmd: fix dead code Date: Tue, 15 Dec 2015 23:42:30 +0800 Message-ID: <1450194150-22234-1-git-send-email-jingjing.wu@intel.com> To: dev@dpdk.org Return-path: Received: from mga04.intel.com (mga04.intel.com [192.55.52.120]) by dpdk.org (Postfix) with ESMTP id D9BB4FE5 for ; Tue, 15 Dec 2015 16:42:37 +0100 (CET) List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Coverity issue (CID 119254): Control flow issues (DEADCODE). Fixes: 1a572499beb6 ("app/testpmd: setup DCB forwarding based on traffic class") Signed-off-by: Jingjing Wu --- app/test-pmd/config.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index e2030b0..7088f6f 100644 --- a/app/test-pmd/config.c +++ b/app/test-pmd/config.c @@ -1251,10 +1251,7 @@ dcb_fwd_config_setup(void) /* reinitialize forwarding streams */ init_fwd_streams(); sm_id = 0; - if ((rxp & 0x1) == 0) - txp = (portid_t) (rxp + 1); - else - txp = (portid_t) (rxp - 1); + txp = 1; /* get the dcb info on the first RX and TX ports */ (void)rte_eth_dev_get_dcb_info(fwd_ports_ids[rxp], &rxp_dcb_info); (void)rte_eth_dev_get_dcb_info(fwd_ports_ids[txp], &txp_dcb_info); -- 2.4.0