]> git.kernelconcepts.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>
Tue, 13 Dec 2011 06:43:21 +0000 (17:43 +1100)
commitc6125ca27f2802c1095d561e2a7a00d09d112ab5
tree4530be5a4c079e5b174b69ca52b6371e96e9f3f7
parent1ddd6f1eb8a1fdca0dc70a315138d77e87ec0f82
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