]> 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>
Thu, 8 Dec 2011 04:42:24 +0000 (15:42 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Mon, 12 Dec 2011 04:19:06 +0000 (15:19 +1100)
commit6d0b710f3eac080dbbc766ea65578f7507f2761b
tree106ecda577eb411d11cf8837ddeaac7d7886319f
parent3b138916885b0cbb62cb921631540ee2429ccc3e
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