diff options
author | Paul Mackerras <paulus@samba.org> | 2007-10-03 05:33:17 (GMT) |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2007-10-03 05:33:17 (GMT) |
commit | 70f227d8846a8a9b1f36f71c42e11cc7c6e9408d (patch) | |
tree | fb4dd5c8240bdaada819fb569c01a392b52847b9 /arch/sparc64/kernel/ebus.c | |
parent | a0c7ce9c877ceef8428798ac91fb794f83609aed (diff) | |
parent | f778089cb2445dfc6dfd30a7a567925fd8589f1e (diff) | |
download | linux-70f227d8846a8a9b1f36f71c42e11cc7c6e9408d.tar.xz |
Merge branch 'linux-2.6' into for-2.6.24
Diffstat (limited to 'arch/sparc64/kernel/ebus.c')
-rw-r--r-- | arch/sparc64/kernel/ebus.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/sparc64/kernel/ebus.c b/arch/sparc64/kernel/ebus.c index bc9ae36..04ab81c 100644 --- a/arch/sparc64/kernel/ebus.c +++ b/arch/sparc64/kernel/ebus.c @@ -375,7 +375,10 @@ static void __init fill_ebus_device(struct device_node *dp, struct linux_ebus_de dev->num_addrs = 0; dev->num_irqs = 0; } else { - (void) of_get_property(dp, "reg", &len); + const int *regs = of_get_property(dp, "reg", &len); + + if (!regs) + len = 0; dev->num_addrs = len / sizeof(struct linux_prom_registers); for (i = 0; i < dev->num_addrs; i++) |