From patchwork Wed May 29 23:33:35 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140409 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DD94C44107; Thu, 30 May 2024 01:39:00 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id B614C406FF; Thu, 30 May 2024 01:38:56 +0200 (CEST) Received: from mail-pj1-f53.google.com (mail-pj1-f53.google.com [209.85.216.53]) by mails.dpdk.org (Postfix) with ESMTP id C139740289 for ; Thu, 30 May 2024 01:38:16 +0200 (CEST) Received: by mail-pj1-f53.google.com with SMTP id 98e67ed59e1d1-2c034b016e6so217885a91.2 for ; Wed, 29 May 2024 16:38:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025896; x=1717630696; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=wIRtwXKIrqNQSsWobASkHGJI5DCTSUy+XFGOBH9YNo8=; b=keUVdGuSZYOqSeWEx6P7moqAYA4Pk3KPljlG0YeIsoBTmWkjs5J2GDmT43OnF5Est4 +37y29AOwwhatmIwl5Oeuq0E9X0mu7eTeFEdrq61Jb6u1Rz78xkYT99hZoECuSTfVFqW R+MOffckXgQv5xoSbwq2ozNAjHqd0yPmoekRRTo1ZCtNsXxXLavEJn2KxKRD7kMbTvmX /N7jBdl+anxv2jl8HlhGhjkdvp59Qx2lqTa2URNCsAIL0HRpIq+O9ZgzuF8I340YZu7Q Zon/I3RStB9yit0ZGj7xhzK0eT6EGLY+HwzkhPB7upG6DYS217Cc38UDT7vQuBqSRjKt 3TmA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025896; x=1717630696; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wIRtwXKIrqNQSsWobASkHGJI5DCTSUy+XFGOBH9YNo8=; b=ZqGttnVmdjCgWT1ALdmPZwkHrvB62/+RKva+xHAsbT2DkTw0rc7ChGd6brgIY/9XAh 1CdSjnSzq+NMvrVk4zx9W/bVwJufXHexLAANB6ZldMNPEJgPsvyk+Ou9q9+xdRDhUT54 +LSpKl9OpyuS05Y81DPdc2fIeSZ8iZg28M6UWBeE2NQlC75FabThVJjEfgK/yyCEUHU3 kkpYaIS70DXvB+zRUzOuwrSWijzREVSN1irwsOQ+ugUdqKUZ3VkGnQq33vZafWQE5z35 EszQ46x3tKBZdFxbU1UvamHX8lSUu9Fnx/s9qW1cZMMeB3FIGM+0NKcgfleqQPySLfwr F8FQ== X-Gm-Message-State: AOJu0Yy0o2MhzZ6xEkgazypl5FWsloIzwB40cMp5fBQi39xshPgl1TMQ BTP6RJeWSfuz/dn6Rd/T38g8LVAZYkXH2opSkGfoLECJTd0rzsKyJz0JYqpRefyq8aEmz+sDJ6P h X-Google-Smtp-Source: AGHT+IFtlfD7rBHzHD2ccgGU2fqc6tBxikQzssmxS4kgQNjFoGMXwINsJ55QNqFti3uCl3fTLl9chA== X-Received: by 2002:a17:90b:944:b0:2bd:f708:ff0f with SMTP id 98e67ed59e1d1-2c1abbf7fabmr637812a91.21.1717025895714; Wed, 29 May 2024 16:38:15 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.14 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:15 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Andrew Rybchenko , =?utf-8?q?Morten_Br=C3=B8?= =?utf-8?q?rup?= Subject: [PATCH v10 01/20] mbuf: replace term sanity check Date: Wed, 29 May 2024 16:33:35 -0700 Message-ID: <20240529233811.663211-2-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Replace rte_mbuf_sanity_check() with rte_mbuf_verify() to match the similar macro RTE_VERIFY() in rte_debug.h The term sanity check is on the Tier 2 list of words that should be replaced. Signed-off-by: Stephen Hemminger Acked-by: Andrew Rybchenko Acked-by: Morten Brørup --- app/test/test_mbuf.c | 28 +++++------ doc/guides/prog_guide/mbuf_lib.rst | 4 +- doc/guides/rel_notes/deprecation.rst | 3 ++ drivers/net/avp/avp_ethdev.c | 18 +++---- drivers/net/sfc/sfc_ef100_rx.c | 6 +-- drivers/net/sfc/sfc_ef10_essb_rx.c | 4 +- drivers/net/sfc/sfc_ef10_rx.c | 4 +- drivers/net/sfc/sfc_rx.c | 2 +- examples/ipv4_multicast/main.c | 2 +- lib/mbuf/rte_mbuf.c | 23 +++++---- lib/mbuf/rte_mbuf.h | 71 +++++++++++++++------------- lib/mbuf/version.map | 1 + 12 files changed, 90 insertions(+), 76 deletions(-) diff --git a/app/test/test_mbuf.c b/app/test/test_mbuf.c index 17be977f31..3fbb5dea8b 100644 --- a/app/test/test_mbuf.c +++ b/app/test/test_mbuf.c @@ -262,8 +262,8 @@ test_one_pktmbuf(struct rte_mempool *pktmbuf_pool) GOTO_FAIL("Buffer should be continuous"); memset(hdr, 0x55, MBUF_TEST_HDR2_LEN); - rte_mbuf_sanity_check(m, 1); - rte_mbuf_sanity_check(m, 0); + rte_mbuf_verify(m, 1); + rte_mbuf_verify(m, 0); rte_pktmbuf_dump(stdout, m, 0); /* this prepend should fail */ @@ -1162,7 +1162,7 @@ test_refcnt_mbuf(void) #ifdef RTE_EXEC_ENV_WINDOWS static int -test_failing_mbuf_sanity_check(struct rte_mempool *pktmbuf_pool) +test_failing_mbuf_verify(struct rte_mempool *pktmbuf_pool) { RTE_SET_USED(pktmbuf_pool); return TEST_SKIPPED; @@ -1181,12 +1181,12 @@ mbuf_check_pass(struct rte_mbuf *buf) } static int -test_failing_mbuf_sanity_check(struct rte_mempool *pktmbuf_pool) +test_failing_mbuf_verify(struct rte_mempool *pktmbuf_pool) { struct rte_mbuf *buf; struct rte_mbuf badbuf; - printf("Checking rte_mbuf_sanity_check for failure conditions\n"); + printf("Checking rte_mbuf_verify for failure conditions\n"); /* get a good mbuf to use to make copies */ buf = rte_pktmbuf_alloc(pktmbuf_pool); @@ -1708,7 +1708,7 @@ test_mbuf_validate_tx_offload(const char *test_name, GOTO_FAIL("%s: mbuf allocation failed!\n", __func__); if (rte_pktmbuf_pkt_len(m) != 0) GOTO_FAIL("%s: Bad packet length\n", __func__); - rte_mbuf_sanity_check(m, 0); + rte_mbuf_verify(m, 0); m->ol_flags = ol_flags; m->tso_segsz = segsize; ret = rte_validate_tx_offload(m); @@ -1915,7 +1915,7 @@ test_pktmbuf_read(struct rte_mempool *pktmbuf_pool) GOTO_FAIL("%s: mbuf allocation failed!\n", __func__); if (rte_pktmbuf_pkt_len(m) != 0) GOTO_FAIL("%s: Bad packet length\n", __func__); - rte_mbuf_sanity_check(m, 0); + rte_mbuf_verify(m, 0); data = rte_pktmbuf_append(m, MBUF_TEST_DATA_LEN2); if (data == NULL) @@ -1964,7 +1964,7 @@ test_pktmbuf_read_from_offset(struct rte_mempool *pktmbuf_pool) if (rte_pktmbuf_pkt_len(m) != 0) GOTO_FAIL("%s: Bad packet length\n", __func__); - rte_mbuf_sanity_check(m, 0); + rte_mbuf_verify(m, 0); /* prepend an ethernet header */ hdr = (struct ether_hdr *)rte_pktmbuf_prepend(m, hdr_len); @@ -2109,7 +2109,7 @@ create_packet(struct rte_mempool *pktmbuf_pool, GOTO_FAIL("%s: mbuf allocation failed!\n", __func__); if (rte_pktmbuf_pkt_len(pkt_seg) != 0) GOTO_FAIL("%s: Bad packet length\n", __func__); - rte_mbuf_sanity_check(pkt_seg, 0); + rte_mbuf_verify(pkt_seg, 0); /* Add header only for the first segment */ if (test_data->flags == MBUF_HEADER && seg == 0) { hdr_len = sizeof(struct rte_ether_hdr); @@ -2321,7 +2321,7 @@ test_pktmbuf_ext_shinfo_init_helper(struct rte_mempool *pktmbuf_pool) GOTO_FAIL("%s: mbuf allocation failed!\n", __func__); if (rte_pktmbuf_pkt_len(m) != 0) GOTO_FAIL("%s: Bad packet length\n", __func__); - rte_mbuf_sanity_check(m, 0); + rte_mbuf_verify(m, 0); ext_buf_addr = rte_malloc("External buffer", buf_len, RTE_CACHE_LINE_SIZE); @@ -2482,8 +2482,8 @@ test_pktmbuf_ext_pinned_buffer(struct rte_mempool *std_pool) GOTO_FAIL("%s: test_pktmbuf_copy(pinned) failed\n", __func__); - if (test_failing_mbuf_sanity_check(pinned_pool) < 0) - GOTO_FAIL("%s: test_failing_mbuf_sanity_check(pinned)" + if (test_failing_mbuf_verify(pinned_pool) < 0) + GOTO_FAIL("%s: test_failing_mbuf_verify(pinned)" " failed\n", __func__); if (test_mbuf_linearize_check(pinned_pool) < 0) @@ -2857,8 +2857,8 @@ test_mbuf(void) goto err; } - if (test_failing_mbuf_sanity_check(pktmbuf_pool) < 0) { - printf("test_failing_mbuf_sanity_check() failed\n"); + if (test_failing_mbuf_verify(pktmbuf_pool) < 0) { + printf("test_failing_mbuf_verify() failed\n"); goto err; } diff --git a/doc/guides/prog_guide/mbuf_lib.rst b/doc/guides/prog_guide/mbuf_lib.rst index 049357c755..0accb51a98 100644 --- a/doc/guides/prog_guide/mbuf_lib.rst +++ b/doc/guides/prog_guide/mbuf_lib.rst @@ -266,8 +266,8 @@ can be found in several of the sample applications, for example, the IPv4 Multic Debug ----- -In debug mode, the functions of the mbuf library perform sanity checks before any operation (such as, buffer corruption, -bad type, and so on). +In debug mode, the functions of the mbuf library perform consistency checks +before any operation (such as, buffer corruption, bad type, and so on). Use Cases --------- diff --git a/doc/guides/rel_notes/deprecation.rst b/doc/guides/rel_notes/deprecation.rst index 6948641ff6..6b4a3102ca 100644 --- a/doc/guides/rel_notes/deprecation.rst +++ b/doc/guides/rel_notes/deprecation.rst @@ -147,3 +147,6 @@ Deprecation Notices will be deprecated and subsequently removed in DPDK 24.11 release. Before this, the new port library API (functions rte_swx_port_*) will gradually transition from experimental to stable status. + +* mbuf: The function ``rte_mbuf_sanity_check`` is deprecated. + Use the new function ``rte_mbuf_verify`` instead. diff --git a/drivers/net/avp/avp_ethdev.c b/drivers/net/avp/avp_ethdev.c index 6733462c86..bafc08fd60 100644 --- a/drivers/net/avp/avp_ethdev.c +++ b/drivers/net/avp/avp_ethdev.c @@ -1231,7 +1231,7 @@ _avp_mac_filter(struct avp_dev *avp, struct rte_mbuf *m) #ifdef RTE_LIBRTE_AVP_DEBUG_BUFFERS static inline void -__avp_dev_buffer_sanity_check(struct avp_dev *avp, struct rte_avp_desc *buf) +__avp_dev_buffer_check(struct avp_dev *avp, struct rte_avp_desc *buf) { struct rte_avp_desc *first_buf; struct rte_avp_desc *pkt_buf; @@ -1272,12 +1272,12 @@ __avp_dev_buffer_sanity_check(struct avp_dev *avp, struct rte_avp_desc *buf) first_buf->pkt_len, pkt_len); } -#define avp_dev_buffer_sanity_check(a, b) \ - __avp_dev_buffer_sanity_check((a), (b)) +#define avp_dev_buffer_check(a, b) \ + __avp_dev_buffer_check((a), (b)) #else /* RTE_LIBRTE_AVP_DEBUG_BUFFERS */ -#define avp_dev_buffer_sanity_check(a, b) do {} while (0) +#define avp_dev_buffer_check(a, b) do {} while (0) #endif @@ -1302,7 +1302,7 @@ avp_dev_copy_from_buffers(struct avp_dev *avp, void *pkt_data; unsigned int i; - avp_dev_buffer_sanity_check(avp, buf); + avp_dev_buffer_check(avp, buf); /* setup the first source buffer */ pkt_buf = avp_dev_translate_buffer(avp, buf); @@ -1370,7 +1370,7 @@ avp_dev_copy_from_buffers(struct avp_dev *avp, rte_pktmbuf_pkt_len(m) = total_length; m->vlan_tci = vlan_tci; - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); return m; } @@ -1614,7 +1614,7 @@ avp_dev_copy_to_buffers(struct avp_dev *avp, char *pkt_data; unsigned int i; - __rte_mbuf_sanity_check(mbuf, 1); + __rte_mbuf_verify(mbuf, 1); m = mbuf; src_offset = 0; @@ -1680,7 +1680,7 @@ avp_dev_copy_to_buffers(struct avp_dev *avp, first_buf->vlan_tci = mbuf->vlan_tci; } - avp_dev_buffer_sanity_check(avp, buffers[0]); + avp_dev_buffer_check(avp, buffers[0]); return total_length; } @@ -1798,7 +1798,7 @@ avp_xmit_scattered_pkts(void *tx_queue, #ifdef RTE_LIBRTE_AVP_DEBUG_BUFFERS for (i = 0; i < nb_pkts; i++) - avp_dev_buffer_sanity_check(avp, tx_bufs[i]); + avp_dev_buffer_check(avp, tx_bufs[i]); #endif /* send the packets */ diff --git a/drivers/net/sfc/sfc_ef100_rx.c b/drivers/net/sfc/sfc_ef100_rx.c index e283879e6b..5ebfba4dcf 100644 --- a/drivers/net/sfc/sfc_ef100_rx.c +++ b/drivers/net/sfc/sfc_ef100_rx.c @@ -179,7 +179,7 @@ sfc_ef100_rx_qrefill(struct sfc_ef100_rxq *rxq) struct sfc_ef100_rx_sw_desc *rxd; rte_iova_t dma_addr; - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); dma_addr = rte_mbuf_data_iova_default(m); if (rxq->flags & SFC_EF100_RXQ_NIC_DMA_MAP) { @@ -551,7 +551,7 @@ sfc_ef100_rx_process_ready_pkts(struct sfc_ef100_rxq *rxq, rxq->ready_pkts--; pkt = sfc_ef100_rx_next_mbuf(rxq); - __rte_mbuf_raw_sanity_check(pkt); + __rte_mbuf_raw_verify(pkt); RTE_BUILD_BUG_ON(sizeof(pkt->rearm_data[0]) != sizeof(rxq->rearm_data)); @@ -575,7 +575,7 @@ sfc_ef100_rx_process_ready_pkts(struct sfc_ef100_rxq *rxq, struct rte_mbuf *seg; seg = sfc_ef100_rx_next_mbuf(rxq); - __rte_mbuf_raw_sanity_check(seg); + __rte_mbuf_raw_verify(seg); seg->data_off = RTE_PKTMBUF_HEADROOM; diff --git a/drivers/net/sfc/sfc_ef10_essb_rx.c b/drivers/net/sfc/sfc_ef10_essb_rx.c index 78bd430363..74647e2792 100644 --- a/drivers/net/sfc/sfc_ef10_essb_rx.c +++ b/drivers/net/sfc/sfc_ef10_essb_rx.c @@ -125,7 +125,7 @@ sfc_ef10_essb_next_mbuf(const struct sfc_ef10_essb_rxq *rxq, struct rte_mbuf *m; m = (struct rte_mbuf *)((uintptr_t)mbuf + rxq->buf_stride); - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); return m; } @@ -136,7 +136,7 @@ sfc_ef10_essb_mbuf_by_index(const struct sfc_ef10_essb_rxq *rxq, struct rte_mbuf *m; m = (struct rte_mbuf *)((uintptr_t)mbuf + idx * rxq->buf_stride); - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); return m; } diff --git a/drivers/net/sfc/sfc_ef10_rx.c b/drivers/net/sfc/sfc_ef10_rx.c index 60442930b3..f4fc815570 100644 --- a/drivers/net/sfc/sfc_ef10_rx.c +++ b/drivers/net/sfc/sfc_ef10_rx.c @@ -148,7 +148,7 @@ sfc_ef10_rx_qrefill(struct sfc_ef10_rxq *rxq) struct sfc_ef10_rx_sw_desc *rxd; rte_iova_t phys_addr; - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); SFC_ASSERT((id & ~ptr_mask) == 0); rxd = &rxq->sw_ring[id]; @@ -297,7 +297,7 @@ sfc_ef10_rx_process_event(struct sfc_ef10_rxq *rxq, efx_qword_t rx_ev, rxd = &rxq->sw_ring[pending++ & ptr_mask]; m = rxd->mbuf; - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); m->data_off = RTE_PKTMBUF_HEADROOM; rte_pktmbuf_data_len(m) = seg_len; diff --git a/drivers/net/sfc/sfc_rx.c b/drivers/net/sfc/sfc_rx.c index a193229265..c885ce2b05 100644 --- a/drivers/net/sfc/sfc_rx.c +++ b/drivers/net/sfc/sfc_rx.c @@ -120,7 +120,7 @@ sfc_efx_rx_qrefill(struct sfc_efx_rxq *rxq) ++i, id = (id + 1) & rxq->ptr_mask) { m = objs[i]; - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); rxd = &rxq->sw_desc[id]; rxd->mbuf = m; diff --git a/examples/ipv4_multicast/main.c b/examples/ipv4_multicast/main.c index 1eed645d02..3bfab37012 100644 --- a/examples/ipv4_multicast/main.c +++ b/examples/ipv4_multicast/main.c @@ -258,7 +258,7 @@ mcast_out_pkt(struct rte_mbuf *pkt, int use_clone) hdr->pkt_len = (uint16_t)(hdr->data_len + pkt->pkt_len); hdr->nb_segs = pkt->nb_segs + 1; - __rte_mbuf_sanity_check(hdr, 1); + __rte_mbuf_verify(hdr, 1); return hdr; } /* >8 End of mcast_out_kt. */ diff --git a/lib/mbuf/rte_mbuf.c b/lib/mbuf/rte_mbuf.c index 559d5ad8a7..fc5d4ba29d 100644 --- a/lib/mbuf/rte_mbuf.c +++ b/lib/mbuf/rte_mbuf.c @@ -367,9 +367,9 @@ rte_pktmbuf_pool_create_extbuf(const char *name, unsigned int n, return mp; } -/* do some sanity checks on a mbuf: panic if it fails */ +/* do some checks on a mbuf: panic if it fails */ void -rte_mbuf_sanity_check(const struct rte_mbuf *m, int is_header) +rte_mbuf_verify(const struct rte_mbuf *m, int is_header) { const char *reason; @@ -377,6 +377,13 @@ rte_mbuf_sanity_check(const struct rte_mbuf *m, int is_header) rte_panic("%s\n", reason); } +/* For ABI compatibility, to be removed in next release */ +void +rte_mbuf_sanity_check(const struct rte_mbuf *m, int is_header) +{ + rte_mbuf_verify(m, is_header); +} + int rte_mbuf_check(const struct rte_mbuf *m, int is_header, const char **reason) { @@ -496,7 +503,7 @@ void rte_pktmbuf_free_bulk(struct rte_mbuf **mbufs, unsigned int count) if (unlikely(m == NULL)) continue; - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); do { m_next = m->next; @@ -546,7 +553,7 @@ rte_pktmbuf_clone(struct rte_mbuf *md, struct rte_mempool *mp) return NULL; } - __rte_mbuf_sanity_check(mc, 1); + __rte_mbuf_verify(mc, 1); return mc; } @@ -596,7 +603,7 @@ rte_pktmbuf_copy(const struct rte_mbuf *m, struct rte_mempool *mp, struct rte_mbuf *mc, *m_last, **prev; /* garbage in check */ - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); /* check for request to copy at offset past end of mbuf */ if (unlikely(off >= m->pkt_len)) @@ -660,7 +667,7 @@ rte_pktmbuf_copy(const struct rte_mbuf *m, struct rte_mempool *mp, } /* garbage out check */ - __rte_mbuf_sanity_check(mc, 1); + __rte_mbuf_verify(mc, 1); return mc; } @@ -671,7 +678,7 @@ rte_pktmbuf_dump(FILE *f, const struct rte_mbuf *m, unsigned dump_len) unsigned int len; unsigned int nb_segs; - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); fprintf(f, "dump mbuf at %p, iova=%#" PRIx64 ", buf_len=%u\n", m, rte_mbuf_iova_get(m), m->buf_len); @@ -689,7 +696,7 @@ rte_pktmbuf_dump(FILE *f, const struct rte_mbuf *m, unsigned dump_len) nb_segs = m->nb_segs; while (m && nb_segs != 0) { - __rte_mbuf_sanity_check(m, 0); + __rte_mbuf_verify(m, 0); fprintf(f, " segment at %p, data=%p, len=%u, off=%u, refcnt=%u\n", m, rte_pktmbuf_mtod(m, void *), diff --git a/lib/mbuf/rte_mbuf.h b/lib/mbuf/rte_mbuf.h index 286b32b788..380663a089 100644 --- a/lib/mbuf/rte_mbuf.h +++ b/lib/mbuf/rte_mbuf.h @@ -339,13 +339,13 @@ rte_pktmbuf_priv_flags(struct rte_mempool *mp) #ifdef RTE_LIBRTE_MBUF_DEBUG -/** check mbuf type in debug mode */ -#define __rte_mbuf_sanity_check(m, is_h) rte_mbuf_sanity_check(m, is_h) +/** do mbuf type in debug mode */ +#define __rte_mbuf_verify(m, is_h) rte_mbuf_verify(m, is_h) #else /* RTE_LIBRTE_MBUF_DEBUG */ -/** check mbuf type in debug mode */ -#define __rte_mbuf_sanity_check(m, is_h) do { } while (0) +/** ignore mbuf checks if not in debug mode */ +#define __rte_mbuf_verify(m, is_h) do { } while (0) #endif /* RTE_LIBRTE_MBUF_DEBUG */ @@ -514,10 +514,9 @@ rte_mbuf_ext_refcnt_update(struct rte_mbuf_ext_shared_info *shinfo, /** - * Sanity checks on an mbuf. + * Check that the mbuf is valid and panic if corrupted. * - * Check the consistency of the given mbuf. The function will cause a - * panic if corruption is detected. + * Acts assertion that mbuf is consistent. If not it calls rte_panic(). * * @param m * The mbuf to be checked. @@ -526,13 +525,17 @@ rte_mbuf_ext_refcnt_update(struct rte_mbuf_ext_shared_info *shinfo, * of a packet (in this case, some fields like nb_segs are not checked) */ void +rte_mbuf_verify(const struct rte_mbuf *m, int is_header); + +/* Older deprecated name for rte_mbuf_verify() */ +void __rte_deprecated rte_mbuf_sanity_check(const struct rte_mbuf *m, int is_header); /** - * Sanity checks on a mbuf. + * Do consistency checks on a mbuf. * - * Almost like rte_mbuf_sanity_check(), but this function gives the reason - * if corruption is detected rather than panic. + * Check the consistency of the given mbuf and if not valid + * return the reason. * * @param m * The mbuf to be checked. @@ -551,7 +554,7 @@ int rte_mbuf_check(const struct rte_mbuf *m, int is_header, const char **reason); /** - * Sanity checks on a reinitialized mbuf in debug mode. + * Do checks on a reinitialized mbuf in debug mode. * * Check the consistency of the given reinitialized mbuf. * The function will cause a panic if corruption is detected. @@ -563,16 +566,16 @@ int rte_mbuf_check(const struct rte_mbuf *m, int is_header, * The mbuf to be checked. */ static __rte_always_inline void -__rte_mbuf_raw_sanity_check(__rte_unused const struct rte_mbuf *m) +__rte_mbuf_raw_verify(__rte_unused const struct rte_mbuf *m) { RTE_ASSERT(rte_mbuf_refcnt_read(m) == 1); RTE_ASSERT(m->next == NULL); RTE_ASSERT(m->nb_segs == 1); - __rte_mbuf_sanity_check(m, 0); + __rte_mbuf_verify(m, 0); } /** For backwards compatibility. */ -#define MBUF_RAW_ALLOC_CHECK(m) __rte_mbuf_raw_sanity_check(m) +#define MBUF_RAW_ALLOC_CHECK(m) __rte_mbuf_raw_verify(m) /** * Allocate an uninitialized mbuf from mempool *mp*. @@ -599,7 +602,7 @@ static inline struct rte_mbuf *rte_mbuf_raw_alloc(struct rte_mempool *mp) if (rte_mempool_get(mp, (void **)&m) < 0) return NULL; - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); return m; } @@ -622,7 +625,7 @@ rte_mbuf_raw_free(struct rte_mbuf *m) { RTE_ASSERT(!RTE_MBUF_CLONED(m) && (!RTE_MBUF_HAS_EXTBUF(m) || RTE_MBUF_HAS_PINNED_EXTBUF(m))); - __rte_mbuf_raw_sanity_check(m); + __rte_mbuf_raw_verify(m); rte_mempool_put(m->pool, m); } @@ -885,7 +888,7 @@ static inline void rte_pktmbuf_reset(struct rte_mbuf *m) rte_pktmbuf_reset_headroom(m); m->data_len = 0; - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); } /** @@ -941,22 +944,22 @@ static inline int rte_pktmbuf_alloc_bulk(struct rte_mempool *pool, switch (count % 4) { case 0: while (idx != count) { - __rte_mbuf_raw_sanity_check(mbufs[idx]); + __rte_mbuf_raw_verify(mbufs[idx]); rte_pktmbuf_reset(mbufs[idx]); idx++; /* fall-through */ case 3: - __rte_mbuf_raw_sanity_check(mbufs[idx]); + __rte_mbuf_raw_verify(mbufs[idx]); rte_pktmbuf_reset(mbufs[idx]); idx++; /* fall-through */ case 2: - __rte_mbuf_raw_sanity_check(mbufs[idx]); + __rte_mbuf_raw_verify(mbufs[idx]); rte_pktmbuf_reset(mbufs[idx]); idx++; /* fall-through */ case 1: - __rte_mbuf_raw_sanity_check(mbufs[idx]); + __rte_mbuf_raw_verify(mbufs[idx]); rte_pktmbuf_reset(mbufs[idx]); idx++; /* fall-through */ @@ -1184,8 +1187,8 @@ static inline void rte_pktmbuf_attach(struct rte_mbuf *mi, struct rte_mbuf *m) mi->pkt_len = mi->data_len; mi->nb_segs = 1; - __rte_mbuf_sanity_check(mi, 1); - __rte_mbuf_sanity_check(m, 0); + __rte_mbuf_verify(mi, 1); + __rte_mbuf_verify(m, 0); } /** @@ -1340,7 +1343,7 @@ static inline int __rte_pktmbuf_pinned_extbuf_decref(struct rte_mbuf *m) static __rte_always_inline struct rte_mbuf * rte_pktmbuf_prefree_seg(struct rte_mbuf *m) { - __rte_mbuf_sanity_check(m, 0); + __rte_mbuf_verify(m, 0); if (likely(rte_mbuf_refcnt_read(m) == 1)) { @@ -1411,7 +1414,7 @@ static inline void rte_pktmbuf_free(struct rte_mbuf *m) struct rte_mbuf *m_next; if (m != NULL) - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); while (m != NULL) { m_next = m->next; @@ -1492,7 +1495,7 @@ rte_pktmbuf_copy(const struct rte_mbuf *m, struct rte_mempool *mp, */ static inline void rte_pktmbuf_refcnt_update(struct rte_mbuf *m, int16_t v) { - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); do { rte_mbuf_refcnt_update(m, v); @@ -1509,7 +1512,7 @@ static inline void rte_pktmbuf_refcnt_update(struct rte_mbuf *m, int16_t v) */ static inline uint16_t rte_pktmbuf_headroom(const struct rte_mbuf *m) { - __rte_mbuf_sanity_check(m, 0); + __rte_mbuf_verify(m, 0); return m->data_off; } @@ -1523,7 +1526,7 @@ static inline uint16_t rte_pktmbuf_headroom(const struct rte_mbuf *m) */ static inline uint16_t rte_pktmbuf_tailroom(const struct rte_mbuf *m) { - __rte_mbuf_sanity_check(m, 0); + __rte_mbuf_verify(m, 0); return (uint16_t)(m->buf_len - rte_pktmbuf_headroom(m) - m->data_len); } @@ -1538,7 +1541,7 @@ static inline uint16_t rte_pktmbuf_tailroom(const struct rte_mbuf *m) */ static inline struct rte_mbuf *rte_pktmbuf_lastseg(struct rte_mbuf *m) { - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); while (m->next != NULL) m = m->next; return m; @@ -1582,7 +1585,7 @@ static inline struct rte_mbuf *rte_pktmbuf_lastseg(struct rte_mbuf *m) static inline char *rte_pktmbuf_prepend(struct rte_mbuf *m, uint16_t len) { - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); if (unlikely(len > rte_pktmbuf_headroom(m))) return NULL; @@ -1617,7 +1620,7 @@ static inline char *rte_pktmbuf_append(struct rte_mbuf *m, uint16_t len) void *tail; struct rte_mbuf *m_last; - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); m_last = rte_pktmbuf_lastseg(m); if (unlikely(len > rte_pktmbuf_tailroom(m_last))) @@ -1645,7 +1648,7 @@ static inline char *rte_pktmbuf_append(struct rte_mbuf *m, uint16_t len) */ static inline char *rte_pktmbuf_adj(struct rte_mbuf *m, uint16_t len) { - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); if (unlikely(len > m->data_len)) return NULL; @@ -1677,7 +1680,7 @@ static inline int rte_pktmbuf_trim(struct rte_mbuf *m, uint16_t len) { struct rte_mbuf *m_last; - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); m_last = rte_pktmbuf_lastseg(m); if (unlikely(len > m_last->data_len)) @@ -1699,7 +1702,7 @@ static inline int rte_pktmbuf_trim(struct rte_mbuf *m, uint16_t len) */ static inline int rte_pktmbuf_is_contiguous(const struct rte_mbuf *m) { - __rte_mbuf_sanity_check(m, 1); + __rte_mbuf_verify(m, 1); return m->nb_segs == 1; } diff --git a/lib/mbuf/version.map b/lib/mbuf/version.map index daa65e2bbd..c85370e430 100644 --- a/lib/mbuf/version.map +++ b/lib/mbuf/version.map @@ -31,6 +31,7 @@ DPDK_24 { rte_mbuf_set_platform_mempool_ops; rte_mbuf_set_user_mempool_ops; rte_mbuf_user_mempool_ops; + rte_mbuf_verify; rte_pktmbuf_clone; rte_pktmbuf_copy; rte_pktmbuf_dump; From patchwork Wed May 29 23:33:36 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140410 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 0759044107; Thu, 30 May 2024 01:39:07 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EA5A040A6C; Thu, 30 May 2024 01:38:57 +0200 (CEST) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mails.dpdk.org (Postfix) with ESMTP id 9FA0F40289 for ; Thu, 30 May 2024 01:38:17 +0200 (CEST) Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-2c1a16805f9so411629a91.0 for ; Wed, 29 May 2024 16:38:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025897; x=1717630697; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=QvV2qmdLs4RKcERhNJ4V15AwUB0YcGmKeHwuxo7W6+c=; b=tTmUTkr8l3sT9TXEXTE8c3KDAs9kjIcYy9KvoCEz5eh5yNjSLeY+IFQ4jd5Ekv+YFg YOMppKpiabuGUjJf0CrnInvVzDH9VT0q9uyc6hCKZdp3WYVrF05vtN0iz+6PI98YmNHB auS3LdiqaLB6PFnRhmXc+KAB/H8TTK/VOtWY2Rhin+F9/yhlgrRm/bnNwIbTiidcx3iY 7M5a0sqKHT155oNUAINvFYvQeDIcn/6pXDx+ZZP0ezMlPZjkuek1aNmFumIswmb8DWkn u4tyRVvpy4qCJEWr8Y9aXA+VOLcbvh6VnMGmrgSnOYhFwbTcMha86UcOc5GKKSD2Hxmp 7Eyw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025897; x=1717630697; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=QvV2qmdLs4RKcERhNJ4V15AwUB0YcGmKeHwuxo7W6+c=; b=wbZesPeLIGe5yQzwAXBiLXSIrsiWxMTgPkh2rrBUlG1hmv7159f5d6c8wCe2YtHxY8 T8qWoUkBCPP3x4CEXTqTywY6bAARPmQpjHa+W1zRa7aGgqnRrdVAiBypKFhaajZxfihh BjoJsJaOsDp/ljde2EworJmnrDOjoOzYe70yZhB3l7PepUk3Pbmd1NqN/0g+z8DHkcT8 9PKDijnw3HbrSg1zMn/3ZlITglvwxaBRqC++14qQpEdsndIYSsr/09tPkzU/3OG1r8wR K9jMjUThHbCa4jY4KlC3WthfB7pkn6G5ePlgjT9KW3MyTb2jNqY7n13vCW75MRe83g94 vBsA== X-Gm-Message-State: AOJu0Yzq7HWabH90GPz6/g3I5YHo4I/ZwWxGd+xzksNeXVXeePdHSpWD Sub9W8BuFFyzMSZJEdW5s4hVB7tU8TmrY7EEnKuL5sLkcUKl0A2hUu997TrJCyQaVqPsgd3rEgZ F X-Google-Smtp-Source: AGHT+IGz9udbv7jY0fO2st+rhHQ3nWr8CbQSYlgOKfFodtM5Rq4HFt8255y5xjNtvYXW8InqjmKoQQ== X-Received: by 2002:a17:90a:f00c:b0:2c1:a546:350d with SMTP id 98e67ed59e1d1-2c1acc2d871mr403123a91.4.1717025896600; Wed, 29 May 2024 16:38:16 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:16 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Anatoly Burakov Subject: [PATCH v10 02/20] eal: replace use of sanity check in comments and messages Date: Wed, 29 May 2024 16:33:36 -0700 Message-ID: <20240529233811.663211-3-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sanity check is on the Tier 2 non-inclusive list. Replace or remove it. Signed-off-by: Stephen Hemminger Acked-by: Anatoly Burakov Acked-by: Morten Brørup --- lib/eal/common/eal_common_memory.c | 2 +- lib/eal/common/eal_common_proc.c | 3 ++- lib/eal/common/eal_common_trace.c | 2 +- lib/eal/common/eal_memcfg.h | 2 +- lib/eal/common/rte_malloc.c | 2 +- lib/eal/freebsd/eal.c | 2 +- lib/eal/linux/eal.c | 2 +- lib/eal/windows/eal.c | 2 +- 8 files changed, 9 insertions(+), 8 deletions(-) diff --git a/lib/eal/common/eal_common_memory.c b/lib/eal/common/eal_common_memory.c index 60ddc30580..9f4a8676f1 100644 --- a/lib/eal/common/eal_common_memory.c +++ b/lib/eal/common/eal_common_memory.c @@ -562,7 +562,7 @@ check_dma_mask(uint8_t maskbits, bool thread_unsafe) uint64_t mask; int ret; - /* Sanity check. We only check width can be managed with 64 bits + /* We only check width can be managed with 64 bits * variables. Indeed any higher value is likely wrong. */ if (maskbits > MAX_DMA_MASK_BITS) { EAL_LOG(ERR, "wrong dma mask size %u (Max: %u)", diff --git a/lib/eal/common/eal_common_proc.c b/lib/eal/common/eal_common_proc.c index d24093937c..838602edef 100644 --- a/lib/eal/common/eal_common_proc.c +++ b/lib/eal/common/eal_common_proc.c @@ -309,7 +309,8 @@ read_msg(int fd, struct mp_msg_internal *m, struct sockaddr_un *s) break; } } - /* sanity-check the response */ + + /* Check that the response is valid */ if (m->msg.num_fds < 0 || m->msg.num_fds > RTE_MP_MAX_FD_NUM) { EAL_LOG(ERR, "invalid number of fd's received"); return -1; diff --git a/lib/eal/common/eal_common_trace.c b/lib/eal/common/eal_common_trace.c index 918f49bf4f..9349f5780d 100644 --- a/lib/eal/common/eal_common_trace.c +++ b/lib/eal/common/eal_common_trace.c @@ -468,7 +468,7 @@ __rte_trace_point_register(rte_trace_point_t *handle, const char *name, struct trace_point *tp; uint16_t sz; - /* Sanity checks of arguments */ + /* Check arguments */ if (name == NULL || register_fn == NULL || handle == NULL) { trace_err("invalid arguments"); rte_errno = EINVAL; diff --git a/lib/eal/common/eal_memcfg.h b/lib/eal/common/eal_memcfg.h index 60e2089797..e8a85df355 100644 --- a/lib/eal/common/eal_memcfg.h +++ b/lib/eal/common/eal_memcfg.h @@ -18,7 +18,7 @@ * Memory configuration shared across multiple processes. */ struct rte_mem_config { - volatile uint32_t magic; /**< Magic number - sanity check. */ + volatile uint32_t magic; /**< Magic number check. */ uint32_t version; /**< Prevent secondary processes using different DPDK versions. */ diff --git a/lib/eal/common/rte_malloc.c b/lib/eal/common/rte_malloc.c index 6d3c301a23..dac077bc8e 100644 --- a/lib/eal/common/rte_malloc.c +++ b/lib/eal/common/rte_malloc.c @@ -654,7 +654,7 @@ rte_malloc_heap_destroy(const char *heap_name) ret = -1; goto unlock; } - /* sanity checks done, now we can destroy the heap */ + /* checks done, now we can destroy the heap */ rte_spinlock_lock(&heap->lock); ret = malloc_heap_destroy(heap); rte_spinlock_unlock(&heap->lock); diff --git a/lib/eal/freebsd/eal.c b/lib/eal/freebsd/eal.c index bab77118e9..1500778b4f 100644 --- a/lib/eal/freebsd/eal.c +++ b/lib/eal/freebsd/eal.c @@ -501,7 +501,7 @@ eal_parse_args(int argc, char **argv) goto out; } - /* sanity checks */ + /* options checks */ if (eal_check_common_options(internal_conf) != 0) { eal_usage(prgname); ret = -1; diff --git a/lib/eal/linux/eal.c b/lib/eal/linux/eal.c index fd422f1f62..50cebdbbd4 100644 --- a/lib/eal/linux/eal.c +++ b/lib/eal/linux/eal.c @@ -803,7 +803,7 @@ eal_parse_args(int argc, char **argv) goto out; } - /* sanity checks */ + /* options checks */ if (eal_check_common_options(internal_conf) != 0) { eal_usage(prgname); ret = -1; diff --git a/lib/eal/windows/eal.c b/lib/eal/windows/eal.c index 52f0e7462d..915c8e569a 100644 --- a/lib/eal/windows/eal.c +++ b/lib/eal/windows/eal.c @@ -194,7 +194,7 @@ eal_parse_args(int argc, char **argv) if (eal_adjust_config(internal_conf) != 0) return -1; - /* sanity checks */ + /* options checks */ if (eal_check_common_options(internal_conf) != 0) { eal_usage(prgname); return -1; From patchwork Wed May 29 23:33:37 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140411 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 12E0A44107; Thu, 30 May 2024 01:39:13 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 2D17F40649; Thu, 30 May 2024 01:39:00 +0200 (CEST) Received: from mail-pj1-f44.google.com (mail-pj1-f44.google.com [209.85.216.44]) by mails.dpdk.org (Postfix) with ESMTP id 612C540289 for ; Thu, 30 May 2024 01:38:18 +0200 (CEST) Received: by mail-pj1-f44.google.com with SMTP id 98e67ed59e1d1-2bf59b781d6so234492a91.0 for ; Wed, 29 May 2024 16:38:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025897; x=1717630697; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=vpto4kiY3RodVDe9Ety5SXIETYr3APj+FM1RX5sJa2k=; b=3gQz40oJWgHYblTJPL8CS7XVjlp++FuKlUgJ0dOTrEXQzyrzewXSdAHgIDvBfQYGSg uWm5Tkx98RB0bV0BWKl9xSo2nfI27FE8jwXw8o9xH6nctRrNicrh6NJQqtRodlI5DlLt 8lY0eogkfR8gUHLLQjYxM4nBPAmRaQGxI6epJj2EpP+smFdgdLO6clwp1WpBGSHkMb50 75Ui0bSHRfb6V0o4TREBVuHJFxtpvJezHgFI2FmE+5p5wSJIpnjd+57+0TlPy2G3MZzf vIc5vjpQm5axFY86q66MUQi4JwwAA2q06cH5fALBk0IUWS64qlJn7v4tCK3eG3ViZ4bz X7Xw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025897; x=1717630697; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=vpto4kiY3RodVDe9Ety5SXIETYr3APj+FM1RX5sJa2k=; b=rQx6nvoZBDJSK4eA51VbuGJFqi8UGh0AqlZDQy9L1vX7wMaGcROt5Ywhrmxr1qIeZP /GiZlDC12VgTTScpFTXGGA40/OyYvR3Rwd0ouDaruN9K0FUYFATyVNrNTzeSmJKA6d3X rdeJo19kINlib0oZfuvF5zHNQVa9KC0Ojm0crxIFIRBKVd0I1Scs4RMfy8wbLXAiqvym pxJjs06fcIrcPbB3uj8kYXkfDCU/EDSPUJrHREyPm5v4BGsH0zWjMqHll+QvAkUKJddr hqvzHagy0iQ5XTki7q1oTBFSLa7RLM1/1ST5I+2J7LVauaoX7+9bmxQDXP+RPnugSQGg VZwQ== X-Gm-Message-State: AOJu0YxcsPn436wVkZFnbBKBrLV4v20B8WnMoxoL3dRo0+W4SFuT6RUg nVNUZmofNu4h5t61r0s5YcQmfr5eDzEYU2ZQG+QtexgcHdxVOTtN6IQTEdQL6pKVGQ3JCi0ZjFU r X-Google-Smtp-Source: AGHT+IFKq/ZJs+fOXYN0pYw/hmM3lqGRxdiXrbEgDzifns1K0bSLb+PGaH54Cm3vC1LctQ7isMrFKA== X-Received: by 2002:a17:90a:da04:b0:2bd:d42a:e071 with SMTP id 98e67ed59e1d1-2c1abc3d324mr586965a91.30.1717025897349; Wed, 29 May 2024 16:38:17 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.16 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:17 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 03/20] test: replace use word sanity Date: Wed, 29 May 2024 16:33:37 -0700 Message-ID: <20240529233811.663211-4-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The word "sanity" is on the not-allowed inclusive naming list. Replace the unnecessary usage in tests. Signed-off-by: Stephen Hemminger --- app/test/test_bitmap.c | 4 +-- app/test/test_bpf.c | 6 ++-- app/test/test_common.c | 2 +- app/test/test_distributor.c | 46 +++++++++++++++--------------- app/test/test_eal_flags.c | 20 ++++++------- app/test/test_hash.c | 2 +- app/test/test_interrupts.c | 9 +++--- app/test/test_link_bonding_mode4.c | 2 +- app/test/test_mbuf.c | 2 +- app/test/test_rawdev.c | 2 +- app/test/test_timer.c | 10 +++---- 11 files changed, 53 insertions(+), 52 deletions(-) diff --git a/app/test/test_bitmap.c b/app/test/test_bitmap.c index bab11812c7..a074b64f2e 100644 --- a/app/test/test_bitmap.c +++ b/app/test/test_bitmap.c @@ -33,7 +33,7 @@ test_bitmap_scan_operations(struct rte_bitmap *bmp) } if (slab1_magic != out_slab) { - printf("Scan operation sanity failed.\n"); + printf("Scan operation magic number check failed.\n"); return TEST_FAILED; } @@ -43,7 +43,7 @@ test_bitmap_scan_operations(struct rte_bitmap *bmp) } if (slab2_magic != out_slab) { - printf("Scan operation sanity failed.\n"); + printf("Scan operation magic number check failed.\n"); return TEST_FAILED; } diff --git a/app/test/test_bpf.c b/app/test/test_bpf.c index 64c3c90b0a..7fe4ec1ca2 100644 --- a/app/test/test_bpf.c +++ b/app/test/test_bpf.c @@ -3343,9 +3343,9 @@ test_bpf_match(pcap_t *pcap, const char *str, return ret; } -/* Basic sanity test can we match a IP packet */ +/* Basic test can we match a IP packet */ static int -test_bpf_filter_sanity(pcap_t *pcap) +test_bpf_filter_match(pcap_t *pcap) { const uint32_t plen = 100; struct rte_mbuf mb, *m; @@ -3478,7 +3478,7 @@ test_bpf_convert(void) return -1; } - rc = test_bpf_filter_sanity(pcap); + rc = test_bpf_filter_match(pcap); for (i = 0; i < RTE_DIM(sample_filters); i++) rc |= test_bpf_filter(pcap, sample_filters[i]); diff --git a/app/test/test_common.c b/app/test/test_common.c index 21eb2285e1..784cdaf3d6 100644 --- a/app/test/test_common.c +++ b/app/test/test_common.c @@ -19,7 +19,7 @@ {printf(x "() test failed!\n");\ return -1;} -/* this is really a sanity check */ +/* this is really a consistency check */ static int test_macros(int __rte_unused unused_parm) { diff --git a/app/test/test_distributor.c b/app/test/test_distributor.c index 60fe96ea82..b32aa78989 100644 --- a/app/test/test_distributor.c +++ b/app/test/test_distributor.c @@ -81,7 +81,7 @@ clear_packet_count(void) rte_memory_order_relaxed); } -/* this is the basic worker function for sanity test +/* this is the basic worker function * it does nothing but return packets and count them. */ static int @@ -106,7 +106,7 @@ handle_work(void *arg) return 0; } -/* do basic sanity testing of the distributor. This test tests the following: +/* do basic testing of the distributor. This test tests the following: * - send 32 packets through distributor with the same tag and ensure they * all go to the one worker * - send 32 packets through the distributor with two different tags and @@ -118,7 +118,7 @@ handle_work(void *arg) * not necessarily in the same order (as different flows). */ static int -sanity_test(struct worker_params *wp, struct rte_mempool *p) +basic_test(struct worker_params *wp, struct rte_mempool *p) { struct rte_distributor *db = wp->dist; struct rte_mbuf *bufs[BURST]; @@ -127,7 +127,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p) unsigned int retries; unsigned int processed; - printf("=== Basic distributor sanity tests ===\n"); + printf("=== Basic distributor tests ===\n"); clear_packet_count(); if (rte_mempool_get_bulk(p, (void *)bufs, BURST) != 0) { printf("line %d: Error getting mbufs from pool\n", __LINE__); @@ -164,7 +164,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p) printf("Worker %u handled %u packets\n", i, rte_atomic_load_explicit(&worker_stats[i].handled_packets, rte_memory_order_relaxed)); - printf("Sanity test with all zero hashes done.\n"); + printf("Test with all zero hashes done.\n"); /* pick two flows and check they go correctly */ if (rte_lcore_count() >= 3) { @@ -192,7 +192,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p) rte_atomic_load_explicit( &worker_stats[i].handled_packets, rte_memory_order_relaxed)); - printf("Sanity test with two hash values done\n"); + printf("Test with two hash values done\n"); } /* give a different hash value to each packet, @@ -220,11 +220,11 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p) printf("Worker %u handled %u packets\n", i, rte_atomic_load_explicit(&worker_stats[i].handled_packets, rte_memory_order_relaxed)); - printf("Sanity test with non-zero hashes done\n"); + printf("Test with non-zero hashes done\n"); rte_mempool_put_bulk(p, (void *)bufs, BURST); - /* sanity test with BIG_BATCH packets to ensure they all arrived back + /* test with BIG_BATCH packets to ensure they all arrived back * from the returned packets function */ clear_packet_count(); struct rte_mbuf *many_bufs[BIG_BATCH], *return_bufs[BIG_BATCH]; @@ -289,7 +289,7 @@ sanity_test(struct worker_params *wp, struct rte_mempool *p) return -1; } } - printf("Sanity test of returned packets done\n"); + printf("Test of returned packets done\n"); rte_mempool_put_bulk(p, (void *)many_bufs, BIG_BATCH); @@ -327,20 +327,20 @@ handle_work_with_free_mbufs(void *arg) return 0; } -/* Perform a sanity test of the distributor with a large number of packets, +/* Perform a test of the distributor with a large number of packets, * where we allocate a new set of mbufs for each burst. The workers then * free the mbufs. This ensures that we don't have any packet leaks in the * library. */ static int -sanity_test_with_mbuf_alloc(struct worker_params *wp, struct rte_mempool *p) +basic_test_with_mbuf_alloc(struct worker_params *wp, struct rte_mempool *p) { struct rte_distributor *d = wp->dist; unsigned i; struct rte_mbuf *bufs[BURST]; unsigned int processed; - printf("=== Sanity test with mbuf alloc/free (%s) ===\n", wp->name); + printf("=== Test with mbuf alloc/free (%s) ===\n", wp->name); clear_packet_count(); for (i = 0; i < ((1<dist; @@ -450,7 +450,7 @@ sanity_test_with_worker_shutdown(struct worker_params *wp, unsigned int failed = 0; unsigned int processed = 0; - printf("=== Sanity test of worker shutdown ===\n"); + printf("=== Test of worker shutdown ===\n"); clear_packet_count(); @@ -516,7 +516,7 @@ sanity_test_with_worker_shutdown(struct worker_params *wp, if (failed) return -1; - printf("Sanity test with worker shutdown passed\n\n"); + printf("Test with worker shutdown passed\n\n"); return 0; } @@ -612,13 +612,13 @@ handle_and_mark_work(void *arg) return 0; } -/* sanity_mark_test sends packets to workers which mark them. +/* mark_test sends packets to workers which mark them. * Every packet has also encoded sequence number. * The returned packets are sorted and verified if they were handled * by proper workers. */ static int -sanity_mark_test(struct worker_params *wp, struct rte_mempool *p) +mark_test(struct worker_params *wp, struct rte_mempool *p) { const unsigned int buf_count = 24; const unsigned int burst = 8; @@ -899,13 +899,13 @@ test_distributor(void) rte_eal_mp_remote_launch(handle_work, &worker_params, SKIP_MAIN); - if (sanity_test(&worker_params, p) < 0) + if (basic_test(&worker_params, p) < 0) goto err; quit_workers(&worker_params, p); rte_eal_mp_remote_launch(handle_work_with_free_mbufs, &worker_params, SKIP_MAIN); - if (sanity_test_with_mbuf_alloc(&worker_params, p) < 0) + if (basic_test_with_mbuf_alloc(&worker_params, p) < 0) goto err; quit_workers(&worker_params, p); @@ -913,7 +913,7 @@ test_distributor(void) rte_eal_mp_remote_launch(handle_work_for_shutdown_test, &worker_params, SKIP_MAIN); - if (sanity_test_with_worker_shutdown(&worker_params, + if (basic_test_with_worker_shutdown(&worker_params, p) < 0) goto err; quit_workers(&worker_params, p); @@ -928,7 +928,7 @@ test_distributor(void) rte_eal_mp_remote_launch(handle_and_mark_work, &worker_params, SKIP_MAIN); - if (sanity_mark_test(&worker_params, p) < 0) + if (mark_test(&worker_params, p) < 0) goto err; quit_workers(&worker_params, p); diff --git a/app/test/test_eal_flags.c b/app/test/test_eal_flags.c index 6cb4b06757..9c082ff914 100644 --- a/app/test/test_eal_flags.c +++ b/app/test/test_eal_flags.c @@ -314,7 +314,7 @@ get_number_of_sockets(void) /* * Test that the app doesn't run with invalid allow option. - * Final tests ensures it does run with valid options as sanity check (one + * Final tests ensures it does run with valid options as basic test (one * test for with Domain+BDF, second for just with BDF) */ static int @@ -382,7 +382,7 @@ test_allow_flag(void) /* * Test that the app doesn't run with invalid blocklist option. - * Final test ensures it does run with valid options as sanity check + * Final test ensures it does run with valid options as basic check. */ static int test_invalid_b_flag(void) @@ -429,7 +429,7 @@ test_invalid_b_flag(void) /* * Test that the app doesn't run with invalid vdev option. - * Final test ensures it does run with valid options as sanity check + * Final test ensures it does run with valid options basic check. */ static int test_invalid_vdev_flag(void) @@ -554,7 +554,7 @@ test_missing_c_flag(void) /* bad coremask value */ const char *argv3[] = { prgname, prefix, mp_flag, "-c", "error" }; - /* sanity check of tests - valid coremask value */ + /* check of tests - valid coremask value */ const char *argv4[] = { prgname, prefix, mp_flag, "-c", "1" }; /* -l flag but no corelist value */ @@ -581,7 +581,7 @@ test_missing_c_flag(void) "-l", RTE_STR(RTE_MAX_LCORE) }; const char * const argv14[] = { prgname, prefix, mp_flag, "-l", "1-"RTE_STR(RTE_MAX_LCORE) }; - /* sanity check test - valid corelist value */ + /* check test - valid corelist value */ const char * const argv15[] = { prgname, prefix, mp_flag, "-l", "1-2,3" }; @@ -613,7 +613,7 @@ test_missing_c_flag(void) "--lcores", "(4-7)=(1,3)" }; const char * const argv28[] = { prgname, prefix, mp_flag, "--lcores", "[4-7]@(1,3)" }; - /* sanity check of tests - valid lcores value */ + /* more complex valid lcores value */ const char * const argv29[] = { prgname, prefix, mp_flag, "--lcores", "0-1,2@(5-7),(3-5)@(0,2),(0,6),7"}; @@ -744,7 +744,7 @@ test_main_lcore_flag(void) /* * Test that the app doesn't run with invalid -n flag option. - * Final test ensures it does run with valid options as sanity check + * Final test ensures it does run with valid options as basic check. * Since -n is not compulsory for MP, we instead use --no-huge and --no-shconf * flags. */ @@ -772,10 +772,10 @@ test_invalid_n_flag(void) /* zero is invalid */ const char *argv3[] = { prgname, prefix, no_huge, no_shconf, "-n", "0" }; - /* sanity test - check with good value */ + /* check with good value */ const char *argv4[] = { prgname, prefix, no_huge, no_shconf, "-n", "2" }; - /* sanity test - check with no -n flag */ + /* check with no -n flag */ const char *argv5[] = { prgname, prefix, no_huge, no_shconf}; if (launch_proc(argv1) == 0 @@ -977,7 +977,7 @@ test_misc_flags(void) * All cases, apart from the first, app should run. * No further testing of output done. */ - /* sanity check - failure with invalid option */ + /* failure with invalid option */ const char *argv0[] = {prgname, prefix, mp_flag, "--invalid-opt"}; /* With --no-pci */ diff --git a/app/test/test_hash.c b/app/test/test_hash.c index d586878a22..54e751b5ee 100644 --- a/app/test/test_hash.c +++ b/app/test/test_hash.c @@ -1088,7 +1088,7 @@ fbk_hash_unit_test(void) .socket_id = 0, }; - /* this is a sanity check for "same name" test + /* this is a check for "same name" test * creating this hash will check if we are actually able to create * multiple hashes with different names (instead of having just one). */ diff --git a/app/test/test_interrupts.c b/app/test/test_interrupts.c index 3952f9685f..42b830e936 100644 --- a/app/test/test_interrupts.c +++ b/app/test/test_interrupts.c @@ -48,7 +48,7 @@ static union intr_pipefds pfds; * Check if the interrupt handle is valid. */ static inline int -test_interrupt_handle_sanity_check(struct rte_intr_handle *intr_handle) +test_interrupt_handle_check(struct rte_intr_handle *intr_handle) { if (!intr_handle || rte_intr_fd_get(intr_handle) < 0) return -1; @@ -164,7 +164,7 @@ test_interrupt_handle_compare(struct rte_intr_handle *intr_handle_l, #else /* to be implemented for bsd later */ static inline int -test_interrupt_handle_sanity_check(struct rte_intr_handle *intr_handle) +test_interrupt_handle_check(struct rte_intr_handle *intr_handle) { RTE_SET_USED(intr_handle); @@ -215,7 +215,7 @@ test_interrupt_callback(void *arg) return; } - if (test_interrupt_handle_sanity_check(intr_handle) < 0) { + if (test_interrupt_handle_check(intr_handle) < 0) { printf("null or invalid intr_handle for %s\n", __func__); flag = -1; return; @@ -241,7 +241,8 @@ static void test_interrupt_callback_1(void *arg) { struct rte_intr_handle *intr_handle = arg; - if (test_interrupt_handle_sanity_check(intr_handle) < 0) { + + if (test_interrupt_handle_check(intr_handle) < 0) { printf("null or invalid intr_handle for %s\n", __func__); flag = -1; return; diff --git a/app/test/test_link_bonding_mode4.c b/app/test/test_link_bonding_mode4.c index ff13dbed93..299b89f669 100644 --- a/app/test/test_link_bonding_mode4.c +++ b/app/test/test_link_bonding_mode4.c @@ -224,7 +224,7 @@ add_member(struct member_conf *member, uint8_t start) struct rte_ether_addr addr, addr_check; int retval; - /* Some sanity check */ + /* Some basic tests. */ RTE_VERIFY(test_params.member_ports <= member && member - test_params.member_ports < (int)RTE_DIM(test_params.member_ports)); RTE_VERIFY(member->bonding == 0); diff --git a/app/test/test_mbuf.c b/app/test/test_mbuf.c index 3fbb5dea8b..1cc50b158f 100644 --- a/app/test/test_mbuf.c +++ b/app/test/test_mbuf.c @@ -1702,7 +1702,7 @@ test_mbuf_validate_tx_offload(const char *test_name, struct rte_mbuf *m = NULL; int ret = 0; - /* alloc a mbuf and do sanity check */ + /* alloc a mbuf and do some basic checks */ m = rte_pktmbuf_alloc(pktmbuf_pool); if (m == NULL) GOTO_FAIL("%s: mbuf allocation failed!\n", __func__); diff --git a/app/test/test_rawdev.c b/app/test/test_rawdev.c index d34691dacf..0d4f0ce1fa 100644 --- a/app/test/test_rawdev.c +++ b/app/test/test_rawdev.c @@ -47,7 +47,7 @@ test_rawdev_selftests(void) int ret = 0; int i; - /* basic sanity on rawdev infrastructure */ + /* basic check on rawdev infrastructure */ if (test_rawdev_selftest_skeleton() < 0) return -1; diff --git a/app/test/test_timer.c b/app/test/test_timer.c index 3411b7fe20..70a4d981fe 100644 --- a/app/test/test_timer.c +++ b/app/test/test_timer.c @@ -498,11 +498,11 @@ timer_basic_main_loop(__rte_unused void *arg) } static int -timer_sanity_check(void) +timer_check(void) { #ifdef RTE_LIBEAL_USE_HPET if (eal_timer_source != EAL_TIMER_HPET) { - printf("Not using HPET, can't sanity check timer sources\n"); + printf("Not using HPET, can't check timer sources\n"); return 0; } @@ -546,9 +546,9 @@ test_timer(void) return TEST_SKIPPED; } - /* sanity check our timer sources and timer config values */ - if (timer_sanity_check() < 0) { - printf("Timer sanity checks failed\n"); + /* check our timer sources and timer config values */ + if (timer_check() < 0) { + printf("Timer checks failed\n"); return TEST_FAILED; } From patchwork Wed May 29 23:33:38 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140412 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A2FA844107; Thu, 30 May 2024 01:39:19 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6FEEC40A72; Thu, 30 May 2024 01:39:01 +0200 (CEST) Received: from mail-pg1-f173.google.com (mail-pg1-f173.google.com [209.85.215.173]) by mails.dpdk.org (Postfix) with ESMTP id E3B6640289 for ; Thu, 30 May 2024 01:38:18 +0200 (CEST) Received: by mail-pg1-f173.google.com with SMTP id 41be03b00d2f7-681a48efe77so252188a12.2 for ; Wed, 29 May 2024 16:38:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025898; x=1717630698; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=lYC5/UsM05kKw71DacNJAZrA+LiK9sY1PpnLcB7k7EA=; b=S+DlVQ2PtjEt8g9EeTm3FOZwJ66CvnR8ArW5qu+aUOp9R2DidgStHiDvrikyABC3TB HAivpW/XhL5MFeeewXzEA3Eb398Iph4ABwlBe/44QqFoa6P7SJk51VwWyRWrLdVabOrO eucb0feokdcCletiGE7IxK0JIyEIHVhC3BMsjFxEuw6nxCGcKlP28d3+Pva3I//qP6IR ohf78lt9xUA2+WqaAKLdvy2nPnmeljqUudNv0dtunqI45vKNBKPwB5sL6Wq7W02iPxZS Hh8deG06b/4pDVB/b5OANfRxXOpQ0Qgu2yxEd82lzq5cs/fXz0au+EV8pqSvD8R0Vg8v h+Mw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025898; x=1717630698; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=lYC5/UsM05kKw71DacNJAZrA+LiK9sY1PpnLcB7k7EA=; b=Ttz4s9JLhMJ8IzG/FCay7R4A5c7URcEcxPNKZKIku41DkoEkO7KR5W7w5/6MOFgk4h in01XWLZlwKL3ghMPnGMq3vqIdHyOaGzCzMeh6nt/un8IIZQhvsjYhflHkX+X1s90G6H EniqQ+nPrUUzpcW0JdqaB9W1YEZinJVFj2e79vGQuDJMEvheAq8Ps81hId9vZrqpQpF8 SN5+OVM3GV/BLNGz5NFGaLbHPKuYJjdgZO2rL28v0pLIRu9IrN0LzvNlcFn/UVHWODwu bYZ4skPLETyILR8BWqnjOWlKDf2qD66w6aBjVbXFz41WIeThHO3R888PoVpB70UDEmLv uDOA== X-Gm-Message-State: AOJu0YyVeAVY2OEWHbgw3RO0cq3uZM0Q5XLFiHs/HxjtWTfVijRveQam 7OH1gzwR7bBiwaNqBpkBKpmCJVtStiFskB5gdY42pwW6gbUDbcJpki+JN25DZfi1Dgx9fYVIR7w N X-Google-Smtp-Source: AGHT+IEvNKHTrmnojrNAG6dkvnIwn06T10F93kQf5lH/IiomVTO7FZTaEqh9rKty+AS9LdC1YB8ROA== X-Received: by 2002:a17:90a:3d0b:b0:2bd:e0dd:f232 with SMTP id 98e67ed59e1d1-2c1ab9dcc2amr613665a91.8.1717025898044; Wed, 29 May 2024 16:38:18 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.17 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:17 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 04/20] examples: remove term sanity Date: Wed, 29 May 2024 16:33:38 -0700 Message-ID: <20240529233811.663211-5-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Do not use non-inclusive terms. Signed-off-by: Stephen Hemminger --- examples/ipsec-secgw/event_helper.c | 2 +- examples/qos_sched/args.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/ipsec-secgw/event_helper.c b/examples/ipsec-secgw/event_helper.c index 89fb7e62a5..f595b4fe01 100644 --- a/examples/ipsec-secgw/event_helper.c +++ b/examples/ipsec-secgw/event_helper.c @@ -2100,7 +2100,7 @@ eh_launch_worker(struct eh_conf *conf, struct eh_app_worker_params *app_wrkr, goto clean_and_exit; } - /* Verify sanity of the matched worker */ + /* Verify validity of the matched worker */ if (eh_verify_match_worker(match_wrkr) != 1) { EH_LOG_ERR("Failed to validate the matched worker"); goto clean_and_exit; diff --git a/examples/qos_sched/args.c b/examples/qos_sched/args.c index 8d61d3e454..dde53d0167 100644 --- a/examples/qos_sched/args.c +++ b/examples/qos_sched/args.c @@ -386,7 +386,7 @@ app_parse_args(int argc, char **argv) return -1; } - /* sanity check for cores assignment */ + /* check for cores assignment */ for(i = 0; i < nb_pfc; i++) { if (qos_conf[i].rx_core >= RTE_MAX_LCORE) { RTE_LOG(ERR, APP, "pfc %u: invalid RX lcore index %u\n", i + 1, From patchwork Wed May 29 23:33:39 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140413 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 4DB3544107; Thu, 30 May 2024 01:39:26 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3C38140A81; Thu, 30 May 2024 01:39:03 +0200 (CEST) Received: from mail-pj1-f42.google.com (mail-pj1-f42.google.com [209.85.216.42]) by mails.dpdk.org (Postfix) with ESMTP id BAE8E40289 for ; Thu, 30 May 2024 01:38:19 +0200 (CEST) Received: by mail-pj1-f42.google.com with SMTP id 98e67ed59e1d1-2bdd8968dabso211137a91.3 for ; Wed, 29 May 2024 16:38:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025899; x=1717630699; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=tIfb8+eBP19eJHu+3Ju2F1eoR7OufKzHVgtYR+Mx0KA=; b=oNxfgj0z7fRxXvVhWx7LUjyL/ZFcCIKIATZ2Qo7mybaeP7tJgIdaul2CSuYo2br/Ng S26p1pWe+DsSIJoLk/uCYZOvbQv79JHltGhOgt2nUp9J/1E4+sLo+TsHNhGPNd/n3StU v/exRab5UCyWrVPsns9MPjxH5PG70U11c7qENJ8PcBuYBRaBArqqOVIR/BtHIXsiObGV BxfkoghbeKNYwQD5VKNJDppAmhHeVuxrew5mMISZDI46eGpS0+hjEf7flsarDT0U02YC W3xVvkzfQfmnVMdwXRWFj0/95fSGCLH7EIkNWy6+uJgEedDmWSFlCMGkcawtvzIOJ8ID i/0A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025899; x=1717630699; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=tIfb8+eBP19eJHu+3Ju2F1eoR7OufKzHVgtYR+Mx0KA=; b=aYlTdtYXrpBM22Ft4wnCU3ZMbBEL1fbrG6csEXnwDg+P8jX8d3ceXi01lvdP6GXcEe MRm9Yi/dVEwI35OulCInfsExO1JuITC7uhDwl58CeHlswab+6baJ42p7BYbGlePJSv3I xiYb0EiQ01lcl/7vZtgnNbzxfSQ/D7cJ8IVzTWe1ZxZNSrEYGbwe55uAQAyJWs5skBKx mavleYav0CfqObI/UZNSFwKI9hUqbgP9Zgc4WlBTRU00BOIKC+LrNTLfOi1uCZ1MKFgw 46PqftPhxSyrd/LHMj+UhEHAokzaQH6BeFmu6el8poJE4YW2fOt6/Ezdf4scKx0bAL5O HyPw== X-Gm-Message-State: AOJu0Yy/hXQ+1nQfG16QQtOunIU0j//dIlRngLtlC/Hg/9FCHgInMsh9 gVnJOnqEhleDWNLB6DCxpGoY0Bs6rRtIrS+simGOj17JULMogNipgJqOCqdCtIpwGEMcFjmq86s 5 X-Google-Smtp-Source: AGHT+IGDzRNinLmktkXzaXtQWV8/UktnqtfdxKBHK47KwcUEdV9hkxZ2ehZnF3+x/AlAxe62yPCTCA== X-Received: by 2002:a17:90a:ac09:b0:2c1:a55e:b95d with SMTP id 98e67ed59e1d1-2c1aace3d70mr808581a91.0.1717025898788; Wed, 29 May 2024 16:38:18 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:18 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 05/20] lib: replace use of sanity check in comments and messages Date: Wed, 29 May 2024 16:33:39 -0700 Message-ID: <20240529233811.663211-6-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sanity check is on the Tier 2 non-inclusive list. Replace or remove it. Signed-off-by: Stephen Hemminger --- lib/graph/graph.c | 2 +- lib/graph/graph_stats.c | 2 +- lib/graph/node.c | 2 +- lib/jobstats/rte_jobstats.c | 6 +++--- lib/metrics/rte_metrics.c | 2 +- lib/pcapng/rte_pcapng.c | 2 +- 6 files changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/graph/graph.c b/lib/graph/graph.c index 26f0968a97..e51dcc3056 100644 --- a/lib/graph/graph.c +++ b/lib/graph/graph.c @@ -344,7 +344,7 @@ rte_graph_create(const char *name, struct rte_graph_param *prm) graph_spinlock_lock(); - /* Check arguments sanity */ + /* Check argument validity */ if (prm == NULL) SET_ERR_JMP(EINVAL, fail, "Param should not be NULL"); diff --git a/lib/graph/graph_stats.c b/lib/graph/graph_stats.c index 2fb808b21e..d0a636dde8 100644 --- a/lib/graph/graph_stats.c +++ b/lib/graph/graph_stats.c @@ -317,7 +317,7 @@ rte_graph_cluster_stats_create(const struct rte_graph_cluster_stats_param *prm) const char *pattern; rte_graph_t i; - /* Sanity checks */ + /* Validate arguments */ if (!rte_graph_has_stats_feature()) SET_ERR_JMP(EINVAL, fail, "Stats feature is not enabled"); diff --git a/lib/graph/node.c b/lib/graph/node.c index 99a9622779..c238d140ed 100644 --- a/lib/graph/node.c +++ b/lib/graph/node.c @@ -68,7 +68,7 @@ __rte_node_register(const struct rte_node_register *reg) graph_spinlock_lock(); - /* Check sanity */ + /* Check argument validity */ if (reg == NULL || reg->process == NULL) { rte_errno = EINVAL; goto fail; diff --git a/lib/jobstats/rte_jobstats.c b/lib/jobstats/rte_jobstats.c index af565a14ea..1c4b280c95 100644 --- a/lib/jobstats/rte_jobstats.c +++ b/lib/jobstats/rte_jobstats.c @@ -124,7 +124,7 @@ rte_jobstats_start(struct rte_jobstats_context *ctx, struct rte_jobstats *job) { uint64_t now; - /* Some sanity check. */ + /* Check validity of arguments. */ if (unlikely(ctx == NULL || job == NULL || job->context != NULL)) return -EINVAL; @@ -144,7 +144,7 @@ rte_jobstats_abort(struct rte_jobstats *job) struct rte_jobstats_context *ctx; uint64_t now, exec_time; - /* Some sanity check. */ + /* Check that arguments are valid */ if (unlikely(job == NULL || job->context == NULL)) return -EINVAL; @@ -165,7 +165,7 @@ rte_jobstats_finish(struct rte_jobstats *job, int64_t job_value) uint64_t now, exec_time; int need_update; - /* Some sanity check. */ + /* Check arguments */ if (unlikely(job == NULL || job->context == NULL)) return -EINVAL; diff --git a/lib/metrics/rte_metrics.c b/lib/metrics/rte_metrics.c index 0ccdbabc04..f60d4f3f6e 100644 --- a/lib/metrics/rte_metrics.c +++ b/lib/metrics/rte_metrics.c @@ -120,7 +120,7 @@ rte_metrics_reg_names(const char * const *names, uint16_t cnt_names) uint16_t idx_name; uint16_t idx_base; - /* Some sanity checks */ + /* Some consistency checks */ if (cnt_names < 1 || names == NULL) return -EINVAL; for (idx_name = 0; idx_name < cnt_names; idx_name++) diff --git a/lib/pcapng/rte_pcapng.c b/lib/pcapng/rte_pcapng.c index 7254defce7..ee065acda6 100644 --- a/lib/pcapng/rte_pcapng.c +++ b/lib/pcapng/rte_pcapng.c @@ -620,7 +620,7 @@ rte_pcapng_write_packets(rte_pcapng_t *self, struct pcapng_enhance_packet_block *epb; uint64_t cycles, timestamp; - /* sanity check that is really a pcapng mbuf */ + /* Check that is really a pcapng mbuf */ epb = rte_pktmbuf_mtod(m, struct pcapng_enhance_packet_block *); if (unlikely(epb->block_type != PCAPNG_ENHANCED_PACKET_BLOCK || epb->block_length != rte_pktmbuf_data_len(m))) { From patchwork Wed May 29 23:33:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140414 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 38EEF44107; Thu, 30 May 2024 01:39:33 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0934640A8B; Thu, 30 May 2024 01:39:05 +0200 (CEST) Received: from mail-pg1-f173.google.com (mail-pg1-f173.google.com [209.85.215.173]) by mails.dpdk.org (Postfix) with ESMTP id 5F45240289 for ; Thu, 30 May 2024 01:38:20 +0200 (CEST) Received: by mail-pg1-f173.google.com with SMTP id 41be03b00d2f7-6818eea9c3aso215281a12.1 for ; Wed, 29 May 2024 16:38:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025899; x=1717630699; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=LHhPOQamLLrlUqLjwGAvaPTGqtFiPYIYGUMD8tBWyto=; b=GThlDzaS6y5g58JQX73JY4imf97I8xq990HhNQgFhhjE9OrLJVp4W8Azg0p0brnM4r S7LhByVT0UfbVTOEgt6gu1IS1+f7S1kdJVdLsSzE+icvzvz+JXBNca/fG/VBhkLO0Cpn HE3+p4NRbI2Lnow/gbaPz/zhq7lvSStNOvb6ZyHy25NjlkJINxV30Z1KIIvP+dHEHT/O vJV8ejGnvZk9Te9XGPnEbdBHsnd6Lr28VjO+NVlhrlWXLGfMnlf5xq2JcMum5NBZ9kc2 ojYx8LNvkeq48KPLYzFb2YbA8i6tBDldn6Su42h2wc0UB6fIlM59+iwDL0vCPO67JLYF BExA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025899; x=1717630699; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=LHhPOQamLLrlUqLjwGAvaPTGqtFiPYIYGUMD8tBWyto=; b=VqnPlGDVugdfrgpZKVKLdrG+FAdCOXOwx7P42Q2gRhsLl0+byjEx9e5wa7explOmnH utSzXCJ90EyX0vo73DKQCBJk/TsuMzDB0d7i+o/X41MAOV6HHShLNut2OvhWNZofNCjS GPTd97baQK66yko7cg66hBM9VGW7lbTos3ikHdUb82Z8TkPB0IwrO1M8/v9NUKZTE+MI BbbtfiKEIOALPRMEaUFQYt7Gg+cNoUNlhEXgd/bCQ0NKsLfMpf2eC+Vq3qY/ic6XuDnp 9YE6hFHXQsGaMyDf9+3zndVkDXAiBtK4N63ANrbMbLnt/pVM2zt8eK0yvy4l1WeEYsmi dSpg== X-Gm-Message-State: AOJu0YzYYThgPCLZsk8vBIPXvtl8QPUgJgd8TPAzNbVH8E8u6M+Vqym2 ycek2cX8GwTUUQnR8emudYPWL/UtDeYrKGiemnk4RhhPhB3guPdfNyjLqbtm0+w1R1EgrAQ1SoN U X-Google-Smtp-Source: AGHT+IEPhfMf7jLozFQQg5yzpUEUGKexYRj7nwPGWuYft8pKbtmdUnOtaNTKjOWFRjiBXsSU1KOW+w== X-Received: by 2002:a17:90a:b005:b0:2bd:8803:4858 with SMTP id 98e67ed59e1d1-2c1abc013a1mr573133a91.29.1717025899584; Wed, 29 May 2024 16:38:19 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:19 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 06/20] doc/eventdev_pipeline: remove sanity Date: Wed, 29 May 2024 16:33:40 -0700 Message-ID: <20240529233811.663211-7-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The word sanity check is unnecessary here. Signed-off-by: Stephen Hemminger --- doc/guides/gpus/cuda.rst | 2 +- doc/guides/sample_app_ug/eventdev_pipeline.rst | 2 +- doc/guides/tools/testbbdev.rst | 8 ++++---- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/doc/guides/gpus/cuda.rst b/doc/guides/gpus/cuda.rst index 6520c17c3e..c523da1f3e 100644 --- a/doc/guides/gpus/cuda.rst +++ b/doc/guides/gpus/cuda.rst @@ -80,7 +80,7 @@ Similarly to CUDA shared library, if the **libgdrapi.so** shared library is not installed in default locations (e.g. /usr/local/lib), you can use the variable ``GDRCOPY_PATH_L``. -As an example, to enable the CPU map feature sanity check, +As an example, to enable the CPU map feature check, run the ``app/test-gpudev`` application with: .. code-block:: console diff --git a/doc/guides/sample_app_ug/eventdev_pipeline.rst b/doc/guides/sample_app_ug/eventdev_pipeline.rst index 19ff53803e..e7787fb266 100644 --- a/doc/guides/sample_app_ug/eventdev_pipeline.rst +++ b/doc/guides/sample_app_ug/eventdev_pipeline.rst @@ -50,7 +50,7 @@ these settings is shown below: .//examples/dpdk-eventdev_pipeline -l 0,2,8-15 --vdev event_sw0 \ -- -r1 -t1 -e4 -w FF00 -s4 -n0 -c32 -W1000 -D -The application has some sanity checking built-in, so if there is a function +The application has some internal validation, so if there is a function (e.g.; the RX core) which doesn't have a cpu core mask assigned, the application will print an error message: diff --git a/doc/guides/tools/testbbdev.rst b/doc/guides/tools/testbbdev.rst index ddb8d787be..baaf9d115d 100644 --- a/doc/guides/tools/testbbdev.rst +++ b/doc/guides/tools/testbbdev.rst @@ -9,7 +9,7 @@ dpdk-test-bbdev Application The ``dpdk-test-bbdev`` tool is a Data Plane Development Kit (DPDK) utility that allows measuring performance parameters of PMDs available in the bbdev framework. Tests available for execution are: latency, throughput, validation, -bler and sanity tests. Execution of tests can be customized using various +bler and basic functionality. Execution of tests can be customized using various parameters passed to a python running script. @@ -97,8 +97,8 @@ Test Cases There are 7 main test cases that can be executed using testbbdev tool: -* Sanity checks [-c unittest] - - Performs sanity checks on BBDEV interface, validating basic functionality +* Functional checks [-c unittest] + - Performs checks on BBDEV interface, validating basic functionality * Validation tests [-c validation] - Performs full operation of enqueue and dequeue @@ -232,7 +232,7 @@ vector name refer more explicitly processing specificity such as is purely read/written for external DDR, lbrm when limited buffer rate matching is expected, or crc_fail when a CRC failure is expected. They are chosen to have a good coverage across sizes and processing -parameters while still keeping their number limited as part of sanity +parameters while still keeping their number limited as part of functional regression. Shortened tree of isg_cid-wireless_dpdk_ae with dpdk compiled and output From patchwork Wed May 29 23:33:41 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140415 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 993C844107; Thu, 30 May 2024 01:39:39 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3F02340DCE; Thu, 30 May 2024 01:39:06 +0200 (CEST) Received: from mail-pj1-f48.google.com (mail-pj1-f48.google.com [209.85.216.48]) by mails.dpdk.org (Postfix) with ESMTP id 0E7FB40289 for ; Thu, 30 May 2024 01:38:21 +0200 (CEST) Received: by mail-pj1-f48.google.com with SMTP id 98e67ed59e1d1-2bfdae0b0e0so235276a91.0 for ; Wed, 29 May 2024 16:38:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025900; x=1717630700; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=H2riqw3f0POwJEge0XVOapup74T2F1I8ILDmuiS2ouc=; b=MDiqePpJ8whbCMcx711KdmLyXHdWww8n0kW9TSWZ92ZpHqzhzsX+ThJt3QQ1H2NeBw fl60kcYxhCDVBpY62m4JFGU/TiTwG/5le/Q6IIkuE+y2ovLpKRFErn73hKMBDA9gP26Y Q3l+IzIfn4DkMgeNzsk3UQCEIe4168UzpcrgDx86jOnNywepE6mCZdzFrW09L38neQG3 /DFG6/3gd9WXeY9WU3ZloKXhy6ZLEY6LT5AkqzGEhnJ5WlKpcKQ3w/oQEti6iXrgWa10 S+7lRP53w5jv0uI6BMp1AzDRMqgPkFd1KS81WZMTjyvV2V6qJ2kGOixQA57enIS5UuNV jjnQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025900; x=1717630700; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=H2riqw3f0POwJEge0XVOapup74T2F1I8ILDmuiS2ouc=; b=E1pA6JJgpObhPWT8r+U7xyb2mW7PNVV/5Woi+yjDt3MwfcErf/d4gJ6qFrZekRaLKC key0gnJ3dI9eWEu+oNw8AnNfwDycTrGdw5qcR0WGia0ZcaJGb/KpHdswrZmVfgSdVafY 0nQblalRTgpE1kn/W3if5mRemF18nVLpUuRoHqCkiEV3RifbfY6r+UdLafT2IQdxchJC zk0QYl5HI7jlNXIbjmfoEyYh0CmnD6F3nbVZCdtPpXotwKgp11YdEu9XBCZsv1WjGJAt H/LmOmcKiKCmRnzxbswhXoqo4rmPBiaBzroiJtBh1YHpF+q4KpcxHwbG/7TsP5B62ETH 6tlw== X-Gm-Message-State: AOJu0YyCPL9QEwC4Yb/ZN5Q3Pb02P0gydC9vzqcweeZgVqrJMWWW3U+q or5v7nitybxg6tCPkD+OhuCK1f4szTlJfdSlAn/sivix+Vh+qZhsJJ+sdxcYnnHWdpFeRMLbXRK 1 X-Google-Smtp-Source: AGHT+IHMu3RgCCd4tTExcw0KKWq71IseHOec30EnyvcfhEM8QqLRGGTbyBTILYNXMI2/MlzU0Xb0pQ== X-Received: by 2002:a17:90a:8592:b0:2c1:a50c:5469 with SMTP id 98e67ed59e1d1-2c1abc4c1e3mr624954a91.42.1717025900195; Wed, 29 May 2024 16:38:20 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:19 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 07/20] net/ring: replace use of sanity Date: Wed, 29 May 2024 16:33:41 -0700 Message-ID: <20240529233811.663211-8-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Don't use term sanity check Signed-off-by: Stephen Hemminger --- drivers/net/ring/rte_eth_ring.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/drivers/net/ring/rte_eth_ring.c b/drivers/net/ring/rte_eth_ring.c index b16f5d55f2..1788e68cf3 100644 --- a/drivers/net/ring/rte_eth_ring.c +++ b/drivers/net/ring/rte_eth_ring.c @@ -34,7 +34,7 @@ struct ring_internal_args { struct rte_ring * const *tx_queues; const unsigned int nb_tx_queues; const unsigned int numa_node; - void *addr; /* self addr for sanity check */ + void *addr; /* self addr for verification */ }; enum dev_action { @@ -606,10 +606,7 @@ static int parse_kvlist(const char *key __rte_unused, *action = '\0'; action++; - /* - * Need to do some sanity checking here - */ - + /* Check the command argument is valid action */ if (strcmp(action, ETH_RING_ACTION_ATTACH) == 0) info->list[info->count].action = DEV_ATTACH; else if (strcmp(action, ETH_RING_ACTION_CREATE) == 0) From patchwork Wed May 29 23:33:42 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140416 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 396F044107; Thu, 30 May 2024 01:39:45 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 938AB40DF6; Thu, 30 May 2024 01:39:07 +0200 (CEST) Received: from mail-pg1-f173.google.com (mail-pg1-f173.google.com [209.85.215.173]) by mails.dpdk.org (Postfix) with ESMTP id D657140289 for ; Thu, 30 May 2024 01:38:21 +0200 (CEST) Received: by mail-pg1-f173.google.com with SMTP id 41be03b00d2f7-68194ee2174so253540a12.3 for ; Wed, 29 May 2024 16:38:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025901; x=1717630701; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=HpaeMRq2qfG+tENQk0ClTJ+bTURIssBL//hAV3p6UHY=; b=Pf/yHo8Sp9qYK9/LouRk3SCfjFv41fSWCxRojetk1OOqmm0ny1VdhpAeyereZtxqGS 8TlhT/MuziX7AmlHLTN8aAl6NZW+tJHknML6GhAteS26tyruSEduDc6xZB0DJwq9w4ev ijzccbVWg91JwzhaH8czwxftNxDJw83rA3xvS8nmoHguSdcBp3UoU5mV1NSpHSpzIYLi tjAwl5HLZWPDx9A/9oO7OomGwQm9dRMAjZ376TbVmJw4x9RcKaotrstuwwVyYRBT88sn GW6jQA3UXaysmiaw8nE2hYhRY9oClrQUlscEsh8zUhVHwFNX2BKKwkTLNJkBatKOU95U uDcg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025901; x=1717630701; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HpaeMRq2qfG+tENQk0ClTJ+bTURIssBL//hAV3p6UHY=; b=jki7rFQP29Fq/GJCsnrkMugaeD7wmXBZsXNPsLFjwDKM0JN3KOEMiLymcAHe7YCKKo s20lbPcE7VkYmZvfCcUhO2LwkzbU8oxO9yTz4xRdL5H7la8X/Op13Mv6HAQEbKVGoXgP ijCT+yiwwkhUPcC+XoD+tAbgInW50lv2TYwNyXZiU2f9zN7hfiZySAlOEl1qqaRZETcc W+5HONlSV+BCIfa7OM47tXhzI25FwUXhBTrZEGobfPsegkaUV1bc5xctq91K2Wv8lAGP 6r6tIN1BadGiaXgidDWBpFFkvYdDAnvk/jYyjOtc55Jxah3xo53Yl+Ih40Bk7X2QuGpx 19kA== X-Gm-Message-State: AOJu0YwPFvn4wJrwCxx2wJ6m3nBhXVa228b1lmN+UsZl+LypF/La/BsS sXiVQD85pxI+dxBghF/Y+RL4rYcjDZZyye9Qvh1Lh5RLz5j9NiwMVINhRYDNlumOskdwJJP5Gjb S X-Google-Smtp-Source: AGHT+IF5A7z6Au2q15wXabYv0R/ITeXn/dR03HeWenFOSn0I1M1Zg+4zuuIf7UKmasqiW+VmSkAehA== X-Received: by 2002:a17:90b:a4d:b0:2b3:28be:ddfa with SMTP id 98e67ed59e1d1-2c1abc6a03dmr570760a91.38.1717025900901; Wed, 29 May 2024 16:38:20 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:20 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 08/20] net/fm10k, net/ixgbe: remove word sanity Date: Wed, 29 May 2024 16:33:42 -0700 Message-ID: <20240529233811.663211-9-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Remove non-inclusive term sanity from these Intel drivers. Signed-off-by: Stephen Hemminger --- drivers/net/fm10k/fm10k_ethdev.c | 2 +- drivers/net/fm10k/fm10k_rxtx.c | 2 +- drivers/net/ixgbe/ixgbe_fdir.c | 2 +- drivers/net/ixgbe/ixgbe_ipsec.c | 2 +- drivers/net/ixgbe/ixgbe_rxtx.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/net/fm10k/fm10k_ethdev.c b/drivers/net/fm10k/fm10k_ethdev.c index fa0d16277e..a415c2c46d 100644 --- a/drivers/net/fm10k/fm10k_ethdev.c +++ b/drivers/net/fm10k/fm10k_ethdev.c @@ -1758,7 +1758,7 @@ mempool_element_size_valid(struct rte_mempool *mp) /* account for up to 512B of alignment */ min_size -= FM10K_RX_DATABUF_ALIGN; - /* sanity check for overflow */ + /* check for overflow */ if (min_size > mp->elt_size) return 0; diff --git a/drivers/net/fm10k/fm10k_rxtx.c b/drivers/net/fm10k/fm10k_rxtx.c index 690142b357..c2940901fe 100644 --- a/drivers/net/fm10k/fm10k_rxtx.c +++ b/drivers/net/fm10k/fm10k_rxtx.c @@ -646,7 +646,7 @@ fm10k_xmit_pkts(void *tx_queue, struct rte_mbuf **tx_pkts, if (q->nb_free < mb->nb_segs) break; - /* sanity check to make sure the mbuf is valid */ + /* check to make sure the mbuf is valid */ if ((mb->nb_segs == 0) || ((mb->nb_segs > 1) && (mb->next == NULL))) break; diff --git a/drivers/net/ixgbe/ixgbe_fdir.c b/drivers/net/ixgbe/ixgbe_fdir.c index 06d6e2126d..51bbf577e3 100644 --- a/drivers/net/ixgbe/ixgbe_fdir.c +++ b/drivers/net/ixgbe/ixgbe_fdir.c @@ -1130,7 +1130,7 @@ ixgbe_fdir_filter_program(struct rte_eth_dev *dev, return -ENOTSUP; /* - * Sanity check for x550. + * Check for x550. * When adding a new filter with flow type set to IPv4, * the flow director mask should be configed before, * and the L4 protocol and ports are masked. diff --git a/drivers/net/ixgbe/ixgbe_ipsec.c b/drivers/net/ixgbe/ixgbe_ipsec.c index d331308556..d4aa3e9ede 100644 --- a/drivers/net/ixgbe/ixgbe_ipsec.c +++ b/drivers/net/ixgbe/ixgbe_ipsec.c @@ -615,7 +615,7 @@ ixgbe_crypto_enable_ipsec(struct rte_eth_dev *dev) rx_offloads = dev->data->dev_conf.rxmode.offloads; tx_offloads = dev->data->dev_conf.txmode.offloads; - /* sanity checks */ + /* input validation */ if (rx_offloads & RTE_ETH_RX_OFFLOAD_TCP_LRO) { PMD_DRV_LOG(ERR, "RSC and IPsec not supported"); return -1; diff --git a/drivers/net/ixgbe/ixgbe_rxtx.c b/drivers/net/ixgbe/ixgbe_rxtx.c index 0d42fd8a3b..5e6aebe3e9 100644 --- a/drivers/net/ixgbe/ixgbe_rxtx.c +++ b/drivers/net/ixgbe/ixgbe_rxtx.c @@ -4983,7 +4983,7 @@ ixgbe_set_rsc(struct rte_eth_dev *dev) uint32_t rdrxctl; uint32_t rfctl; - /* Sanity check */ + /* Offload check */ dev->dev_ops->dev_infos_get(dev, &dev_info); if (dev_info.rx_offload_capa & RTE_ETH_RX_OFFLOAD_TCP_LRO) rsc_capable = true; From patchwork Wed May 29 23:33:43 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140417 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id DB93944107; Thu, 30 May 2024 01:39:54 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DC4F840DFD; Thu, 30 May 2024 01:39:17 +0200 (CEST) Received: from mail-pj1-f42.google.com (mail-pj1-f42.google.com [209.85.216.42]) by mails.dpdk.org (Postfix) with ESMTP id 8247440289 for ; Thu, 30 May 2024 01:38:22 +0200 (CEST) Received: by mail-pj1-f42.google.com with SMTP id 98e67ed59e1d1-2bfff08fc29so224554a91.1 for ; Wed, 29 May 2024 16:38:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025902; x=1717630702; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=hEZs/yjlsC4XWTTPN5o6e5OGi6hZZQkdITaTMei+B9k=; b=ei7KW1Ex8jDNSKyRYvjXKZouQ40MkfdDu2zMbzguwTepux/Marv9GOEQL2+WTGbj9v gczeXagnkwYydgyEJHaY+7YdF0elmCXiq2nqlToTNfmnA6OD1kVIGHssoq+OetLoEkeO ryC3I1C+9FLlrmDcftjyMrqVUcjHUSw9LCq0fgKi8ogbRgTqhopcRoErsyEDFw0owmr4 5G2JxQUYkPP8jCy4pCcuLtAIlhMbuvJjAzKvV8mWS+eNlfEPhOI0OhNSQ4SIiAqy5Bbu wAYXudGueMiOtpvXa9ZreYutC0hf0Xf6EvO2nqfKx9D6nX+oGNDuKfWdsTrmJ5dQ9TI2 1phA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025902; x=1717630702; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=hEZs/yjlsC4XWTTPN5o6e5OGi6hZZQkdITaTMei+B9k=; b=uN0CkgMGUbNQkcSxT+DmfWHxtNacexqipSq1uA9ccymTDUmW+bg+fS4tEP+qFygKJn CR5ZkI0nsQuIYe2tjFqMIYEcftpn3dAx50rKB5FAuITV7tQcYn6g1O4+tn80oyCoBPBA k10uhTkJln+v++B8+w3Q9U7EmQ1dEEEpxlU1++VdidmICb++qFZZhzXznUullznjtuzS dNC6TY27weqHz0j3InEYi3aPepMcI+77L5L7HO8U0mc7FP+P59IIJtBVMBw+T8LqZwNC FcrEjotib1tbHqs2JPqBehk50DGjPCemBlZQSgkD+Xo+TwSSNpG8JEba91VV/XQgCsq+ H3eg== X-Gm-Message-State: AOJu0YzCJ8QGCREBDyasTQA4fGUgxsOhgEaHcxSegnUP1/bD0yayYh4r rlHLeaqFdanM9YcSUkD45oEhHmMCubnfgmW8JBgqVqA0laxk+tl1cSOWiouLMVDGOd9xSKmSxd2 9 X-Google-Smtp-Source: AGHT+IHBy+aMLlBgoE3M2QFfBgzaJKN7evB5vuHYBQpTYhcJBFnFtjsdXmYF1PVgBK1BGc+QHDoliA== X-Received: by 2002:a17:90a:f490:b0:2b1:782:8827 with SMTP id 98e67ed59e1d1-2c1ab9f6d69mr618527a91.20.1717025901564; Wed, 29 May 2024 16:38:21 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:21 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 09/20] net/mlx[45]: remove word sanity Date: Wed, 29 May 2024 16:33:43 -0700 Message-ID: <20240529233811.663211-10-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org The term "sanity" is on non-inclusive naming list. Remove it from the Nvidia drivers. Signed-off-by: Stephen Hemminger --- drivers/common/mlx5/linux/mlx5_common_os.c | 2 +- drivers/net/mlx4/mlx4.c | 2 +- drivers/net/mlx4/mlx4_flow.c | 6 +++--- drivers/net/mlx5/mlx5_flow_dv.c | 2 +- drivers/net/mlx5/mlx5_flow_hw.c | 6 ++---- drivers/net/mlx5/mlx5_rxq.c | 2 +- drivers/net/mlx5/mlx5_rxtx_vec.h | 2 +- 7 files changed, 10 insertions(+), 12 deletions(-) diff --git a/drivers/common/mlx5/linux/mlx5_common_os.c b/drivers/common/mlx5/linux/mlx5_common_os.c index 41345e1597..2caa1a1da0 100644 --- a/drivers/common/mlx5/linux/mlx5_common_os.c +++ b/drivers/common/mlx5/linux/mlx5_common_os.c @@ -235,7 +235,7 @@ mlx5_get_ifname_sysfs(const char *ibdev_path, char *ifname) /** * Suffix RTE_EAL_PMD_PATH with "-glue". * - * This function performs a sanity check on RTE_EAL_PMD_PATH before + * This function performs a check on RTE_EAL_PMD_PATH before * suffixing its last component. * * @param buf[out] diff --git a/drivers/net/mlx4/mlx4.c b/drivers/net/mlx4/mlx4.c index a1a7e93288..c167d7f90f 100644 --- a/drivers/net/mlx4/mlx4.c +++ b/drivers/net/mlx4/mlx4.c @@ -1216,7 +1216,7 @@ static struct rte_pci_driver mlx4_driver = { /** * Suffix RTE_EAL_PMD_PATH with "-glue". * - * This function performs a sanity check on RTE_EAL_PMD_PATH before + * This function performs a check on RTE_EAL_PMD_PATH before * suffixing its last component. * * @param buf[out] diff --git a/drivers/net/mlx4/mlx4_flow.c b/drivers/net/mlx4/mlx4_flow.c index 8ef9fd2db4..25b185d871 100644 --- a/drivers/net/mlx4/mlx4_flow.c +++ b/drivers/net/mlx4/mlx4_flow.c @@ -514,7 +514,7 @@ mlx4_flow_merge_tcp(struct rte_flow *flow, } /** - * Perform basic sanity checks on a pattern item. + * Perform basic checks on a pattern item. * * @param[in] item * Item specification. @@ -730,7 +730,7 @@ mlx4_flow_prepare(struct mlx4_priv *priv, goto exit_item_not_supported; proc = next; /* - * Perform basic sanity checks only once, while handle is + * Perform basic checks only once, while handle is * not allocated. */ if (flow == &temp) { @@ -799,7 +799,7 @@ mlx4_flow_prepare(struct mlx4_priv *priv, rss_key = mlx4_rss_hash_key_default; rss_key_len = MLX4_RSS_HASH_KEY_SIZE; } - /* Sanity checks. */ + /* Input checks. */ for (i = 0; i < rss->queue_num; ++i) if (rss->queue[i] >= ETH_DEV(priv)->data->nb_rx_queues) diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c index f9c56af86c..ace51c8bb5 100644 --- a/drivers/net/mlx5/mlx5_flow_dv.c +++ b/drivers/net/mlx5/mlx5_flow_dv.c @@ -9089,7 +9089,7 @@ flow_dv_prepare(struct rte_eth_dev *dev, #ifdef RTE_LIBRTE_MLX5_DEBUG /** - * Sanity check for match mask and value. Similar to check_valid_spec() in + * Check for match mask and value. Similar to check_valid_spec() in * kernel driver. If unmasked bit is present in value, it returns failure. * * @param match_mask diff --git a/drivers/net/mlx5/mlx5_flow_hw.c b/drivers/net/mlx5/mlx5_flow_hw.c index 825f258065..6f9da172a2 100644 --- a/drivers/net/mlx5/mlx5_flow_hw.c +++ b/drivers/net/mlx5/mlx5_flow_hw.c @@ -8452,11 +8452,10 @@ flow_hw_tx_tag_regc_mask(struct rte_eth_dev *dev) struct mlx5_priv *priv = dev->data->dev_private; uint32_t mask = priv->sh->dv_regc0_mask; - /* Mask is verified during device initialization. Sanity checking here. */ + /* Mask is verified during device initialization. */ MLX5_ASSERT(mask != 0); /* * Availability of sufficient number of bits in REG_C_0 is verified on initialization. - * Sanity checking here. */ MLX5_ASSERT(rte_popcount32(mask) >= rte_popcount32(priv->vport_meta_mask)); return mask; @@ -8468,12 +8467,11 @@ flow_hw_tx_tag_regc_value(struct rte_eth_dev *dev) struct mlx5_priv *priv = dev->data->dev_private; uint32_t tag; - /* Mask is verified during device initialization. Sanity checking here. */ + /* Mask is verified during device initialization. */ MLX5_ASSERT(priv->vport_meta_mask != 0); tag = priv->vport_meta_tag >> (rte_bsf32(priv->vport_meta_mask)); /* * Availability of sufficient number of bits in REG_C_0 is verified on initialization. - * Sanity checking here. */ MLX5_ASSERT((tag & priv->sh->dv_regc0_mask) == tag); return tag; diff --git a/drivers/net/mlx5/mlx5_rxq.c b/drivers/net/mlx5/mlx5_rxq.c index f67aaa6178..d9ed3b1cf9 100644 --- a/drivers/net/mlx5/mlx5_rxq.c +++ b/drivers/net/mlx5/mlx5_rxq.c @@ -1442,7 +1442,7 @@ mlx5_mprq_alloc_mp(struct rte_eth_dev *dev) desc *= 4; obj_num = desc + MLX5_MPRQ_MP_CACHE_SZ * n_ibv; /* - * rte_mempool_create_empty() has sanity check to refuse large cache + * rte_mempool_create_empty() has basic check to refuse large cache * size compared to the number of elements. * CALC_CACHE_FLUSHTHRESH() is defined in a C file, so using a * constant number 2 instead. diff --git a/drivers/net/mlx5/mlx5_rxtx_vec.h b/drivers/net/mlx5/mlx5_rxtx_vec.h index 77c3f4efa0..f8376f2b55 100644 --- a/drivers/net/mlx5/mlx5_rxtx_vec.h +++ b/drivers/net/mlx5/mlx5_rxtx_vec.h @@ -21,7 +21,7 @@ RTE_ETH_TX_OFFLOAD_OUTER_IPV4_CKSUM) /* - * Compile time sanity check for vectorized functions. + * Compile time checks for vectorized functions. */ #define S_ASSERT_RTE_MBUF(s) \ From patchwork Wed May 29 23:33:44 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140418 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A4CEB44107; Thu, 30 May 2024 01:40:00 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 44AAE40E4A; Thu, 30 May 2024 01:39:19 +0200 (CEST) Received: from mail-pj1-f47.google.com (mail-pj1-f47.google.com [209.85.216.47]) by mails.dpdk.org (Postfix) with ESMTP id 1B258402AC for ; Thu, 30 May 2024 01:38:23 +0200 (CEST) Received: by mail-pj1-f47.google.com with SMTP id 98e67ed59e1d1-2c199e776ebso216464a91.3 for ; Wed, 29 May 2024 16:38:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025902; x=1717630702; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Z+wiaZpsXppNysHrGyg9i3rJWp5nRQ5keA2sE+y17qs=; b=v3jFmtU09btfYTjioD2ShaQ+tuyCdHpqjqZ4holQQKssrmbqTIAQIfZKqD7J9tkii6 /cf3igILClxr4pJ6LW+Tp9/bvVidjtLTQitQT1McjXtfmmlcT5OG9PQt2Cf/I6OnsE7A upzouy+8ZfekSm0yrKX4iHoe0YB5LEIb85k3MwluUG9JxHxg7uek8yfVpqoeq8lJ+mT+ YbBU8B9FB6P/fcdjEcrr/i1J5gAsWOxTZXkpOsrn/4/QRNQmnCF45V7xY5S+LtBNdVsq RYRGZdqs+/MZpmohmsOxTWupbYEABEWBEfgrVOBOUEbUgh2lsSNrf6ECNvb4LKE55q1n +DfA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025902; x=1717630702; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Z+wiaZpsXppNysHrGyg9i3rJWp5nRQ5keA2sE+y17qs=; b=YDGgVsULi+yTqBPrIz9ToxGe6uXbDYi3SvIp49vHeXBMPiTDYawiILJMUCm6OEr4m7 y5lmIBJrnzk0kPSRMIl02KhTL59ihRd4TxKW254B7HLIGtzfQqHHYYL9Tne9nZiYwgyD 02nqfJwrWK4nWpfYioV0EnpakS4E3l9VV4tEU4OQLzRby/WpszharHUOOiIX8CKB0QCL Xn++q/GgEavBU5lVGeVWm20b3sx06SuA+gaiAM3zcrPPWzPtSEPSqQTvDRmJkRrAmQW0 9lr2gx+3yyXX2rTzkpeKiPPM65nbsyLwYrzS0gw0sFwz3ktL5k25qpOQQqLEHT/oCZuD ceoQ== X-Gm-Message-State: AOJu0YykF8FC6xBT64u6N1/7cbXi7DT+WApZ01ovFXK2lQi8rAnmJqv2 pa4deQhYbMhDTOyDTTE9pGrxzOEhPXS+bDzwU/jkh/iUbmB+X08Aw0PNB2cMVA1CCryp4sE5Pwj + X-Google-Smtp-Source: AGHT+IG72JYdh1w1jStDkub/dQ2JqyqQZk7g/m+cyZ/O8nnwCLZ3+2cczi9ulNfQ9TJcJMmSHAZTLQ== X-Received: by 2002:a17:90b:1a85:b0:2a2:7a00:f101 with SMTP id 98e67ed59e1d1-2c1abc4a2d9mr492799a91.47.1717025902263; Wed, 29 May 2024 16:38:22 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:21 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Andrew Rybchenko Subject: [PATCH v10 10/20] net/sfc: remove term "sanity check" Date: Wed, 29 May 2024 16:33:44 -0700 Message-ID: <20240529233811.663211-11-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Remove term sanity check in comment. Signed-off-by: Stephen Hemminger Acked-by: Andrew Rybchenko --- drivers/net/sfc/sfc_dp_rx.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/sfc/sfc_dp_rx.h b/drivers/net/sfc/sfc_dp_rx.h index ed667c68d1..17ab10616b 100644 --- a/drivers/net/sfc/sfc_dp_rx.h +++ b/drivers/net/sfc/sfc_dp_rx.h @@ -59,7 +59,7 @@ struct sfc_dp_rx_qcreate_info { /** * Maximum number of Rx descriptors completed in one Rx event. - * Just for sanity checks if datapath would like to do. + * Checks if datapath would like to do. */ unsigned int batch_max; From patchwork Wed May 29 23:33:45 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140419 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 95C8A44107; Thu, 30 May 2024 01:40:07 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 602D140E64; Thu, 30 May 2024 01:39:20 +0200 (CEST) Received: from mail-pj1-f43.google.com (mail-pj1-f43.google.com [209.85.216.43]) by mails.dpdk.org (Postfix) with ESMTP id E4A7940289 for ; Thu, 30 May 2024 01:38:23 +0200 (CEST) Received: by mail-pj1-f43.google.com with SMTP id 98e67ed59e1d1-2c19bba897bso217304a91.2 for ; Wed, 29 May 2024 16:38:23 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025903; x=1717630703; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=yeJQ8PHJLpqlBU3XqZTTMFn1DsCfehaqk2rIHhhaUh4=; b=N8ma+S2+Y4vqOpk/ttRTY2Kx5NjFhFb0Dd10I2UADjLnFEhuV2gWL04Klk1ZrOg2VG ZYTY525lpAwnwSOlxo9HVOsCGWqKHKoU76eEIzBPrmlcz6efsfDKU16lnc0JurxhCF/K CMIRwdI0LissmPOvAh7Gmac72bmGfiJqStdvfgR+smDLKdQRCk4eSAnP+3xIY3Nx/L16 EeBxopLDDyGXTWXG3+AtzTbhmd/hku1NTdZaL5GppLBn/IGLcXL29496m2YC1F4B0uGf I+oDUhft3bPwCl6LG9fGodNwso4kXgclCjGQQSjgBMcE+zyAVPTFsxtEJHg9tSMkRj5A KxDw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025903; x=1717630703; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yeJQ8PHJLpqlBU3XqZTTMFn1DsCfehaqk2rIHhhaUh4=; b=TvkTjQ33dkDRvjzLfC+K639zOWNhFiOdk3S+gcb6ev9YlXwPietKYqMqGmLQHhMxsR 39OdXsPtnto5gq5VvnAz/5SlMqg2qRCq05XiNcRQHZHpnEqy6r3lBlMFKkFv7XO3mKzl 0Pz1V50EYJ8GhfdvDdDwXDWhVMZ0qIBvuUlP56+D01puNRu1u9YQ1E/QSLJuBuXyBMkC 4zCMvFvVlMmoT0o7465xT9CsqtigvlHJgq1Iml5pk7fnTWAbDk6weaOkDp27SjppavoW zmC8SfhYlH0E4mYDfGSwZZ07MfAzsrCiOMLFocH77pyj/nw7YGi5xPW95meWehuE/WWm qdGg== X-Gm-Message-State: AOJu0YyqaSeOar6QZVoeLRjOLClEYvL1VlZhxev0yO/ZCULjVv8vfFK8 sZy16tm3Thd4XWSyOUWyNN7m6NakbHIe2bQdXalbbyF5UTw3Sp2/ub8KTJyt8N6HexRtBhKp3Cn M X-Google-Smtp-Source: AGHT+IG06pxq67UN9F+PNs9cJsGWS8WiZou9bTA2Npq/qC7h+l3JCMVMZuoO3qG8M3rKkvg/G+zsHQ== X-Received: by 2002:a17:90a:8a13:b0:2bd:e806:49dd with SMTP id 98e67ed59e1d1-2c1abc06531mr573181a91.8.1717025903043; Wed, 29 May 2024 16:38:23 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:22 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 11/20] net/ark: replace use of term sanity Date: Wed, 29 May 2024 16:33:45 -0700 Message-ID: <20240529233811.663211-12-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Do not use non inclusive terms. Signed-off-by: Stephen Hemminger --- drivers/net/ark/ark_ethdev.c | 8 ++++---- drivers/net/ark/ark_ethdev_rx.c | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/net/ark/ark_ethdev.c b/drivers/net/ark/ark_ethdev.c index c029dc46b3..36b3e2b8e6 100644 --- a/drivers/net/ark/ark_ethdev.c +++ b/drivers/net/ark/ark_ethdev.c @@ -349,10 +349,10 @@ eth_ark_dev_init(struct rte_eth_dev *dev) ARK_PMD_LOG(NOTICE, "Arkville HW Commit_ID: %08x\n", rte_be_to_cpu_32(ark->sysctrl.t32[0x20 / 4])); - /* If HW sanity test fails, return an error */ + /* If HW test fails, return an error */ if (ark->sysctrl.t32[4] != 0xcafef00d) { ARK_PMD_LOG(ERR, - "HW Sanity test has failed, expected constant" + "HW test has failed, expected constant" " 0x%x, read 0x%x (%s)\n", 0xcafef00d, ark->sysctrl.t32[4], __func__); @@ -360,7 +360,7 @@ eth_ark_dev_init(struct rte_eth_dev *dev) } ARK_PMD_LOG(DEBUG, - "HW Sanity test has PASSED, expected constant" + "HW test has PASSED, expected constant" " 0x%x, read 0x%x (%s)\n", 0xcafef00d, ark->sysctrl.t32[4], __func__); @@ -590,7 +590,7 @@ eth_ark_dev_start(struct rte_eth_dev *dev) rte_thread_t thread; /* Delay packet generator start allow the hardware to be ready - * This is only used for sanity checking with internal generator + * This is only used for checking with internal generator */ char tname[RTE_THREAD_INTERNAL_NAME_SIZE]; snprintf(tname, sizeof(tname), "ark-pg%d", dev->data->port_id); diff --git a/drivers/net/ark/ark_ethdev_rx.c b/drivers/net/ark/ark_ethdev_rx.c index 80e431f1ae..e7683c9175 100644 --- a/drivers/net/ark/ark_ethdev_rx.c +++ b/drivers/net/ark/ark_ethdev_rx.c @@ -283,7 +283,7 @@ eth_ark_recv_pkts(void *rx_queue, mbuf->pkt_len = meta->pkt_len; mbuf->data_len = meta->pkt_len; - if (ARK_DEBUG_CORE) { /* debug sanity checks */ + if (ARK_DEBUG_CORE) { /* debug checks */ if ((meta->pkt_len > (1024 * 16)) || (meta->pkt_len == 0)) { From patchwork Wed May 29 23:33:46 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140420 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 25CEE44107; Thu, 30 May 2024 01:40:13 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 5F63D40E7C; Thu, 30 May 2024 01:39:21 +0200 (CEST) Received: from mail-pj1-f42.google.com (mail-pj1-f42.google.com [209.85.216.42]) by mails.dpdk.org (Postfix) with ESMTP id 86CAA402AC for ; Thu, 30 May 2024 01:38:24 +0200 (CEST) Received: by mail-pj1-f42.google.com with SMTP id 98e67ed59e1d1-2b9702e05easo224424a91.1 for ; Wed, 29 May 2024 16:38:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025904; x=1717630704; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=OeMYdvN4uxwlF4f8v4CpCS1mvxuwjcP5WXYWfqqRWW4=; b=P8RUMLZcmc5ILffJLulaGbxvUCtY1u8OF1fpRaTzdO3t0yeR5DzjQk0LRs4a8w/HDS wyCov3BMJGpDFeNLRg+5+Jtp4bLGIidgeoak7l3EbIh92Y8SWDlgmdmq04CfeUiOOHXj 6gYPsrxMfV171Xax6sdSiCzPKJUM8CbfZJTcagWLWcqf6G80GFeatV/2UN4aCE5Gcsij OPMjEWm83aO+wAXcjJNvXV5PiY6qr036z7wUWkhotyaQfr/qyv70IP11wVVR349eqM3A Inb76PQDu8KVs9Q251FfPmqGymrQjCddRdlOt6Z0NjyWEoBYEy2zcH9uSK/ytVF/aK6E zV6g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025904; x=1717630704; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=OeMYdvN4uxwlF4f8v4CpCS1mvxuwjcP5WXYWfqqRWW4=; b=gZRCdjioG+D//kMMjOAFoYS3H8RwvnhBvj+Su3y8sUeh+tzzxR8SHRIQ1rnJ9Z/7f6 ZlzpMgkXDcWmI4eneLRc9/DsS5Sex4owwAbaTSVHjdNOigsdrLUe2EwYpRx2kg4GZuKE zSCxJAHRxaAXM7r4zqA8tes+DzR18Bnib7TEOVLd/uEEbYnRWZYogECWM5qxdExmxDKP cxMPGiEmSTrVzezOaBbC7zom4Hz3yiLLpglnay4XaiEU4a/PaXOepOzaDaHPuizd5VwZ VTu36KqqzD0wvq0232VeuMvg/74y0kaEJtaA9Ny9o2UsCQ2WP3b/2Faxug3q6PaBP5ym Wu9g== X-Gm-Message-State: AOJu0YyuiUPfBnjcpurpOGaNudXuah19lnsuqf3AwLplqhLPMm5Lx9d9 FcvCu/p4BlysNP1g10lRQ2CImLUk6An5y8JDFm/PmYDDkKRlXDJ1kLXqky4Tlr8EIlyucQpKCAk C X-Google-Smtp-Source: AGHT+IFmAfr134XKePvcWPqThCgES3vIzmlrczjs/BhZxnFkI85Su6OvC0xtMFiYBow1LsSd53HdsA== X-Received: by 2002:a17:90b:2245:b0:2bf:6b68:5219 with SMTP id 98e67ed59e1d1-2c1abc4d0a2mr547954a91.41.1717025903697; Wed, 29 May 2024 16:38:23 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:23 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 12/20] net/bnxt: replace use of term sanity Date: Wed, 29 May 2024 16:33:46 -0700 Message-ID: <20240529233811.663211-13-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Do not use non-inclusive terms. Signed-off-by: Stephen Hemminger --- drivers/net/bnxt/bnxt_hwrm.c | 2 +- drivers/net/bnxt/hsi_struct_def_dpdk.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/bnxt/bnxt_hwrm.c b/drivers/net/bnxt/bnxt_hwrm.c index 6ea7089a3f..26d29c88cd 100644 --- a/drivers/net/bnxt/bnxt_hwrm.c +++ b/drivers/net/bnxt/bnxt_hwrm.c @@ -575,7 +575,7 @@ static int bnxt_hwrm_send_message(struct bnxt *bp, void *msg, done = bnxt_check_cq_hwrm_done(cpr, is_tx, is_rx, i == timeout - 1); - /* Sanity check on the resp->resp_len */ + /* Input check on the resp->resp_len */ rte_io_rmb(); if (resp->resp_len && resp->resp_len <= bp->max_resp_len) { /* Last byte of resp contains the valid key */ diff --git a/drivers/net/bnxt/hsi_struct_def_dpdk.h b/drivers/net/bnxt/hsi_struct_def_dpdk.h index 9beacd94aa..ff7646179a 100644 --- a/drivers/net/bnxt/hsi_struct_def_dpdk.h +++ b/drivers/net/bnxt/hsi_struct_def_dpdk.h @@ -56770,7 +56770,7 @@ struct hwrm_tfc_ident_alloc_output { * Requests the firmware to free a TFC resource identifier. * A resource subtype and session id are passed in. * An identifier (previously allocated) corresponding to all these is - * freed, only after various sanity checks are completed. + * freed, only after various checks are completed. */ /* hwrm_tfc_ident_free_input (size:192b/24B) */ struct hwrm_tfc_ident_free_input { From patchwork Wed May 29 23:33:47 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140421 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8E63244107; Thu, 30 May 2024 01:40:18 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7B0CC40ECF; Thu, 30 May 2024 01:39:22 +0200 (CEST) Received: from mail-pj1-f41.google.com (mail-pj1-f41.google.com [209.85.216.41]) by mails.dpdk.org (Postfix) with ESMTP id 51DC040289 for ; Thu, 30 May 2024 01:38:25 +0200 (CEST) Received: by mail-pj1-f41.google.com with SMTP id 98e67ed59e1d1-2c19bba897bso217322a91.2 for ; Wed, 29 May 2024 16:38:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025904; x=1717630704; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=trAkbZT49bJ6O/6HmxX+9AQ6qGq927l9uIzIHWmZqB0=; b=hTNTiVavXkraevGhbqnXwFqUGQQFS83+V6cB1BpcuOM1pP4hJBZtKhVNoWpnR6K7pw 9FWgKNhojmW2Xhi0kgDL+Q3qJwZ1SWWV+2OduJ46/fuf30Xcudxf3mJI85ZlAKc2to2X S69EB44gdvScnQdMzGicQr/W0cWP7RLUDmz2mn8uokEltUp/Fe+I9+DmrrKT/FKmjCvj Sj4eT/dOldml7kAoZ/m3S3736Y9X5mDxV6GjyiEWEdjRt2raCaPasy+0Gu8x21/RXqK/ ivedi6LAO1xrm89CbebukkElUYNCu9gEGQKhQotdyWJzt2e9zg35EaEyP5+bhT+mJ6hT t8AQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025904; x=1717630704; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=trAkbZT49bJ6O/6HmxX+9AQ6qGq927l9uIzIHWmZqB0=; b=XiLj2g+11F1r+KwodizvWnbxb5OT7q4F4qkqt3GmZOaM95A/3i0JTidsXMNRzgYdI9 PDXA4S5jDogmCeaBHmrvUFihkfYMqx295s3ZYTTTV9SYQevSnhOuG9feL924Jt1iQPnB Hjx+0uoFuD+I5V5u/duPfvJYnKLZHP6/jdCc55BP/gBEnST51x4MGesDlDM+/+ARKKD9 Qzknw2Ul+iUHJidWd+7tr+3OwsJDhLCUVyQTIyEAoJ+dr+rqUrx50AEn6MwnIMuluSiI 2hJaXkRJhHPjZD3GZI5vaPTe6Za//eme7X8EBG641vnvE5irUFtL3RnXCoW/jX0qzF4Y OFDw== X-Gm-Message-State: AOJu0YwSaTPlV3rDStHjEsCtYIYNcO0ezEOUuEcGKkGJKrFh4TVoIRhC ZzMFhZvOoer5A9Zp28IpzGAPLT1WSJeXXdE5vwz53608mnKcE7bMZQTtJVo7VuG2FlZq56GQW6B T X-Google-Smtp-Source: AGHT+IH12KtEHwnEboF7Lvy2bMclxGxLK6x4ffdNy5mzKef7XKk7pPhitLWejsBjUMv3rPGZRRaIUg== X-Received: by 2002:a17:90a:e650:b0:2ac:f010:b1c0 with SMTP id 98e67ed59e1d1-2c1abc38d8bmr628295a91.22.1717025904341; Wed, 29 May 2024 16:38:24 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:24 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 13/20] net/bnx2x: remove reference to sanity Date: Wed, 29 May 2024 16:33:47 -0700 Message-ID: <20240529233811.663211-14-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Replace "sanity check" Signed-off-by: Stephen Hemminger --- drivers/net/bnx2x/bnx2x.c | 2 +- drivers/net/bnx2x/bnx2x_stats.c | 8 ++++---- drivers/net/bnx2x/ecore_sp.c | 2 +- drivers/net/bnx2x/elink.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/drivers/net/bnx2x/bnx2x.c b/drivers/net/bnx2x/bnx2x.c index 597ee43359..92abd2d3f1 100644 --- a/drivers/net/bnx2x/bnx2x.c +++ b/drivers/net/bnx2x/bnx2x.c @@ -7820,7 +7820,7 @@ static int bnx2x_check_valid_mf_cfg(struct bnx2x_softc *sc) uint32_t ovlan2; uint8_t i, j; - /* various MF mode sanity checks... */ + /* various MF mode checks... */ if (mf_info->mf_config[SC_VN(sc)] & FUNC_MF_CFG_FUNC_HIDE) { PMD_DRV_LOG(NOTICE, sc, diff --git a/drivers/net/bnx2x/bnx2x_stats.c b/drivers/net/bnx2x/bnx2x_stats.c index d473c5e7ec..9dcb90bda8 100644 --- a/drivers/net/bnx2x/bnx2x_stats.c +++ b/drivers/net/bnx2x/bnx2x_stats.c @@ -181,7 +181,7 @@ bnx2x_stats_pmf_update(struct bnx2x_softc *sc) */ return; } - /* sanity */ + /* input validation */ if (!sc->port.pmf || !sc->port.port_stx) { PMD_DRV_LOG(ERR, sc, "BUG!"); return; @@ -231,7 +231,7 @@ bnx2x_port_stats_init(struct bnx2x_softc *sc) uint32_t mac_addr; uint32_t *stats_comp = BNX2X_SP(sc, stats_comp); - /* sanity */ + /* input validation */ if (!sc->link_vars.link_up || !sc->port.pmf) { PMD_DRV_LOG(ERR, sc, "BUG!"); return; @@ -457,7 +457,7 @@ bnx2x_func_stats_init(struct bnx2x_softc *sc) struct dmae_command *dmae = &sc->stats_dmae; uint32_t *stats_comp = BNX2X_SP(sc, stats_comp); - /* sanity */ + /* input validation */ if (!sc->func_stx) { PMD_DRV_LOG(ERR, sc, "BUG!"); return; @@ -1280,7 +1280,7 @@ bnx2x_port_stats_base_init(struct bnx2x_softc *sc) struct dmae_command *dmae; uint32_t *stats_comp = BNX2X_SP(sc, stats_comp); - /* sanity */ + /* input validation */ if (!sc->port.pmf || !sc->port.port_stx) { PMD_DRV_LOG(ERR, sc, "BUG!"); return; diff --git a/drivers/net/bnx2x/ecore_sp.c b/drivers/net/bnx2x/ecore_sp.c index c6c3857778..158205266f 100644 --- a/drivers/net/bnx2x/ecore_sp.c +++ b/drivers/net/bnx2x/ecore_sp.c @@ -207,7 +207,7 @@ static int ecore_exe_queue_step(struct bnx2x_softc *sc, break; } - /* Sanity check */ + /* Argument check */ if (!cur_len) return ECORE_SUCCESS; diff --git a/drivers/net/bnx2x/elink.c b/drivers/net/bnx2x/elink.c index 2c81f85b96..6ebd47d927 100644 --- a/drivers/net/bnx2x/elink.c +++ b/drivers/net/bnx2x/elink.c @@ -1088,7 +1088,7 @@ static void elink_get_epio(struct bnx2x_softc *sc, uint32_t epio_pin, { uint32_t epio_mask, gp_oenable; *en = 0; - /* Sanity check */ + /* Input check */ if (epio_pin > 31) { ELINK_DEBUG_P1(sc, "Invalid EPIO pin %d to get", epio_pin); return; @@ -1105,7 +1105,7 @@ static void elink_set_epio(struct bnx2x_softc *sc, uint32_t epio_pin, uint32_t e { uint32_t epio_mask, gp_output, gp_oenable; - /* Sanity check */ + /* Input check */ if (epio_pin > 31) { ELINK_DEBUG_P1(sc, "Invalid EPIO pin %d to set", epio_pin); return; From patchwork Wed May 29 23:33:48 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140422 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 6D4A744107; Thu, 30 May 2024 01:40:24 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 796AF40ED6; Thu, 30 May 2024 01:39:23 +0200 (CEST) Received: from mail-pg1-f177.google.com (mail-pg1-f177.google.com [209.85.215.177]) by mails.dpdk.org (Postfix) with ESMTP id E6E4B40289 for ; Thu, 30 May 2024 01:38:25 +0200 (CEST) Received: by mail-pg1-f177.google.com with SMTP id 41be03b00d2f7-681953ad4f2so209216a12.2 for ; Wed, 29 May 2024 16:38:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025905; x=1717630705; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=eqD33bxrhYubXW7en0psCKuD/ThpoZ4cAdL78yd2Q+w=; b=n+OOscDLIsna+8nTxwKv/sjGx0R+Y3IUzSeORSivv79Z0nS5wMCeZc7GNK2zP5hvBR a2N/Q0SzUbeAp5CdxmUNZ5oXuYWk7Vj39Xm8lJ1O6c//xrb4bKhbGyMa6w8/Nud2oiiJ W7Sn/4kl12EUnlkHcAZ7a5gDHXKlSz4VEbir4iZqwa6m+p7+rdeTesLirdph6IT5avSH nRH8kXAo+Dqj3F0STD3mnQn18EmGdzFGBgyk/gIEX4Uj/hmldev+2aaF9Z+5BbCv9pKq eh9gEa/kh3DMhtP2K6QCkXOyUl/DxtE8OfbwIlMTOuqE2BRQAXjkvhAf9mt5XfZhmqrr mOig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025905; x=1717630705; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=eqD33bxrhYubXW7en0psCKuD/ThpoZ4cAdL78yd2Q+w=; b=UEa1AGppxqEnNxwwLoblMM8FENYDEiUmHZQ3/3fPYO6IYyWQEvphx2XrXJ5Egwfx3k 9haFS/3NzP4gVOcTdOjJAHGRhPMs5PZ0nhJEavWwhtx56Xw6ZqrOY5PUCBGulZMR0/nG s89XQh5VgNX+E+Zw1nEoA6CaXaDXGy1Nw4g1p4/eEGsHIMU9HgFHL3kmnT7YNMeLdvgF VhzTpWkCSmVi8qkq4TDlK7LUHWZ89DYfsBQE10X3kZSUqcjy04U675Ad+QZBm93j/Y0w erSO8d2nepVylcTXPP75yAVkKBZ7mUVupgKUR2CwyNaZxQlRfrECYK+g/4QtYDqG8EyU Z5KA== X-Gm-Message-State: AOJu0YyoTILsqcHB5fBIx//wl10xjLVqAtKyH+tdZZcmzCBZFcWVp+3D BvYTh5vlxKmMCoL7kZs/ioU5dNxge+DRvmdSIdDCrXQ4Tj92/hmDqr96yOADCb6N/T/fz8iOWel s X-Google-Smtp-Source: AGHT+IEJID1PJPIApKMyfHERsRDUbN9eYuY0vrERBhs5Nig3L4AfWU1pks9yByxGAJpVAY1oxhSH1Q== X-Received: by 2002:a17:90a:a097:b0:2bd:b155:a7d8 with SMTP id 98e67ed59e1d1-2c1abc3c336mr634913a91.22.1717025905104; Wed, 29 May 2024 16:38:25 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:24 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 14/20] net/nfp: replace use of term sanity Date: Wed, 29 May 2024 16:33:48 -0700 Message-ID: <20240529233811.663211-15-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Replace "sanity check" Signed-off-by: Stephen Hemminger --- drivers/net/nfp/nfp_net_flow.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/nfp/nfp_net_flow.c b/drivers/net/nfp/nfp_net_flow.c index ea743eed73..2d443bbcfc 100644 --- a/drivers/net/nfp/nfp_net_flow.c +++ b/drivers/net/nfp/nfp_net_flow.c @@ -519,7 +519,7 @@ nfp_net_flow_compile_items(const struct rte_flow_item items[], break; } - /* Perform basic sanity checks */ + /* Perform basic checks */ ret = nfp_net_flow_item_check(item, proc); if (ret != 0) { PMD_DRV_LOG(ERR, "NFP flow item %d check failed", item->type); From patchwork Wed May 29 23:33:49 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140423 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 72C3A44107; Thu, 30 May 2024 01:40:30 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7503040EDD; Thu, 30 May 2024 01:39:24 +0200 (CEST) Received: from mail-pg1-f178.google.com (mail-pg1-f178.google.com [209.85.215.178]) by mails.dpdk.org (Postfix) with ESMTP id 930F340289 for ; Thu, 30 May 2024 01:38:26 +0200 (CEST) Received: by mail-pg1-f178.google.com with SMTP id 41be03b00d2f7-68197edc2d3so246595a12.2 for ; Wed, 29 May 2024 16:38:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025906; x=1717630706; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=q/Tv9IOz1FThj5ft4iemRxzx0yoUwF4B/otck3ReKgw=; b=awDPTNQIEDOGkQUNDBji6o56m84q0RjyIsz0zXqNDOuii2PQjmwtbLy/upDCQJ3yC8 Qu++FqmUh1dPK89mJEgJFBb9cFDHtR65UYHuucH2wJeBFJ5YX9LwURMyjwFJsCf+ypIa RGaI2lGfviBytb1g+orUmTU9OToM8+qK58C45YaGbykuzpk8xHG7fWXnpNoo8javVkJz txV35rYy5JWibVxOqlSJeZiBVWYt2NYeWm0UtRAwXxkVOpV1+c9c2UVkm9an1n1ujmZI r1Z9//VuplkpEhfHm28gLp2iWbzI+bcKXUb6s7eM5ln5d9ahaubeZkSfiIpHz34f8/UO uIUA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025906; x=1717630706; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=q/Tv9IOz1FThj5ft4iemRxzx0yoUwF4B/otck3ReKgw=; b=qnYN+AMjjuYeBCilrLWFp6azjTA5aCWw5ouS7MAd8IRfQB/WLuHtG68bxWOyphJvE+ DU5A9yTq69VirBHy17L51LQM7GYUe9AA6728A9891aIrZdWNe0OnGE2/nKsaUA5Kcf4z 8R12uh7Suj8TJAJJhBrBmcF3JwmHs9l01qx47zPER3JrgTAUHYRIZ/+4fycajGmUeMDb 7XYmYswwnPBqquq90vIlCnF2cyk6XYD/Pcow2KVLwmBtmR2NIyXWieG6j1e21mZwvGyA RgkQRAh9pVBOh2MhLUNEa26ZRQNP5LVKtrsTjTnvecERlNOtE1nFg7gr0el0o+Tip2+z gyvQ== X-Gm-Message-State: AOJu0Yw7vMXkbEuCmuqRgG3cKC759n7Eh91SviR4gGKj2llV4yEkKHr2 jC+rbCWy78XwPt4dg4VBX/ruhBG4T0829AmUp5jimEqFUhM8DmT+tOcxh9Y6UavfYKHheJbMGe2 B X-Google-Smtp-Source: AGHT+IEy5qkH69TNlQaNOyuqUH+9t/uLES6XUhwxHEyZHGvUURdnIwFFSoCRLAZqJa1U+WPR23SS7A== X-Received: by 2002:a05:6a20:6a14:b0:1af:e624:b9b1 with SMTP id adf61e73a8af0-1b26454508dmr539034637.21.1717025905803; Wed, 29 May 2024 16:38:25 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:25 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 15/20] net/txgbe: replace term sanity Date: Wed, 29 May 2024 16:33:49 -0700 Message-ID: <20240529233811.663211-16-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Don't use term sanity. Signed-off-by: Stephen Hemminger --- drivers/net/txgbe/txgbe_ipsec.c | 2 +- drivers/net/txgbe/txgbe_rxtx.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/net/txgbe/txgbe_ipsec.c b/drivers/net/txgbe/txgbe_ipsec.c index f9f8108fb8..cadb0943c8 100644 --- a/drivers/net/txgbe/txgbe_ipsec.c +++ b/drivers/net/txgbe/txgbe_ipsec.c @@ -595,7 +595,7 @@ txgbe_crypto_enable_ipsec(struct rte_eth_dev *dev) rx_offloads = dev->data->dev_conf.rxmode.offloads; tx_offloads = dev->data->dev_conf.txmode.offloads; - /* sanity checks */ + /* offload checks */ if (rx_offloads & RTE_ETH_RX_OFFLOAD_TCP_LRO) { PMD_DRV_LOG(ERR, "RSC and IPsec not supported"); return -1; diff --git a/drivers/net/txgbe/txgbe_rxtx.c b/drivers/net/txgbe/txgbe_rxtx.c index 2568bf0b85..17c4449d93 100644 --- a/drivers/net/txgbe/txgbe_rxtx.c +++ b/drivers/net/txgbe/txgbe_rxtx.c @@ -4115,7 +4115,7 @@ txgbe_set_rsc(struct rte_eth_dev *dev) uint32_t rdrxctl; uint32_t rfctl; - /* Sanity check */ + /* Offload check */ dev->dev_ops->dev_infos_get(dev, &dev_info); if (dev_info.rx_offload_capa & RTE_ETH_RX_OFFLOAD_TCP_LRO) rsc_capable = true; From patchwork Wed May 29 23:33:50 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140424 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id A99A844107; Thu, 30 May 2024 01:40:35 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 8CBFA40EE6; Thu, 30 May 2024 01:39:25 +0200 (CEST) Received: from mail-pj1-f48.google.com (mail-pj1-f48.google.com [209.85.216.48]) by mails.dpdk.org (Postfix) with ESMTP id 6915740289 for ; Thu, 30 May 2024 01:38:27 +0200 (CEST) Received: by mail-pj1-f48.google.com with SMTP id 98e67ed59e1d1-2c1a5913777so246686a91.2 for ; Wed, 29 May 2024 16:38:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025906; x=1717630706; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=UfPxKQW4bN9g8JzuRkGjtvJT+boQkdJkMK3fzGSWpLY=; b=biIlxzlxZaYW22bk5Zugz5dQb3MVQGAcHf2QZzhZdIuve1aSHixgPtfkfBzfeBXRta /dByBjVc5vlIBDHArnTR52rs01yglLAS6pe65FygveYsS2YPKJGpJVmx3FNlyMBexnrK JHMZ8gtcizcuZ+r5SDioift9sVprhLDzJaqGUlYaGXsBhm6iXm/PFb5I4oiVmZogkKvW wwmDGMiWDEEiz7wC8XnstNJQQ3iglJd0nMRQRsBvQLkSCpgD0gjYnd3m+IB3Jnw+/jmD cll6hLqoXzlUuwmWFjA0x0qXb7lrwrCrnOf7oDnIdOMSQ0vgt0+ZQwAbJBdwnc0dqNWH F5zQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025906; x=1717630706; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=UfPxKQW4bN9g8JzuRkGjtvJT+boQkdJkMK3fzGSWpLY=; b=V95/pnPXf7uFZzwPwDKMcIF6HLPKZH5abnn3rnEDChR4RtvS6FQ5KRQ+NF7phzy3RE qJUvn+QSsgw3tydZY9oMl4E+O6dionJ77UHAZOKSpEuku1qo4D3ByxxYAj7gZ67PS+0+ Uw85fxEH+/J1bHX33i+xC51ysfW1OAqz7tpoEgmV6EssC0ORAvyXtg3BZN6C/JT79LHR q0m0nAlO+LGmpHr4d5xtTJMdC19ICv3+tjnUaJiAdP+IeVF9oZc8UYrxxdfBRrvDaN2R uP6SMGWfvMtWOcemYLu/VAJ7/l5dPjSKW0WkJ+4458VMH0GDK7zEQ6K3YuZcxy5ZU0rG bz7g== X-Gm-Message-State: AOJu0YxL4GTLfe5KBOc75nCzxeRWr6k6vHQJSC4153ze8QaHGsvwM8he iMBniq+FGk+ExrZRwdHUtlww7WOF0iAfZyUC/0AGCLYQzZLAfkEyw7/QmwPG7YJ77aZcwHbH25g p X-Google-Smtp-Source: AGHT+IGHGcfs+c0YytsuYBRQqtcbUvZb0Vf8a96EpObawXsQGEuXG0TPsJKRP5Ll1Q4zMpA6q946/A== X-Received: by 2002:a17:90a:a897:b0:2bd:d6d1:c54a with SMTP id 98e67ed59e1d1-2c1abc468b0mr604225a91.40.1717025906432; Wed, 29 May 2024 16:38:26 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:26 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 16/20] net/cxgbe: remove use of term sanity Date: Wed, 29 May 2024 16:33:50 -0700 Message-ID: <20240529233811.663211-17-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Remove non-inclusive terminolgy. Signed-off-by: Stephen Hemminger --- drivers/net/cxgbe/cxgbe_ethdev.c | 10 ++-------- drivers/net/cxgbe/cxgbevf_main.c | 4 ++-- 2 files changed, 4 insertions(+), 10 deletions(-) diff --git a/drivers/net/cxgbe/cxgbe_ethdev.c b/drivers/net/cxgbe/cxgbe_ethdev.c index a27b9b266e..31a65430f6 100644 --- a/drivers/net/cxgbe/cxgbe_ethdev.c +++ b/drivers/net/cxgbe/cxgbe_ethdev.c @@ -524,10 +524,7 @@ int cxgbe_dev_tx_queue_setup(struct rte_eth_dev *eth_dev, eth_dev->data->tx_queues[queue_idx] = (void *)txq; - /* Sanity Checking - * - * nb_desc should be > 1023 and <= CXGBE_MAX_RING_DESC_SIZE - */ + /* nb_desc should be > 1023 and <= CXGBE_MAX_RING_DESC_SIZE */ temp_nb_desc = nb_desc; if (nb_desc < CXGBE_MIN_RING_DESC_SIZE) { dev_warn(adapter, "%s: number of descriptors must be >= %d. Using default [%d]\n", @@ -648,10 +645,7 @@ int cxgbe_dev_rx_queue_setup(struct rte_eth_dev *eth_dev, eth_dev->data->rx_queues[queue_idx] = (void *)rxq; - /* Sanity Checking - * - * nb_desc should be > 0 and <= CXGBE_MAX_RING_DESC_SIZE - */ + /* nb_desc should be > 0 and <= CXGBE_MAX_RING_DESC_SIZE */ temp_nb_desc = nb_desc; if (nb_desc < CXGBE_MIN_RING_DESC_SIZE) { dev_warn(adapter, "%s: number of descriptors must be >= %d. Using default [%d]\n", diff --git a/drivers/net/cxgbe/cxgbevf_main.c b/drivers/net/cxgbe/cxgbevf_main.c index d0c93f8ac3..dfb12b4ed5 100644 --- a/drivers/net/cxgbe/cxgbevf_main.c +++ b/drivers/net/cxgbe/cxgbevf_main.c @@ -137,7 +137,7 @@ static int adap_init0vf(struct adapter *adapter) /* * Grab our Virtual Interface resource allocation, extract the - * features that we're interested in and do a bit of sanity testing on + * features that we're interested in and do a bit of testing on * what we discover. */ err = t4vf_get_vfres(adapter); @@ -148,7 +148,7 @@ static int adap_init0vf(struct adapter *adapter) } /* - * Check for various parameter sanity issues. + * Check for various parameter issues. */ if (adapter->params.vfres.pmask == 0) { dev_err(adapter->pdev_dev, "no port access configured\n" From patchwork Wed May 29 23:33:51 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140425 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 8B80344107; Thu, 30 May 2024 01:40:40 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id BA31040EF0; Thu, 30 May 2024 01:39:26 +0200 (CEST) Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) by mails.dpdk.org (Postfix) with ESMTP id 0ABA440289 for ; Thu, 30 May 2024 01:38:28 +0200 (CEST) Received: by mail-pj1-f45.google.com with SMTP id 98e67ed59e1d1-2bfdae7997aso215230a91.2 for ; Wed, 29 May 2024 16:38:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025907; x=1717630707; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=/z0dndd2a0BY1CbkfjHepoRC+A1Eb1MqK15oA9kd9co=; b=P9pt4Iw2UoDZM6/kc2fLhJKIh1D1huke9qxUd5sslTFCl+ddrQ+F6FndUeUMHJxKC2 5iLgX1NJC87nXh8YgSV9ToXQ0EmP72N/BfKRlt19WcQL1b9gbCGaHX2GIzaVNrBsWR3a gBgh4NNolRUQe1sc07vEWMim+peWp+aNbSi9iwFN/Et4ntaGHpamFLawlF6eUcFCqgNL O+pl3n4s9HvNc2DzHEAKIeVmZ69nQV+nMIQApZXKry0zrzFciLArIwfjDUjj0rfG9klZ uEPDvY2Nkf9rm/LIcsJACmjM4EdOwbnos9G3fzfgFBy3VB7hJJRtNkqaYjd9v1cs3iRn mgXQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025907; x=1717630707; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=/z0dndd2a0BY1CbkfjHepoRC+A1Eb1MqK15oA9kd9co=; b=eYdSE9TD2CRcSQXmVpI72dwzwVtT2rVSea/dUDdv6jQnJkmwg6vyFLZCzlvNRaKwVR 8dG5vEMsQau+kKMVys6+vcnox1M621hCVkRUTwGTioD9B6AxDKSYj+qxQdbF7m2J5bYp pp8zem78ZSW2irrcvdo5/9DHalcnRiY+JnoZ/89gr5pypBpIOtqESiaC5+LvztV/tRJ9 dzuYpnIdOxrfUSpc0/ezrsGyh52Okzwm55UvKTRF0oNJL8HaG5YLejSk7GANwxpCxwAh cfddK/rkqHh2rMzEs9Kjr83MphiPxE6eOlCUMUsMBS5ZU3qf9RAqqXetSH7ks2IeeK4G 5EmQ== X-Gm-Message-State: AOJu0YwOxn56B1Hr/wwJHUWf254jgjGzKLMCnGfB9oEVEU3CaKO12BcX IBAUnWjQUq5emLPmcCdNfOPeVneaH/PsEo6Fh0YPnjKxGdqsMMaOlbknmiqS1jynHs5sYBx4Rvz 6 X-Google-Smtp-Source: AGHT+IFOoZPpqHavDosULk46QA4KpZATyuc2IhOwSn6h5NAvfHZ5N9Ejm/FAuVVrUCc0irV66jGS0g== X-Received: by 2002:a17:90a:c981:b0:2bf:7ade:a7dc with SMTP id 98e67ed59e1d1-2c1ab9dfe06mr596561a91.10.1717025907156; Wed, 29 May 2024 16:38:27 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.26 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:26 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 17/20] cnxk: replace term sanity Date: Wed, 29 May 2024 16:33:51 -0700 Message-ID: <20240529233811.663211-18-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Do not use non-inclusive naming. Signed-off-by: Stephen Hemminger --- drivers/common/cnxk/roc_nix_tm_ops.c | 2 +- drivers/common/cnxk/roc_npa.c | 4 ++-- drivers/net/cnxk/cnxk_ethdev.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/common/cnxk/roc_nix_tm_ops.c b/drivers/common/cnxk/roc_nix_tm_ops.c index 9f3870a311..6cf329eee2 100644 --- a/drivers/common/cnxk/roc_nix_tm_ops.c +++ b/drivers/common/cnxk/roc_nix_tm_ops.c @@ -528,7 +528,7 @@ roc_nix_tm_hierarchy_disable(struct roc_nix *roc_nix) node->flags &= ~NIX_TM_NODE_ENABLED; } - /* Verify sanity of all tx queues */ + /* Verify all tx queues */ for (i = 0; i < sq_cnt; i++) { sq = nix->sqs[i]; if (!sq) diff --git a/drivers/common/cnxk/roc_npa.c b/drivers/common/cnxk/roc_npa.c index 6c14c49901..5e38ecf041 100644 --- a/drivers/common/cnxk/roc_npa.c +++ b/drivers/common/cnxk/roc_npa.c @@ -458,7 +458,7 @@ npa_aura_pool_pair_alloc(struct npa_lf *lf, const uint32_t block_size, char name[PLT_MEMZONE_NAMESIZE]; const struct plt_memzone *mz; - /* Sanity check */ + /* argument checks */ if (!lf || !block_size || !block_count || !pool || !aura || !aura_handle) return NPA_ERR_PARAM; @@ -1096,7 +1096,7 @@ npa_dev_init(struct npa_lf *lf, uintptr_t base, struct mbox *mbox) uint8_t aura_sz; int rc; - /* Sanity checks */ + /* Input checks */ if (!lf || !base || !mbox) return NPA_ERR_PARAM; diff --git a/drivers/net/cnxk/cnxk_ethdev.c b/drivers/net/cnxk/cnxk_ethdev.c index 6b37bd877f..da9716c3c9 100644 --- a/drivers/net/cnxk/cnxk_ethdev.c +++ b/drivers/net/cnxk/cnxk_ethdev.c @@ -636,7 +636,7 @@ cnxk_nix_rx_queue_setup(struct rte_eth_dev *eth_dev, uint16_t qid, struct rte_mempool *lpb_pool = mp; struct rte_mempool *spb_pool = NULL; - /* Sanity checks */ + /* input checks */ if (rx_conf->rx_deferred_start == 1) { plt_err("Deferred Rx start is not supported"); goto fail; @@ -1205,7 +1205,7 @@ cnxk_nix_configure(struct rte_eth_dev *eth_dev) rc = -EINVAL; - /* Sanity checks */ + /* baseline checks */ if (rte_eal_has_hugepages() == 0) { plt_err("Huge page is not configured"); goto fail_configure; From patchwork Wed May 29 23:33:52 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140426 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 3B85944107; Thu, 30 May 2024 01:40:47 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id EAEFE410D5; Thu, 30 May 2024 01:39:27 +0200 (CEST) Received: from mail-pj1-f51.google.com (mail-pj1-f51.google.com [209.85.216.51]) by mails.dpdk.org (Postfix) with ESMTP id A4EC6402AC for ; Thu, 30 May 2024 01:38:28 +0200 (CEST) Received: by mail-pj1-f51.google.com with SMTP id 98e67ed59e1d1-2bdf11888a5so265630a91.0 for ; Wed, 29 May 2024 16:38:28 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025908; x=1717630708; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=pXZ1jnr5VPnVDLIXcjoC53MLyy/VOPz6DalPdmj8YQM=; b=xdZwV7bmwl2Vv1KoFdeRfEzrhfon17m+fyvCXI+6vc2R/87g3mFfLn9PaO7bmwqSB2 7VDhYu2Yu+YPGgEM01dekTopp4hc7A0IxOfKdMSY1xRivFINfXXcAIPN7UPPtTEXJK4k TxGi4O6gT/g1tzbm/cyikz/gB1pdmegP8VZDsLfaejdTA1XwEz2vksqtOA2rbVufUhHR lJeBPECRpVymQjD4hp7UlZUlL9JXE5rUGZ72K7iJr4h98RpZHM7y6UZoSd3TNnV2dqPZ FvQGEwz2Aa+g45Tdl5ftOq/j6spslxKyRssLSvbfBQ77pYxHf2KRwPaGuLamnbN852Sk 19aw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025908; x=1717630708; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=pXZ1jnr5VPnVDLIXcjoC53MLyy/VOPz6DalPdmj8YQM=; b=aFRHbAKTfwZOzH6vj1vXaubz7J8RUdvr0wfNuckuuPnVnS45uEJ8AS75NiNn8iu/oe I8pJs+9gIubQpEH3j0cDRdWfEZNA//vCGvfC/o5NtLDhRd29JKUTxqLotdhi98lNivzO sXU0UdSahnHllp35MbogfH92XRMgX++k7evpHOKSXDZloZpxKOVboXJLqQw2XahyPXZ7 Amq51mIHF58sGYiuB/jsjlOjM4AeAUjqimZct9GMG+Ae4RxlkvCeHS+aYRq+nDhjWV4/ mHX4tnc7UjK3+jNS2HZuLseyu374FEV3WXCOWwuFPXtfRaAPOgWYhkFDdpEuvyPANSy1 cg0w== X-Gm-Message-State: AOJu0YwaefnPk40wgz4fVd13l+uLNO04DCuJIGd5V9Rh3GZNTpi6l5K/ iWHTkPIXml6nMOSm4Efe8yOgHZYO5Z9xNfMsHDBO5LNz8/1GFrIbf+urn2wJE23oJKhBfHbqzqT / X-Google-Smtp-Source: AGHT+IFLEuZ2XolTl2TvCD66tXCgUabQB+ZndP4JN1AvndLsvp+rcvMSomcllc5Chwt+EBUBL7nQMQ== X-Received: by 2002:a17:90b:e89:b0:2c1:9e98:70bb with SMTP id 98e67ed59e1d1-2c1ab9d7a8emr611506a91.10.1717025907885; Wed, 29 May 2024 16:38:27 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.27 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:27 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 18/20] event/opdl: remove term sanity Date: Wed, 29 May 2024 16:33:52 -0700 Message-ID: <20240529233811.663211-19-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Don't use non-inclusive term. Signed-off-by: Stephen Hemminger --- drivers/event/opdl/opdl_evdev.c | 2 +- drivers/event/opdl/opdl_evdev_init.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/event/opdl/opdl_evdev.c b/drivers/event/opdl/opdl_evdev.c index b34a5fcacd..de9c560967 100644 --- a/drivers/event/opdl/opdl_evdev.c +++ b/drivers/event/opdl/opdl_evdev.c @@ -241,7 +241,7 @@ opdl_queue_setup(struct rte_eventdev *dev, struct opdl_evdev *device = opdl_pmd_priv(dev); - /* Extra sanity check, probably not needed */ + /* Extra check, probably not needed */ if (queue_id == OPDL_INVALID_QID) { PMD_DRV_LOG(ERR, "DEV_ID:[%02d] : " "Invalid queue id %u requested\n", diff --git a/drivers/event/opdl/opdl_evdev_init.c b/drivers/event/opdl/opdl_evdev_init.c index be3437fc2f..12eb2695f5 100644 --- a/drivers/event/opdl/opdl_evdev_init.c +++ b/drivers/event/opdl/opdl_evdev_init.c @@ -300,7 +300,7 @@ static int opdl_add_deps(struct opdl_evdev *device, struct opdl_queue *queue_deps = &device->queue[deps_q_id]; struct opdl_stage *dep_stages[OPDL_PORTS_MAX]; - /* sanity check that all stages are for same opdl ring */ + /* check that all stages are for same opdl ring */ for (i = 0; i < queue->nb_ports; i++) { struct opdl_ring *r = opdl_stage_get_opdl_ring(stage_for_port(queue, i)); From patchwork Wed May 29 23:33:53 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140427 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 1EDC044107; Thu, 30 May 2024 01:40:52 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 0F45B410E4; Thu, 30 May 2024 01:39:29 +0200 (CEST) Received: from mail-pf1-f176.google.com (mail-pf1-f176.google.com [209.85.210.176]) by mails.dpdk.org (Postfix) with ESMTP id 8355B40289 for ; Thu, 30 May 2024 01:38:29 +0200 (CEST) Received: by mail-pf1-f176.google.com with SMTP id d2e1a72fcca58-6f8ea3e9543so259412b3a.2 for ; Wed, 29 May 2024 16:38:29 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025909; x=1717630709; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Aek5gyQ2NOSqyZ8DWlL/4XfFOXERV7YZNOjg+oGrfKw=; b=HEPe+OuU+Kx0CcFcVG1AQQLPDsRA4uLoAtZuQAu7CVQFntd09i3+NBSLTniQZd6xVg GgPqs7lSMn+Fzr6r4ohvKfTL4BTHeC1cIgIygsoSyR83K8YTlibxOXjg42qyVs2Om6bL KtBH+zroCC5EI0biwd75yZXh9NXMn+dV+JW8Y1uY5n//aeKwMhOGTd1kZfiQucvbzVOe LccCFjTGeps1xeLV0BG2zaPS71wUC7Sr07PDaA8jaWvBVbPo725VW+OUSO9EdBIAhh0E jPZ+MSeasbfyg+rpo5TGjfJkxRjo4SAoRlK1mJu8td5dSCb3qglsNhA1YoHgdpHmwqnz dsNQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025909; x=1717630709; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Aek5gyQ2NOSqyZ8DWlL/4XfFOXERV7YZNOjg+oGrfKw=; b=k7NXHtSz/PS/iokhIgempEI0fIhQ6opo3spuVUgJ9hsekXISdCRnlZC69LOSQA1x8p EbF0G/ETOeX/+0luDXwOom1/cjmnWJafq6vvIe7DbkjyDlLOfWQ1gL0R3wumKPJRuW6p Eked0E6mTQP1Wxl2eaCxSK6jMUmp8Pc1j5pRw9UpSvSsnwW1nskvQ51IhTAFLnGXBWx5 Btqb5TizlNiS2dY/f+ApNpajy4YEaKI9I4VrU8Sn0d8AgBRyaUITnM+vwZ0WJQkPrqTa uzfc+G+1WHER2Ep70ZTBn834oewzdTyX+VqfJ87Uo0ke66eKUDm+V4im+WlRdUrwJEAY joqQ== X-Gm-Message-State: AOJu0YxKyZIZbftvRf1yyEwPrK23ZCfg2o1+dBNJ5QfRcrk6F/lORRIu sUt3dlKHizUaYT7VkRPEDnxdMfa6h18CCiVbje7Oh+2teHOKEAp7IaaWOckWFanFUtGyE0Jrzl/ z X-Google-Smtp-Source: AGHT+IGlXBCy+7UjSkxvifDqAlXko08wdDOHsaLLsYrLwhF/soV+BoqvITQWViyQILZfb+5C+XqRzg== X-Received: by 2002:a05:6a20:2454:b0:1af:a4cb:f6a with SMTP id adf61e73a8af0-1b264570ae5mr514708637.29.1717025908627; Wed, 29 May 2024 16:38:28 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:28 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger Subject: [PATCH v10 19/20] crypto/bcmfs: replace term sanity check Date: Wed, 29 May 2024 16:33:53 -0700 Message-ID: <20240529233811.663211-20-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Do not use non-inclusive naming here. Signed-off-by: Stephen Hemminger --- drivers/crypto/bcmfs/hw/bcmfs4_rm.c | 6 +++--- drivers/crypto/bcmfs/hw/bcmfs5_rm.c | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/crypto/bcmfs/hw/bcmfs4_rm.c b/drivers/crypto/bcmfs/hw/bcmfs4_rm.c index 9a30c654da..051bbea9cc 100644 --- a/drivers/crypto/bcmfs/hw/bcmfs4_rm.c +++ b/drivers/crypto/bcmfs/hw/bcmfs4_rm.c @@ -317,7 +317,7 @@ bcmfs4_mdst_desc(uint64_t addr, unsigned int length_div_16) } static bool -bcmfs4_sanity_check(struct bcmfs_qp_message *msg) +bcmfs4_message_check(struct bcmfs_qp_message *msg) { unsigned int i = 0; @@ -458,8 +458,8 @@ bcmfs4_enqueue_single_request_qp(struct bcmfs_qp *qp, void *op) struct bcmfs_queue *txq = &qp->tx_q; struct bcmfs_qp_message *msg = (struct bcmfs_qp_message *)op; - /* Do sanity check on message */ - if (!bcmfs4_sanity_check(msg)) { + /* Do check on message */ + if (!bcmfs4_message_check(msg)) { BCMFS_DP_LOG(ERR, "Invalid msg on queue %d", qp->qpair_id); return -EIO; } diff --git a/drivers/crypto/bcmfs/hw/bcmfs5_rm.c b/drivers/crypto/bcmfs/hw/bcmfs5_rm.c index cbfe42cb47..2df10a3028 100644 --- a/drivers/crypto/bcmfs/hw/bcmfs5_rm.c +++ b/drivers/crypto/bcmfs/hw/bcmfs5_rm.c @@ -293,7 +293,7 @@ bcmfs5_mdst_desc(uint64_t addr, unsigned int len_div_16) } static bool -bcmfs5_sanity_check(struct bcmfs_qp_message *msg) +bcmfs5_message_check(struct bcmfs_qp_message *msg) { unsigned int i = 0; @@ -389,8 +389,8 @@ bcmfs5_enqueue_single_request_qp(struct bcmfs_qp *qp, void *op) struct bcmfs_queue *txq = &qp->tx_q; struct bcmfs_qp_message *msg = (struct bcmfs_qp_message *)op; - /* Do sanity check on message */ - if (!bcmfs5_sanity_check(msg)) { + /* Do check on message */ + if (!bcmfs5_message_check(msg)) { BCMFS_DP_LOG(ERR, "Invalid msg on queue %d", qp->qpair_id); return -EIO; } From patchwork Wed May 29 23:33:54 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Hemminger X-Patchwork-Id: 140428 X-Patchwork-Delegate: thomas@monjalon.net Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 72F1344107; Thu, 30 May 2024 01:40:56 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 6D7AC410F1; Thu, 30 May 2024 01:39:30 +0200 (CEST) Received: from mail-pg1-f179.google.com (mail-pg1-f179.google.com [209.85.215.179]) by mails.dpdk.org (Postfix) with ESMTP id B34C640289 for ; Thu, 30 May 2024 01:38:30 +0200 (CEST) Received: by mail-pg1-f179.google.com with SMTP id 41be03b00d2f7-6bff93fac37so109552a12.1 for ; Wed, 29 May 2024 16:38:30 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=networkplumber-org.20230601.gappssmtp.com; s=20230601; t=1717025910; x=1717630710; darn=dpdk.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=yjPCCaIrbyMJeCKCNFxGPkB70SnTzDyi1EyG5Q5M4j4=; b=FBBMR/2w2+7WiMKCETpIiiKT9spovx9CLtCX9WCFhpXDhtDOnMX0wnBnXb/jIP+6MY Kc+Dth4yCeZHlpDW8wa72eNdROF9z4F0/Y3BZ3wo+sFc2Vhv2U9Xk+NaUOckQppTZtFE ZHVPNjjSfb6AOxv55r8kBRFvSVgMUDJrEyBYo1XsfaxSeqYO4bdeK2WDq6c1qph+U+d4 WBA3BXem2bcynTmNoY7EmpK8qIGxpBgr/el8qy4BJm1+FRHJki36xL07E/pL9YB9Thfy e+3qzadiyZgT1+XPEVe1N0fAZ7SeZpSAV/yKZIQ02fyHVDFlbzSjvW4Pum+UcOkZNrBR pYuw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717025910; x=1717630710; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=yjPCCaIrbyMJeCKCNFxGPkB70SnTzDyi1EyG5Q5M4j4=; b=udLZ3wpdnijg3gpEMQa0l1yno1JfA5PapJ0q9afDEMQN97FMO/CqmNCPpL6mOqRDsv e+q4SvCwi455+LXoY8MjBjqgAB9mKDGKZRR85WDs02usybnvMaSWOExxD/1kt3w4yP6C whkESjsl24/CIDIUZ9VG8MjeH1+OF85bLOHjnk1PNGy/+1UVhrq9bgauYTuvV8Y5UzHm NIJRyQdP5Ya/9Pv68bS1IC5tMCNGLWlUxLvXhX4GfObMk6N2RyhEXDTlen3hzIgDyGkX 9kIlERaFH35oHpD+BBln/DuhtbQIoST7eyND5xkjpDJCYaaxZh6dmU0Pkt3tTQ72W2n6 0uMQ== X-Gm-Message-State: AOJu0YzLUa+SMdvWo1H+QN7n8uJPXc4dfeQf+YROOM5/HnCiru6lpGDG gWZVTS5zUk0eRCPvaNlWmUMwGzYfp/7oGvNExFlOjGK2y4k8JmSd2+Aiu5WMoA9VsIrnS+DmdLH A X-Google-Smtp-Source: AGHT+IG7qzU8dum2ScLI3d58+jTRgwnXXwYHGjzt8Yoh/EztuU+Pm5XlydNA62sXQ18WE/Xcggys8w== X-Received: by 2002:a17:90b:270b:b0:2bd:92d9:65ee with SMTP id 98e67ed59e1d1-2c1abc4d0d4mr483664a91.45.1717025909344; Wed, 29 May 2024 16:38:29 -0700 (PDT) Received: from hermes.lan (204-195-96-226.wavecable.com. [204.195.96.226]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-2c1a7761d78sm353955a91.12.2024.05.29.16.38.28 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 29 May 2024 16:38:28 -0700 (PDT) From: Stephen Hemminger To: dev@dpdk.org Cc: Stephen Hemminger , Hemant Agrawal Subject: [PATCH v10 20/20] drivers: remove use of term sanity check Date: Wed, 29 May 2024 16:33:54 -0700 Message-ID: <20240529233811.663211-21-stephen@networkplumber.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240529233811.663211-1-stephen@networkplumber.org> References: <20240529233811.663211-1-stephen@networkplumber.org> MIME-Version: 1.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Replace non-inclusive language with better comments. Covers multiple drivers Signed-off-by: Stephen Hemminger Acked-by: Hemant Agrawal --- drivers/bus/fslmc/qbman/qbman_sys_decl.h | 2 +- drivers/common/cnxk/roc_npa.c | 2 +- drivers/common/dpaax/caamflib/desc.h | 2 +- drivers/common/sfc_efx/base/ef10_nvram.c | 4 ++-- drivers/common/sfc_efx/base/efx_rx.c | 2 +- drivers/dma/idxd/idxd_pci.c | 2 +- drivers/net/bonding/rte_eth_bond_8023ad.c | 2 +- drivers/net/mvpp2/mrvl_qos.c | 2 +- drivers/net/nfp/flower/nfp_flower_flow.c | 2 +- drivers/net/qede/qede_rxtx.c | 6 +++--- 10 files changed, 13 insertions(+), 13 deletions(-) diff --git a/drivers/bus/fslmc/qbman/qbman_sys_decl.h b/drivers/bus/fslmc/qbman/qbman_sys_decl.h index caaae41777..2b6162d0ce 100644 --- a/drivers/bus/fslmc/qbman/qbman_sys_decl.h +++ b/drivers/bus/fslmc/qbman/qbman_sys_decl.h @@ -9,7 +9,7 @@ #include #include -/* Sanity check */ +/* Byte order check */ #if (__BYTE_ORDER__ != __ORDER_BIG_ENDIAN__) && \ (__BYTE_ORDER__ != __ORDER_LITTLE_ENDIAN__) #error "Unknown endianness!" diff --git a/drivers/common/cnxk/roc_npa.c b/drivers/common/cnxk/roc_npa.c index 5e38ecf041..bd8ab1b395 100644 --- a/drivers/common/cnxk/roc_npa.c +++ b/drivers/common/cnxk/roc_npa.c @@ -622,7 +622,7 @@ npa_aura_alloc(struct npa_lf *lf, const uint32_t block_count, int pool_id, { int rc, aura_id; - /* Sanity check */ + /* parameter check */ if (!lf || !aura || !aura_handle) return NPA_ERR_PARAM; diff --git a/drivers/common/dpaax/caamflib/desc.h b/drivers/common/dpaax/caamflib/desc.h index 4a1285c4d4..37c87eebd5 100644 --- a/drivers/common/dpaax/caamflib/desc.h +++ b/drivers/common/dpaax/caamflib/desc.h @@ -107,7 +107,7 @@ extern enum rta_sec_era rta_sec_era; /* * ONE - should always be set. Combination of ONE (always - * set) and ZRO (always clear) forms an endianness sanity check + * set) and ZRO (always clear) forms an endianness check */ #define HDR_ONE BIT(23) #define HDR_ZRO BIT(15) diff --git a/drivers/common/sfc_efx/base/ef10_nvram.c b/drivers/common/sfc_efx/base/ef10_nvram.c index ce8357fa94..fad9f0f507 100644 --- a/drivers/common/sfc_efx/base/ef10_nvram.c +++ b/drivers/common/sfc_efx/base/ef10_nvram.c @@ -595,13 +595,13 @@ tlv_update_partition_len_and_cks( /* * We just modified the partition, so the total length may not be - * valid. Don't use tlv_find(), which performs some sanity checks + * valid. Don't use tlv_find(), which performs some checks * that may fail here. */ partition.data = cursor->block; memcpy(&partition.tlv_cursor, cursor, sizeof (*cursor)); header = (struct tlv_partition_header *)partition.data; - /* Sanity check. */ + /* Header check */ if (__LE_TO_CPU_32(header->tag) != TLV_TAG_PARTITION_HEADER) { rc = EFAULT; goto fail1; diff --git a/drivers/common/sfc_efx/base/efx_rx.c b/drivers/common/sfc_efx/base/efx_rx.c index dce9ada55d..28676c5a5b 100644 --- a/drivers/common/sfc_efx/base/efx_rx.c +++ b/drivers/common/sfc_efx/base/efx_rx.c @@ -930,7 +930,7 @@ efx_rx_qcreate_internal( ndescs, id, flags, eep, erp)) != 0) goto fail4; - /* Sanity check queue creation result */ + /* Check queue creation result */ if (flags & EFX_RXQ_FLAG_RSS_HASH) { const efx_rx_prefix_layout_t *erplp = &erp->er_prefix_layout; const efx_rx_prefix_field_info_t *rss_hash_field; diff --git a/drivers/dma/idxd/idxd_pci.c b/drivers/dma/idxd/idxd_pci.c index 81637d9420..b60b233a1d 100644 --- a/drivers/dma/idxd/idxd_pci.c +++ b/drivers/dma/idxd/idxd_pci.c @@ -205,7 +205,7 @@ init_pci_device(struct rte_pci_device *dev, struct idxd_dmadev *idxd, goto err; } - /* sanity check device status */ + /* check device status */ if (pci->regs->gensts & GENSTS_DEV_STATE_MASK) { /* need function-level-reset (FLR) or is enabled */ IDXD_PMD_ERR("Device status is not disabled, cannot init"); diff --git a/drivers/net/bonding/rte_eth_bond_8023ad.c b/drivers/net/bonding/rte_eth_bond_8023ad.c index 79f1b3f1a0..57a67bd029 100644 --- a/drivers/net/bonding/rte_eth_bond_8023ad.c +++ b/drivers/net/bonding/rte_eth_bond_8023ad.c @@ -1476,7 +1476,7 @@ bond_8023ad_setup_validate(uint16_t port_id, return -EINVAL; if (conf != NULL) { - /* Basic sanity check */ + /* Basic input check */ if (conf->slow_periodic_ms == 0 || conf->fast_periodic_ms >= conf->slow_periodic_ms || conf->long_timeout_ms == 0 || diff --git a/drivers/net/mvpp2/mrvl_qos.c b/drivers/net/mvpp2/mrvl_qos.c index f43217bc58..db5052a9ab 100644 --- a/drivers/net/mvpp2/mrvl_qos.c +++ b/drivers/net/mvpp2/mrvl_qos.c @@ -260,7 +260,7 @@ get_entry_values(const char *entry, uint8_t *tab, if (nb_rng_tokens != 2) return -3; - /* Range and sanity checks. */ + /* Range and input checks. */ if (get_val_securely(rng_tokens[0], &token_val) < 0) return -4; beg = (char)token_val; diff --git a/drivers/net/nfp/flower/nfp_flower_flow.c b/drivers/net/nfp/flower/nfp_flower_flow.c index 26ee92019c..f6c2a61c74 100644 --- a/drivers/net/nfp/flower/nfp_flower_flow.c +++ b/drivers/net/nfp/flower/nfp_flower_flow.c @@ -2079,7 +2079,7 @@ nfp_flow_compile_item_proc(struct nfp_flower_representor *repr, break; } - /* Perform basic sanity checks */ + /* Perform basic checks */ ret = nfp_flow_item_check(item, proc); if (ret != 0) { PMD_DRV_LOG(ERR, "nfp flow item %d check failed", item->type); diff --git a/drivers/net/qede/qede_rxtx.c b/drivers/net/qede/qede_rxtx.c index ede5fc83e3..606c144bd0 100644 --- a/drivers/net/qede/qede_rxtx.c +++ b/drivers/net/qede/qede_rxtx.c @@ -1383,7 +1383,7 @@ qede_rx_process_tpa_end_cqe(struct qede_dev *qdev, cqe->len_list[0]); /* Update total length and frags based on end TPA */ rx_mb = rxq->tpa_info[cqe->tpa_agg_index].tpa_head; - /* TODO: Add Sanity Checks */ + /* TODO: Add more checks */ rx_mb->nb_segs = cqe->num_of_bds; rx_mb->pkt_len = cqe->total_packet_len; @@ -2211,7 +2211,7 @@ qede_xmit_prep_pkts(__rte_unused void *p_txq, struct rte_mbuf **tx_pkts, #ifdef RTE_LIBRTE_QEDE_DEBUG_TX static inline void -qede_mpls_tunn_tx_sanity_check(struct rte_mbuf *mbuf, +qede_mpls_tunn_tx_basic_check(struct rte_mbuf *mbuf, struct qede_tx_queue *txq) { if (((mbuf->outer_l2_len + mbuf->outer_l3_len) / 2) > 0xff) @@ -2473,7 +2473,7 @@ qede_xmit_pkts(void *p_txq, struct rte_mbuf **tx_pkts, uint16_t nb_pkts) RTE_MBUF_F_TX_TUNNEL_MPLSINUDP) { mplsoudp_flg = true; #ifdef RTE_LIBRTE_QEDE_DEBUG_TX - qede_mpls_tunn_tx_sanity_check(mbuf, txq); + qede_mpls_tunn_tx_basic_check(mbuf, txq); #endif /* Outer L4 offset in two byte words */ tunn_l4_hdr_start_offset =