X-Git-Url: http://git.cascardo.eti.br/?a=blobdiff_plain;f=scripts%2Fcheckpatch.pl;h=b0aa2c680593d0c09857b9447d54ef933861ed3b;hb=121782a248f11c63c7c0fc78d4a68a54e99ee37d;hp=8657f99bfb2b7d171df283d82092cba96731fcbd;hpb=82b88bb24e28dd4fb4bec30e75412f41326130f0;p=cascardo%2Flinux.git diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 8657f99bfb2b..b0aa2c680593 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -1943,6 +1943,11 @@ sub process { WARN("LINUX_VERSION_CODE should be avoided, code should be for the version to which it is merged\n" . $herecurr); } +# check for uses of printk_ratelimit + if ($line =~ /\bprintk_ratelimit\s*\(/) { + WARN("Prefer printk_ratelimited or pr__ratelimited to printk_ratelimit\n" . $herecurr); + } + # printk should use KERN_* levels. Note that follow on printk's on the # same line do not need a level, so we use the current block context # to try and find and validate the current printk. In summary the current