mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH v2] checkpatch: really skip LONG_LINE_* when LONG_LINE is ignored
@ 2024-06-10 15:02 Wolfram Sang
  2024-06-10 17:25 ` Joe Perches
  0 siblings, 1 reply; 2+ messages in thread
From: Wolfram Sang @ 2024-06-10 15:02 UTC (permalink / raw)
  To: linux-renesas-soc
  Cc: Wolfram Sang, Andy Whitcroft, Joe Perches, Dwaipayan Ray,
	Lukas Bulwahn, Andrew Morton, linux-kernel

For a printout to happen, all types must be set to "show". So, AND is needed
for the flags, not OR, if we want to ignore something.

Fixes: 47e0c88b37a5 ("checkpatch: categorize some long line length checks")
Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
---

Change since v1:
* removed now unneeded pair of braces (Thanks, Geert!)
* reworded commit message

 scripts/checkpatch.pl | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 2b812210b412..375749e0a174 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -3858,7 +3858,7 @@ sub process {
 			}
 
 			if ($msg_type ne "" &&
-			    (show_type("LONG_LINE") || show_type($msg_type))) {
+			    show_type("LONG_LINE") && show_type($msg_type)) {
 				my $msg_level = \&WARN;
 				$msg_level = \&CHK if ($file);
 				&{$msg_level}($msg_type,
-- 
2.43.0


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2024-06-10 17:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-06-10 15:02 [PATCH v2] checkpatch: really skip LONG_LINE_* when LONG_LINE is ignored Wolfram Sang
2024-06-10 17:25 ` Joe Perches

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®