mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jim Cromie <jim.cromie@gmail.com>
To: linux-kernel@vger.kernel.org
Cc: Jim Cromie <jim.cromie@gmail.com>
Subject: [RFC PATCH 0/2] practical auto-QA de-noiser or -E_TOO_UGLY ?
Date: Wed, 15 Oct 2025 11:51:35 -0600	[thread overview]
Message-ID: <20251015175137.2178263-1-jim.cromie@gmail.com> (raw)

Can I haz (in compiler.h)

  #define __no_side_effects(...)    /* checkpatch hint only */

module_param_named() if submitted now, would draw several warnings
from checkpatch --strict, on name, value (but not type).

  CHECK: Macro argument reuse '_var' - possible side-effects?

This macro allows an author to suppress that complaint, clearly and
declaratively, and strongly suggests that they used --strict, saw the
complaint, and silenced it.  So they know not to pass i++.

Do the possible QA/CI benefits suffice for the mild "hackish" flavor ?


Jim Cromie (2):
  checkpatch: add __no_side_effects() hint/assertion macro
  checkpatch: cosmetic-style tweak

 include/linux/compiler.h | 12 +++++++++
 scripts/checkpatch.pl    | 54 ++++++++++++++++++++++++++++++++++------
 2 files changed, 59 insertions(+), 7 deletions(-)

-- 
2.51.0


             reply	other threads:[~2025-10-15 17:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-15 17:51 Jim Cromie [this message]
2025-10-15 17:51 ` [RFC PATCH 1/2] checkpatch: add __no_side_effects() hint/assertion macro Jim Cromie
2025-10-15 17:51 ` [RFC PATCH 2/2] checkpatch: cosmetic-style tweak Jim Cromie
2025-10-16 15:54   ` Joe Perches

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=20251015175137.2178263-1-jim.cromie@gmail.com \
    --to=jim.cromie@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    /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

all inboxes | Powered by JetHome®