From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id D9F93235 for ; Tue, 17 Jul 2018 12:35:36 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga002.jf.intel.com ([10.7.209.21]) by orsmga102.jf.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 17 Jul 2018 03:35:34 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,365,1526367600"; d="scan'208";a="75432599" Received: from silpixa00397517.ir.intel.com (HELO silpixa00397517.ger.corp.intel.com) ([10.237.222.54]) by orsmga002.jf.intel.com with ESMTP; 17 Jul 2018 03:34:19 -0700 From: Kevin Laatz To: dev@dpdk.org Cc: jasvinder.singh@intel.com, bernard.iremonger@intel.com, Kevin Laatz Date: Tue, 17 Jul 2018 11:34:05 +0100 Message-Id: <20180717103405.6793-1-kevin.laatz@intel.com> X-Mailer: git-send-email 2.9.5 Subject: [dpdk-dev] [PATCH] app/testpmd: fix logically dead code X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Jul 2018 10:35:37 -0000 Remove logically dead code, tm_port_rate cannot be greater than UINT32_MAX. Coverity issue: 302846 Fixes: 0ad778b398c6 ("app/testpmd: rework softnic forward mode") Signed-off-by: Kevin Laatz --- app/test-pmd/softnicfwd.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/app/test-pmd/softnicfwd.c b/app/test-pmd/softnicfwd.c index 1f9eeaf..7ff6228 100644 --- a/app/test-pmd/softnicfwd.c +++ b/app/test-pmd/softnicfwd.c @@ -175,9 +175,6 @@ set_tm_hiearchy_nodes_shaper_rate(portid_t port_id, rte_eth_link_get(port_id, &link_params); tm_port_rate = (uint64_t)ETH_SPEED_NUM_10G * BYTES_IN_MBPS; - if (tm_port_rate > UINT32_MAX) - tm_port_rate = UINT32_MAX; - /* Set tm hierarchy shapers rate */ h->root_node_shaper_rate = tm_port_rate; h->subport_node_shaper_rate = -- 2.9.5