From e1b8ed33c519015cbe39230654ce313e0aca8830 Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Tue, 14 Jan 2020 17:52:47 +0000 Subject: [PATCH] net/ixgbe: fix build with gcc 4.8.5 MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Build error: In function ‘ixgbe_recv_pkts_lro_bulk_alloc’: ../drivers/net/ixgbe/ixgbe_rxtx.c:2209:24: error: ‘next_sc_entry’ may be used uninitialized in this function [-Werror=maybe-uninitialized] next_sc_entry->fbuf = first_seg; ^ http://mails.dpdk.org/archives/test-report/2020-January/113891.html This is a compiler false positive and error not seen by newer compilers, or clang but to fix the warning initializing the complained variable. According git bisect, no idea how: Fixes: ad43b7bce95b ("net/ixgbe: avoid multiple definitions of bool") Reported-by: Maxime Coquelin Signed-off-by: Ferruh Yigit Tested-by: Maxime Coquelin Acked-by: Xiaolong Ye --- drivers/net/ixgbe/ixgbe_rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c index f41dc13d5e..03c0083cea 100644 --- a/drivers/net/ixgbe/ixgbe_rxtx.c +++ b/drivers/net/ixgbe/ixgbe_rxtx.c @@ -2028,7 +2028,7 @@ ixgbe_recv_pkts_lro(void *rx_queue, struct rte_mbuf **rx_pkts, uint16_t nb_pkts, bool eop; struct ixgbe_rx_entry *rxe; struct ixgbe_scattered_rx_entry *sc_entry; - struct ixgbe_scattered_rx_entry *next_sc_entry; + struct ixgbe_scattered_rx_entry *next_sc_entry = NULL; struct ixgbe_rx_entry *next_rxe = NULL; struct rte_mbuf *first_seg; struct rte_mbuf *rxm; -- 2.20.1