DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Mattias Rönnblom" <mattias.ronnblom@ericsson.com>
To: dev@dpdk.org, Jerin Jacob <jerinj@marvell.com>
Cc: "Thomas Monjalon" <thomas@monjalon.net>,
	"David Marchand" <david.marchand@redhat.com>,
	"Mattias Rönnblom" <mattias.ronnblom@ericsson.com>,
	stable@dpdk.org
Subject: [dpdk-dev] [PATCH v2] event/dsw: fix gcc 4.8 false positive warning
Date: Wed, 15 Apr 2020 20:15:37 +0200	[thread overview]
Message-ID: <20200415181537.30087-1-mattias.ronnblom@ericsson.com> (raw)
In-Reply-To: <9833b305-a133-ae09-da8a-8efadd3ca124@ericsson.com>

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 <mattias.ronnblom@ericsson.com>
---
 drivers/event/dsw/dsw_event.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/event/dsw/dsw_event.c b/drivers/event/dsw/dsw_event.c
index 73a9d38cb..e5e3597aa 100644
--- a/drivers/event/dsw/dsw_event.c
+++ b/drivers/event/dsw/dsw_event.c
@@ -442,10 +442,10 @@ dsw_select_emigration_target(struct dsw_evdev *dsw,
 			    uint8_t *targets_len)
 {
 	int16_t source_port_load = port_loads[source_port_id];
-	struct dsw_queue_flow *candidate_qf;
-	uint8_t candidate_port_id;
+	struct dsw_queue_flow *candidate_qf = NULL;
+	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


  reply	other threads:[~2020-04-15 18:15 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-03-09  6:50 [dpdk-dev] [PATCH 0/8] DSW performance and statistics improvements Mattias Rönnblom
2020-03-09  6:50 ` [dpdk-dev] [PATCH 1/8] event/dsw: reduce latency in low-load situations Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 2/8] event/dsw: reduce max flows to speed up load balancing Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 3/8] event/dsw: extend statistics Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 4/8] event/dsw: improve migration mechanism Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 5/8] event/dsw: avoid migration waves in large systems Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 6/8] event/dsw: remove redundant control ring poll Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 7/8] event/dsw: remove unnecessary read barrier Mattias Rönnblom
2020-03-09  6:51 ` [dpdk-dev] [PATCH 8/8] event/dsw: add port busy cycles xstats Mattias Rönnblom
2020-04-04 14:35 ` [dpdk-dev] [EXT] [PATCH 0/8] DSW performance and statistics improvements Jerin Jacob Kollanukkaran
2020-04-15 16:37   ` David Marchand
2020-04-15 17:39     ` Mattias Rönnblom
2020-04-15 17:45       ` [dpdk-dev] [dpdk-ci] " Thomas Monjalon
2020-04-15 18:09         ` Mattias Rönnblom
2020-04-15 18:15           ` Mattias Rönnblom [this message]
2020-04-15 19:45             ` [dpdk-dev] [PATCH v2] event/dsw: fix gcc 4.8 false positive warning David Marchand
2020-04-16  6:15               ` Mattias Rönnblom

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20200415181537.30087-1-mattias.ronnblom@ericsson.com \
    --to=mattias.ronnblom@ericsson.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=stable@dpdk.org \
    --cc=thomas@monjalon.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).