patches for DPDK stable branches
 help / color / mirror / Atom feed
* [dpdk-stable] [PATCH] event/dsw: fix gcc 4.8 false positive warning
@ 2020-04-15 18:07 Mattias Rönnblom
  2020-04-15 18:13 ` Mattias Rönnblom
  0 siblings, 1 reply; 2+ messages in thread
From: Mattias Rönnblom @ 2020-04-15 18:07 UTC (permalink / raw)
  To: dev, Jerin Jacob
  Cc: Thomas Monjalon, David Marchand, Mattias Rönnblom, 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 <mattias.ronnblom@ericsson.com>
---
 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


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-04-15 18:13 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-15 18:07 [dpdk-stable] [PATCH] event/dsw: fix gcc 4.8 false positive warning Mattias Rönnblom
2020-04-15 18:13 ` Mattias Rönnblom

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).