From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pl0-f67.google.com (mail-pl0-f67.google.com [209.85.160.67]) by dpdk.org (Postfix) with ESMTP id 107371C693 for ; Thu, 5 Apr 2018 17:12:34 +0200 (CEST) Received: by mail-pl0-f67.google.com with SMTP id b6-v6so17561126pla.11 for ; Thu, 05 Apr 2018 08:12:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=pZPyuZRo5ofl1R5c2pd82tl34BLSrEJSMjAzKwl2yVQ=; b=y9i+NRBlD4wUbPt0nzILSeMqqViVLAOKJCqMqiYy/1sqdCXGF8k702+tzJF3Bruvgv 8smlJ7q7B6FNWmh2h+beUVYi+niygPmY3uVonbBIf9X2DAzKFCmfh+7rccRuDdGJ4Jpb dQ8rL2XnXY6SvvdVL2iQ+Qek3CILdQ71h+qn/1jBL+Xc1NzEpTgvXbnMUhCR85mZRJ2G 1UtH3QviAET6AxX/xNlsV92NYQcpKRjT0FOZcXPHC5mkfBjAGbv42zkScCxgWgp3zwMx Dg4PUZ21I4YoYdhI2GGKBe64HHuKtwjhUpKHpTQdgnfMq8mk1EZUAF7yinM5fDeQIA7L 7RYw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=pZPyuZRo5ofl1R5c2pd82tl34BLSrEJSMjAzKwl2yVQ=; b=ni8T8ap15uLZVboxxMGbIARJgsFz+7hS83fILzIdTPJ8KcYgYhoEn8md6SEgSi+/ek pLeyiZLcRYJj4j+ea3Tm0ibzIFXIY1+aqpveZi5sPIcvTRTCuZcN9ohxsUewEGCTlOL2 nQbHnX5sB5ig2DwsKcyuAxUiBS7Ta/mYo94z7creCpCkUyqn/BDMEvVzXBWCkj+QGQKc KDmyua7tCAjCX8EXI6tWsXQTf/1qITIEuxo189Gr3+DdDE6dgZY3QExb38OIIEBevolo 4WLm9oJYu7fHduuV+wANmG+d7kpw5Iq1ypXbV5Kr0lz1xGj8QH+v9jfc39CJLLHzfjHT dUWw== X-Gm-Message-State: AElRT7FRrI3G9T9DmcSVScP4R5SOtLXietq2w9TzUaT9+6FVk6LyMI0U eICZr9/EANDrK2dgaZDVFHfnHqveu9E= X-Google-Smtp-Source: AIpwx48EZpU/jCPqeVX9VQxn7lA7DNte8wXXJ2/ES3RBSuT9KcVm1zCqbJgkC+chzJnWV6NKAbW/2A== X-Received: by 10.99.104.131 with SMTP id d125mr15558055pgc.9.1522941153042; Thu, 05 Apr 2018 08:12:33 -0700 (PDT) Received: from xeon-e3.lan (204-195-71-95.wavecable.com. [204.195.71.95]) by smtp.gmail.com with ESMTPSA id r9sm15570270pfg.128.2018.04.05.08.12.31 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 05 Apr 2018 08:12:31 -0700 (PDT) From: Stephen Hemminger To: jerin.jacob@caviumnetworks.com Cc: dev@dpdk.org, Stephen Hemminger Date: Thu, 5 Apr 2018 08:12:28 -0700 Message-Id: <20180405151228.16595-1-stephen@networkplumber.org> X-Mailer: git-send-email 2.16.3 Subject: [dpdk-dev] [PATCH] net/octeneontx: fix warnings 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: Thu, 05 Apr 2018 15:12:34 -0000 This is fix for Coverity Devect 268319 about uninitialized speed in an error case. Also drop unnecessary assignment. Signed-off-by: Stephen Hemminger --- drivers/net/octeontx/octeontx_ethdev.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/octeontx/octeontx_ethdev.c b/drivers/net/octeontx/octeontx_ethdev.c index 90dd249a6b84..ec3438cb1941 100644 --- a/drivers/net/octeontx/octeontx_ethdev.c +++ b/drivers/net/octeontx/octeontx_ethdev.c @@ -518,7 +518,6 @@ octeontx_dev_link_update(struct rte_eth_dev *dev, struct rte_eth_link link; int res; - res = 0; PMD_INIT_FUNC_TRACE(); res = octeontx_port_link_status(nic); @@ -552,6 +551,7 @@ octeontx_dev_link_update(struct rte_eth_dev *dev, case OCTEONTX_LINK_SPEED_RESERVE1: case OCTEONTX_LINK_SPEED_RESERVE2: default: + link.link_speed = ETH_SPEED_NUM_NONE; octeontx_log_err("incorrect link speed %d", nic->speed); break; } -- 2.16.3