From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f169.google.com (mail-wr0-f169.google.com [209.85.128.169]) by dpdk.org (Postfix) with ESMTP id 706632C5 for ; Thu, 6 Apr 2017 11:16:50 +0200 (CEST) Received: by mail-wr0-f169.google.com with SMTP id t20so51593398wra.1 for ; Thu, 06 Apr 2017 02:16:50 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; bh=gbHy8KMNPLsSQ1/yIB0MCoRW+g9vUglbwhChH22khCs=; b=ti8zZqpW2GV70JOLzutsLoDfxe0vO2fKG0VL5abhsXQFwXz+/ezhAWpzTkvVQVeSaX MMukZLb42rD1hfk44sH42SBWnmX+G5fX8FaE88okBYkU2L6Cd4ATatQONe6FcavSBcB9 lPXP0ywEKNgE7opyWRGAInJtD2GpJjnbLDEJN/+KCk6l5AzW8TgbrW8jFgjFjX2ck5iY dx6oCsdxjfjPvoVJilK6oETiDW53Ixa5j2SRevC+lRQk7JRcQXqb/HOEc1S8/0+W4kpM dk5pvoNTpS2gBYTgJWhjcqjti2GlTYnVBS97XMBHwbiwtjHbMTF9r9fXbkIUTGPp9y76 hBPA== 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:mime-version :content-transfer-encoding; bh=gbHy8KMNPLsSQ1/yIB0MCoRW+g9vUglbwhChH22khCs=; b=CZMeeBH73DBXWQHTdPN2rXm2QQ51ZMqXs3ByVClW05I68nBLbFsgx13GdRBAmgVjMI 9aFbIdokSKY4cl8yT80ZWEYjSbsjzmL2KJr+jM36AFL01Jw7qS0B+wEzxDOzI6QGWYHX tnhcikIYZKpbAVGmSmgiRe+LxkdxswFD4cF+nlsjm0glYGcMVyebPQwq8VTEZ8zUJgp4 +SIpcS4GeBU658NtQdObEUsx9GBEAH1+a9OuirUfVWf9Hald/bBDMXHwS22mTPY+wSZK 2r8sdMYKYOjhBNOwdI6hs6ScViUllEE820913gkgxVJC79kjl6pcpDFfzy/RBHss0zGb +ZnQ== X-Gm-Message-State: AN3rC/7kx4E1ilVOY7VpHHDKMaI88ukawOaEN0UPxl2ofVxYX5LsqTD/Z5cHFSkBte8SZoza X-Received: by 10.28.212.134 with SMTP id l128mr4001275wmg.34.1491470210002; Thu, 06 Apr 2017 02:16:50 -0700 (PDT) Received: from ping.vm.6wind.com (host.78.145.23.62.rev.coltfrance.com. [62.23.145.78]) by smtp.gmail.com with ESMTPSA id j26sm1342459wrb.30.2017.04.06.02.16.49 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 06 Apr 2017 02:16:49 -0700 (PDT) From: Nelio Laranjeiro To: dev@dpdk.org, Ferruh Yigit Cc: Adrien Mazarguil , Olivier Matz , stable@dpdk.org Date: Thu, 6 Apr 2017 11:16:32 +0200 Message-Id: <4b9e3b9e3328d43d5766a39391695e704298d04f.1491470160.git.nelio.laranjeiro@6wind.com> X-Mailer: git-send-email 2.1.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH] net/mlx5: fix an uninitialised variable 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, 06 Apr 2017 09:16:50 -0000 Since patch "mbuf: structure reorganization" the compiler complains .../drivers/net/mlx5/mlx5_rxtx.c: In function ‘mlx5_rx_burst’: .../drivers/net/mlx5/mlx5_rxtx.c:2082:17: error: ‘len’ may be used uninitialized in this function [-Werror=maybe-uninitialized] len is not initialised as it will be at the first segment of a received packet, but it remains hard for the compiler to determine it. Fixes: 9964b965ad69 ("net/mlx5: re-add Rx scatter support") Cc: stable@dpdk.org Signed-off-by: Nelio Laranjeiro Acked-by: Olivier Matz --- drivers/net/mlx5/mlx5_rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/mlx5/mlx5_rxtx.c b/drivers/net/mlx5/mlx5_rxtx.c index 06b699a..fae9d27 100644 --- a/drivers/net/mlx5/mlx5_rxtx.c +++ b/drivers/net/mlx5/mlx5_rxtx.c @@ -1972,7 +1972,7 @@ mlx5_rx_burst(void *dpdk_rxq, struct rte_mbuf **pkts, uint16_t pkts_n) &(*rxq->cqes)[rxq->cq_ci & cqe_cnt]; unsigned int i = 0; unsigned int rq_ci = rxq->rq_ci << sges_n; - int len; /* keep its value across iterations. */ + int len = 0; /* keep its value across iterations. */ while (pkts_n) { unsigned int idx = rq_ci & wqe_cnt; -- 2.1.4