]> git.baikalelectronics.ru Git - kernel.git/commit
checkpatch: improve SUSPECT_CODE_INDENT test
authorJoe Perches <joe@perches.com>
Wed, 9 Sep 2015 22:37:30 +0000 (15:37 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Thu, 10 Sep 2015 20:29:01 +0000 (13:29 -0700)
commit98a03dfcfcf5e4c1aaff899e2750d5cdad941814
treea4c8826093272ba4bc1b28f84aa8b83024314129
parent58042742cc2a7d50ca28d3a60af223b4890091a6
checkpatch: improve SUSPECT_CODE_INDENT test

Many lines exist like

if (foo)
bar;

where the tabbed indentation of the branch is not one more than the "if"
line above it.

checkpatch should emit a warning on those lines.

Miscellenea:

o Remove comments from branch blocks
o Skip blank lines in block

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
scripts/checkpatch.pl