From a99bf9516c8db46a1b8fbb6f8f37e1242b96ee4e Mon Sep 17 00:00:00 2001 From: Ferruh Yigit Date: Mon, 4 Oct 2021 18:27:54 +0100 Subject: [PATCH] net/cxgbe: remove useless address check MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit reported by "gcc (GCC) 12.0.0 20211003 (experimental)": ../drivers/net/cxgbe/cxgbe_ethdev.c: In function ‘cxgbe_dev_rx_queue_setup’: ../drivers/net/cxgbe/cxgbe_ethdev.c:682:24: error: the comparison will always evaluate as ‘true’ for the address of ‘fl’ will never be NULL [-Werror=address] 682 | if ((&rxq->fl) != NULL) | ^~ Fixing it by removing useless check. Signed-off-by: Ferruh Yigit Reviewed-by: Rahul Lakkireddy --- drivers/net/cxgbe/cxgbe_ethdev.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/net/cxgbe/cxgbe_ethdev.c b/drivers/net/cxgbe/cxgbe_ethdev.c index 3abe5c3eed..15d9548f79 100644 --- a/drivers/net/cxgbe/cxgbe_ethdev.c +++ b/drivers/net/cxgbe/cxgbe_ethdev.c @@ -679,8 +679,7 @@ int cxgbe_dev_rx_queue_setup(struct rte_eth_dev *eth_dev, } rxq->rspq.size = temp_nb_desc; - if ((&rxq->fl) != NULL) - rxq->fl.size = temp_nb_desc; + rxq->fl.size = temp_nb_desc; /* Set to jumbo mode if necessary */ if (pkt_len > CXGBE_ETH_MAX_LEN) -- 2.20.1