From mboxrd@z Thu Jan 1 00:00:00 1970 From: Shijith Thotton Subject: Re: [PATCH] net/liquidio: fix uninitialized variable Date: Fri, 15 Sep 2017 16:57:47 +0530 Message-ID: <20170915112746.GA8025@localhost.localdomain> References: <1505442779-15698-1-git-send-email-wang.yong19@zte.com.cn> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: shijith.thotton@cavium.com, dev@dpdk.org To: Yong Wang Return-path: Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on0050.outbound.protection.outlook.com [104.47.36.50]) by dpdk.org (Postfix) with ESMTP id 452211396 for ; Fri, 15 Sep 2017 13:28:08 +0200 (CEST) Content-Disposition: inline In-Reply-To: <1505442779-15698-1-git-send-email-wang.yong19@zte.com.cn> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Thu, Sep 14, 2017 at 10:32:59PM -0400, Yong Wang wrote: > In func lio_dev_link_update(), "link.link_autoneg" is used in func call > lio_dev_atomic_write_link_status(), but is uninitialized. > > Signed-off-by: Yong Wang > --- > drivers/net/liquidio/lio_ethdev.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/net/liquidio/lio_ethdev.c b/drivers/net/liquidio/lio_ethdev.c > index 479936a..a5a71f8 100644 > --- a/drivers/net/liquidio/lio_ethdev.c > +++ b/drivers/net/liquidio/lio_ethdev.c > @@ -939,6 +939,7 @@ struct rte_lio_xstats_name_off { > link.link_status = ETH_LINK_DOWN; > link.link_speed = ETH_SPEED_NUM_NONE; > link.link_duplex = ETH_LINK_HALF_DUPLEX; > + link.link_autoneg = ETH_LINK_FIXED; Thanks for noting. Proper value would be ETH_LINK_AUTONEG as we negotiate speed in firmware. > memset(&old, 0, sizeof(old)); > > /* Return what we found */ > -- > 1.8.3.1 >