diff options
author | David Rientjes <rientjes@google.com> | 2014-01-23 15:54:42 -0800 |
---|---|---|
committer | Stepan Moskovchenko <stepanm@codeaurora.org> | 2014-10-10 15:45:27 -0700 |
commit | 38a63dbc7d56f077d9beba58717444452694e745 (patch) | |
tree | b0dd4d71b9b938784cb03e2aebec630f4698f9fe /scripts | |
parent | 9d83098afd2453c7a10fd61124eb6632ed90af6d (diff) | |
download | qcom-msm-v3.10-38a63dbc7d56f077d9beba58717444452694e745.tar.gz |
checkpatch: add warning of future __GFP_NOFAIL use
gfp.h and page_alloc.c already specify that __GFP_NOFAIL is deprecated and
no new users should be added.
Add a warning to checkpatch to catch this.
Signed-off-by: David Rientjes <rientjes@google.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Git-commit: 7e4915e78992ebd3cc031051dc23063bbf29e749
Git-repo: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/checkpatch.pl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 8efce590d4b..9bb4a421a8d 100755 --- a/scripts/checkpatch.pl +++ b/scripts/checkpatch.pl @@ -4113,6 +4113,12 @@ sub process { "$1 uses number as first arg, sizeof is generally wrong\n" . $herecurr); } +# check for GFP_NOWAIT use + if ($line =~ /\b__GFP_NOFAIL\b/) { + WARN("__GFP_NOFAIL", + "Use of __GFP_NOFAIL is deprecated, no new users should be added\n" . $herecurr); + } + # check for multiple semicolons if ($line =~ /;\s*;\s*$/) { if (WARN("ONE_SEMICOLON", |