powerpc/macio: Don't the address of an array element before boundchecking
authorroel kluin <roel.kluin@gmail.com>
Mon, 3 Aug 2009 02:41:42 +0000 (02:41 +0000)
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>
Thu, 20 Aug 2009 00:29:26 +0000 (10:29 +1000)
commitfb2881a7134576a6e95a63e3d2f34ea5629db4a1
tree98ec36788b126a30f56fcac57196d4e29fe7e72f
parent14ea58ad797e4e9b7be755aca0fd3925d0713ede
powerpc/macio: Don't the address of an array element before boundchecking

Check whether index is within bounds before grabbing the element.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
drivers/macintosh/macio_asic.c