[<prev] [next>] [day] [month] [year] [list]
Message-ID: <0753cae7829b98998ac3f5f9fcb52ba1f2475ee1.camel@perches.com>
Date: Mon, 23 Jul 2018 14:28:00 -0700
From: Joe Perches <joe@...ches.com>
To: LKML <linux-kernel@...r.kernel.org>
Subject: [RFC PATCH] checkpatch: Discourage use with --f/--file outside of
drivers/staging ?
Perhaps some patch like this could help reduce the
number of ill-considered checkpatch submissions
for files outside of drivers/staging/
Concept and message wordsmithing appreciated...
---
scripts/checkpatch.pl | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl
index 34e4683de7a3..1a93421d5b1d 100755
--- a/scripts/checkpatch.pl
+++ b/scripts/checkpatch.pl
@@ -2483,6 +2483,10 @@ sub process {
WARN("OBSOLETE",
"$realfile is marked as 'obsolete' in the MAINTAINERS hierarchy. No unnecessary modifications please.\n");
}
+ if ($file && $filename !~ m@...ivers/staging/@) {
+ WARN("CHECKPATCH_FILE",
+ "Using -f/--file with '$realfile' may not be appropriate.\n");
+ }
if ($realfile =~ m@^(?:drivers/net/|net/|drivers/staging/)@) {
$check = 1;
} else {
Powered by blists - more mailing lists