]> git.karo-electronics.de Git - karo-tx-linux.git/commit
checkpatch: fix 'return is not a function' square bracket handling
authorAndy Whitcroft <apw@canonical.com>
Fri, 16 Dec 2011 04:50:19 +0000 (15:50 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Wed, 21 Dec 2011 06:01:27 +0000 (17:01 +1100)
commit5369a1f4b2939e00fca9bd191773bb386f52dd3b
tree9491a6abbe5c6168c49ad4bd5d216a74526a10be
parent77daac1e4773aa8808a1f694cbae0f318fa559af
checkpatch: fix 'return is not a function' square bracket handling

We are incorrectly matching square brackets '[' and ']' leading to false
positives on more complex functions as below:

    return (dt3155_fbuffer[m]->ready_head -
dt3155_fbuffer[m]->ready_len +
dt3155_fbuffer[m]->nbuffers)%
(dt3155_fbuffer[m]->nbuffers);

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