From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id BECCB45E03 for ; Mon, 2 Dec 2024 12:30:06 +0100 (CET) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B8CD74028E; Mon, 2 Dec 2024 12:30:06 +0100 (CET) Received: from dpdk.org (dpdk.org [92.243.24.197]) by mails.dpdk.org (Postfix) with ESMTP id 7BDF24028B for ; Mon, 2 Dec 2024 12:30:05 +0100 (CET) Received: by dpdk.org (Postfix, from userid 65534) id 7734F124519; Mon, 2 Dec 2024 12:30:05 +0100 (CET) Subject: |WARNING| pw148966 [PATCH v1 14/21] net/ice: move Tx queue mbuf cleanup fn to common In-Reply-To: <20241202112444.1517416-15-bruce.richardson@intel.com> References: <20241202112444.1517416-15-bruce.richardson@intel.com> To: test-report@dpdk.org From: checkpatch@dpdk.org Cc: Bruce Richardson Message-Id: <20241202113005.7734F124519@dpdk.org> Date: Mon, 2 Dec 2024 12:30:05 +0100 (CET) X-BeenThere: test-report@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: automatic DPDK test reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: test-report-bounces@dpdk.org Test-Label: checkpatch Test-Status: WARNING http://dpdk.org/patch/148966 _coding style issues_ CHECK:MACRO_ARG_REUSE: Macro argument reuse 'txq' - possible side-effects? #118: FILE: drivers/net/_common_intel/tx.h:275: +#define IETH_FREE_BUFS_LOOP(txq, swr, start) do { \ + uint16_t i = start; \ + if (txq->tx_tail < i) { \ + for (; i < txq->nb_tx_desc; i++) { \ + rte_pktmbuf_free_seg(swr[i].mbuf); \ + swr[i].mbuf = NULL; \ + } \ + i = 0; \ + } \ + for (; i < txq->tx_tail; i++) { \ + rte_pktmbuf_free_seg(swr[i].mbuf); \ + swr[i].mbuf = NULL; \ + } \ +} while (0) CHECK:MACRO_ARG_PRECEDENCE: Macro argument 'txq' may be better as '(txq)' to avoid precedence issues #118: FILE: drivers/net/_common_intel/tx.h:275: +#define IETH_FREE_BUFS_LOOP(txq, swr, start) do { \ + uint16_t i = start; \ + if (txq->tx_tail < i) { \ + for (; i < txq->nb_tx_desc; i++) { \ + rte_pktmbuf_free_seg(swr[i].mbuf); \ + swr[i].mbuf = NULL; \ + } \ + i = 0; \ + } \ + for (; i < txq->tx_tail; i++) { \ + rte_pktmbuf_free_seg(swr[i].mbuf); \ + swr[i].mbuf = NULL; \ + } \ +} while (0) CHECK:MACRO_ARG_REUSE: Macro argument reuse 'swr' - possible side-effects? #118: FILE: drivers/net/_common_intel/tx.h:275: +#define IETH_FREE_BUFS_LOOP(txq, swr, start) do { \ + uint16_t i = start; \ + if (txq->tx_tail < i) { \ + for (; i < txq->nb_tx_desc; i++) { \ + rte_pktmbuf_free_seg(swr[i].mbuf); \ + swr[i].mbuf = NULL; \ + } \ + i = 0; \ + } \ + for (; i < txq->tx_tail; i++) { \ + rte_pktmbuf_free_seg(swr[i].mbuf); \ + swr[i].mbuf = NULL; \ + } \ +} while (0) total: 0 errors, 0 warnings, 3 checks, 253 lines checked