]> git.karo-electronics.de Git - karo-tx-linux.git/commit
checkpatch: optimise statement scanner when mid-statement
authorAndy Whitcroft <apw@canonical.com>
Fri, 16 Dec 2011 04:50:18 +0000 (15:50 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 21 Dec 2011 06:01:25 +0000 (17:01 +1100)
commite99c1376e40229530c2f99006e653cd0ffa4d197
tree003b1d9a07430e30e945b321c54e3fedfa4fe746
parent8c16338d51070c340eeef8973939c0f36ffb1910
checkpatch: optimise statement scanner when mid-statement

In the middle of a long definition or similar, there is no possibility of
finding a smaller sub-statement.  Optimise this case by skipping statement
aquirey where there are no starts of statement (open brace '{' or
semi-colon ';').  We are likely to scan slightly more than needed still
but this is safest.

Signed-off-by: Andy Whitcroft <apw@canonical.com>
Cc: Joe Perches <joe@perches.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
scripts/checkpatch.pl