DPDK patches and discussions
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: dev@dpdk.org
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	Jerin Jacob <jerinj@marvell.com>,
	Kiran Kumar K <kirankumark@marvell.com>,
	Nithin Dabilpuram <ndabilpuram@marvell.com>,
	Zhirun Yan <yanzhirun_163@163.com>,
	Reshma Pattan <reshma.pattan@intel.com>
Subject: [PATCH v12 09/10] lib: replace use of sanity check in comments and
Date: Wed,  2 Apr 2025 16:23:19 -0700	[thread overview]
Message-ID: <20250402232441.440346-10-stephen@networkplumber.org> (raw)
In-Reply-To: <20250402232441.440346-1-stephen@networkplumber.org>

Sanity check is on the Tier 2 non-inclusive list.
Replace or remove it.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 lib/eal/linux/eal_timer.c   | 2 +-
 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 +-
 7 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/lib/eal/linux/eal_timer.c b/lib/eal/linux/eal_timer.c
index 489732c116..92514af9f5 100644
--- a/lib/eal/linux/eal_timer.c
+++ b/lib/eal/linux/eal_timer.c
@@ -247,7 +247,7 @@ get_tsc_freq(uint64_t arch_hz)
 		tsc_hz = (uint64_t)((end - start)/secs);
 
 		if (arch_hz) {
-			/* Make sure we're within 1% for sanity check */
+			/* Make sure we're within 1% */
 			if (RTE_MAX(arch_hz, tsc_hz) - RTE_MIN(arch_hz, tsc_hz) > arch_hz / 100)
 				return arch_hz;
 
diff --git a/lib/graph/graph.c b/lib/graph/graph.c
index dff8e690a8..3e76e8f789 100644
--- a/lib/graph/graph.c
+++ b/lib/graph/graph.c
@@ -389,7 +389,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 0bbbd9fb7c..4eaf03db69 100644
--- a/lib/graph/graph_stats.c
+++ b/lib/graph/graph_stats.c
@@ -385,7 +385,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 63db629da8..a9a7fffbd9 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 16485b27cb..ec12606291 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_pkt_len(m))) {
-- 
2.47.2


  parent reply	other threads:[~2025-04-02 23:25 UTC|newest]

Thread overview: 46+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-05-29 23:33 [PATCH v10 00/20] Remove use of noninclusive term sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 01/20] mbuf: replace term sanity check Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 02/20] eal: replace use of sanity check in comments and messages Stephen Hemminger
2024-06-06  5:38   ` Morten Brørup
2024-05-29 23:33 ` [PATCH v10 03/20] test: replace use word sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 04/20] examples: remove term sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 05/20] lib: replace use of sanity check in comments and messages Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 06/20] doc/eventdev_pipeline: remove sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 07/20] net/ring: replace use of sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 08/20] net/fm10k, net/ixgbe: remove word sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 09/20] net/mlx[45]: " Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 10/20] net/sfc: remove term "sanity check" Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 11/20] net/ark: replace use of term sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 12/20] net/bnxt: " Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 13/20] net/bnx2x: remove reference to sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 14/20] net/nfp: replace use of term sanity Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 15/20] net/txgbe: replace " Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 16/20] net/cxgbe: remove use of " Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 17/20] cnxk: replace " Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 18/20] event/opdl: remove " Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 19/20] crypto/bcmfs: replace term sanity check Stephen Hemminger
2024-05-29 23:33 ` [PATCH v10 20/20] drivers: remove use of " Stephen Hemminger
2024-08-01 15:46 ` [PATCH v11 0/7] Remove usage of wording " Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 1/7] mbuf: replace term " Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 2/7] eal: replace use of sanity check in comments and messages Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 3/7] test: replace use word sanity Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 4/7] examples: remove term sanity Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 5/7] lib: replace use of sanity check in comments and messages Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 6/7] doc: remove sanity Stephen Hemminger
2024-08-01 15:46   ` [PATCH v11 7/7] drivers: remove use of term sanity check Stephen Hemminger
2025-04-02 23:23 ` [PATCH v12 00/10] replace " Stephen Hemminger
2025-04-02 23:23   ` [PATCH v12 01/10] mbuf: replace " Stephen Hemminger
2025-04-02 23:23   ` [PATCH v12 02/10] net/avp: replace use of rte_mbuf_sanity_check Stephen Hemminger
2025-04-02 23:23   ` [PATCH v12 03/10] net/sfc: " Stephen Hemminger
2025-04-04  7:37     ` Andrew Rybchenko
2025-04-02 23:23   ` [PATCH v12 04/10] examples: remove term sanity Stephen Hemminger
2025-04-02 23:23   ` [PATCH v12 05/10] eal: replace use of sanity check in comments and messages Stephen Hemminger
2025-04-02 23:23   ` [PATCH v12 06/10] test: replace use word sanity Stephen Hemminger
2025-04-02 23:23   ` [PATCH v12 07/10] dts: replace use of sanity check in comment Stephen Hemminger
2025-04-03  1:21     ` Patrick Robb
2025-04-03  9:44     ` Luca Vizzarro
2025-04-02 23:23   ` [PATCH v12 08/10] doc: remove sanity Stephen Hemminger
2025-04-02 23:23   ` Stephen Hemminger [this message]
2025-04-02 23:23   ` [PATCH v12 10/10] drivers: remove use of term sanity check Stephen Hemminger
2025-04-04  7:39     ` Andrew Rybchenko
2025-04-03 18:59   ` [PATCH v12 00/10] replace " Patrick Robb

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20250402232441.440346-10-stephen@networkplumber.org \
    --to=stephen@networkplumber.org \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=kirankumark@marvell.com \
    --cc=ndabilpuram@marvell.com \
    --cc=reshma.pattan@intel.com \
    --cc=yanzhirun_163@163.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).