From 765b59fc245e49285a26e8cd5b96f61c48ddeeb9 Mon Sep 17 00:00:00 2001 From: Kees Cook Date: Mon, 17 Dec 2012 16:01:48 -0800 Subject: [PATCH] --- yaml --- r: 346415 b: refs/heads/master c: 1ba8dfd17ead04de18bfca7b68c2a144c8be736a h: refs/heads/master i: 346413: 6a919bb284629909bd377e6dfdc5bc5ea8b61814 346411: 8178cf7563c69181e1114a2be7479b7d7dd04e67 346407: 6f73472e84f702f06f58af70a9c01bfc28b2ce1d 346399: 431020ff488b1d9219afdf57f2b2b7e97a510c01 v: v3 --- [refs] | 2 +- trunk/scripts/checkpatch.pl | 13 +++++++++++++ 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/[refs] b/[refs] index 0fb1efae7f9e..40387c9d84ec 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 5023d3472d444747bfa12e9798d7993e7efb8287 +refs/heads/master: 1ba8dfd17ead04de18bfca7b68c2a144c8be736a diff --git a/trunk/scripts/checkpatch.pl b/trunk/scripts/checkpatch.pl index d4f61a6fed5d..cd251d5f3f1a 100755 --- a/trunk/scripts/checkpatch.pl +++ b/trunk/scripts/checkpatch.pl @@ -1757,6 +1757,13 @@ sub process { #print "is_start<$is_start> is_end<$is_end> length<$length>\n"; } +# discourage the addition of CONFIG_EXPERIMENTAL in Kconfig. + if ($realfile =~ /Kconfig/ && + $line =~ /.\s*depends on\s+.*\bEXPERIMENTAL\b/) { + WARN("CONFIG_EXPERIMENTAL", + "Use of CONFIG_EXPERIMENTAL is deprecated. For alternatives, see https://lkml.org/lkml/2012/10/23/580\n"); + } + if (($realfile =~ /Makefile.*/ || $realfile =~ /Kbuild.*/) && ($line =~ /\+(EXTRA_[A-Z]+FLAGS).*/)) { my $flag = $1; @@ -1912,6 +1919,12 @@ sub process { # check we are in a valid C source file if not then ignore this hunk next if ($realfile !~ /\.(h|c)$/); +# discourage the addition of CONFIG_EXPERIMENTAL in #if(def). + if ($line =~ /^\+\s*\#\s*if.*\bCONFIG_EXPERIMENTAL\b/) { + WARN("CONFIG_EXPERIMENTAL", + "Use of CONFIG_EXPERIMENTAL is deprecated. For alternatives, see https://lkml.org/lkml/2012/10/23/580\n"); + } + # check for RCS/CVS revision markers if ($rawline =~ /^\+.*\$(Revision|Log|Id)(?:\$|)/) { WARN("CVS_KEYWORD",