From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 10528A0577 for ; Wed, 15 Apr 2020 20:07:37 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id E9C8F1D99C; Wed, 15 Apr 2020 20:07:36 +0200 (CEST) Received: from mail.lysator.liu.se (mail.lysator.liu.se [130.236.254.3]) by dpdk.org (Postfix) with ESMTP id 7EBBF1D983; Wed, 15 Apr 2020 20:07:33 +0200 (CEST) Received: from mail.lysator.liu.se (localhost [127.0.0.1]) by mail.lysator.liu.se (Postfix) with ESMTP id E98BC40002; Wed, 15 Apr 2020 20:07:32 +0200 (CEST) Received: by mail.lysator.liu.se (Postfix, from userid 1004) id D71D740013; Wed, 15 Apr 2020 20:07:32 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on bernadotte.lysator.liu.se X-Spam-Level: X-Spam-Status: No, score=-0.9 required=5.0 tests=ALL_TRUSTED,AWL autolearn=disabled version=3.4.2 X-Spam-Score: -0.9 Received: from isengard.friendlyfire.se (host-90-232-146-85.mobileonline.telia.com [90.232.146.85]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.lysator.liu.se (Postfix) with ESMTPSA id 6512840002; Wed, 15 Apr 2020 20:07:29 +0200 (CEST) From: =?UTF-8?q?Mattias=20R=C3=B6nnblom?= To: dev@dpdk.org, Jerin Jacob Cc: Thomas Monjalon , David Marchand , =?UTF-8?q?Mattias=20R=C3=B6nnblom?= , stable@dpdk.org Date: Wed, 15 Apr 2020 20:07:25 +0200 Message-Id: <20200415180725.30875-1-mattias.ronnblom@ericsson.com> X-Mailer: git-send-email 2.20.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Virus-Scanned: ClamAV using ClamSMTP Subject: [dpdk-stable] [PATCH] event/dsw: fix gcc 4.8 false positive warning X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Add redundant stack variable initialization to work around false-positive warnings in older versions of GCC. Fixes: bba7a1aeef46 ("event/dsw: improve migration mechanism") Cc: stable@dpdk.org Signed-off-by: Mattias Rönnblom --- drivers/event/dsw/dsw_event.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/event/dsw/dsw_event.c b/drivers/event/dsw/dsw_event.c index 73a9d38cb..ff5908239 100644 --- a/drivers/event/dsw/dsw_event.c +++ b/drivers/event/dsw/dsw_event.c @@ -443,9 +443,9 @@ dsw_select_emigration_target(struct dsw_evdev *dsw, { int16_t source_port_load = port_loads[source_port_id]; struct dsw_queue_flow *candidate_qf; - uint8_t candidate_port_id; + uint8_t candidate_port_id = 0; int16_t candidate_weight = -1; - int16_t candidate_flow_load; + int16_t candidate_flow_load = -1; uint16_t i; if (source_port_load < DSW_MIN_SOURCE_LOAD_FOR_MIGRATION) -- 2.20.1