From: Scott Wood Date: Fri, 19 Dec 2008 10:13:09 +0000 (+0000) Subject: powerpc/bootwrapper: Use the child-bus #address-cells to decide which range entry... X-Git-Tag: v2.6.29-rc1~574^2~26 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=49e6e3f1aec2d46f5865d3ada38fe9a5d660ef5d;p=linux-2.6-omap-h63xx.git powerpc/bootwrapper: Use the child-bus #address-cells to decide which range entry to use The correct #address-cells was still used for the actual translation, so the impact is only a possibility of choosing the wrong range entry or failing to find any match. Most common cases were not affected. Signed-off-by: Scott Wood Signed-off-by: Paul Mackerras --- diff --git a/arch/powerpc/boot/devtree.c b/arch/powerpc/boot/devtree.c index 5d12336dc36..a7e21a35c03 100644 --- a/arch/powerpc/boot/devtree.c +++ b/arch/powerpc/boot/devtree.c @@ -213,7 +213,7 @@ static int find_range(u32 *reg, u32 *ranges, int nregaddr, u32 range_addr[MAX_ADDR_CELLS]; u32 range_size[MAX_ADDR_CELLS]; - copy_val(range_addr, ranges + i, naddr); + copy_val(range_addr, ranges + i, nregaddr); copy_val(range_size, ranges + i + nregaddr + naddr, nsize); if (compare_reg(reg, range_addr, range_size))