diff options
-rw-r--r-- | arch/powerpc/sysdev/qe_lib/qe_ic.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/arch/powerpc/sysdev/qe_lib/qe_ic.c b/arch/powerpc/sysdev/qe_lib/qe_ic.c index f59444d3be75..c11b313f015b 100644 --- a/arch/powerpc/sysdev/qe_lib/qe_ic.c +++ b/arch/powerpc/sysdev/qe_lib/qe_ic.c | |||
@@ -329,6 +329,10 @@ void __init qe_ic_init(struct device_node *node, unsigned int flags, | |||
329 | struct resource res; | 329 | struct resource res; |
330 | u32 temp = 0, ret, high_active = 0; | 330 | u32 temp = 0, ret, high_active = 0; |
331 | 331 | ||
332 | ret = of_address_to_resource(node, 0, &res); | ||
333 | if (ret) | ||
334 | return; | ||
335 | |||
332 | qe_ic = alloc_bootmem(sizeof(struct qe_ic)); | 336 | qe_ic = alloc_bootmem(sizeof(struct qe_ic)); |
333 | if (qe_ic == NULL) | 337 | if (qe_ic == NULL) |
334 | return; | 338 | return; |
@@ -342,10 +346,6 @@ void __init qe_ic_init(struct device_node *node, unsigned int flags, | |||
342 | return; | 346 | return; |
343 | } | 347 | } |
344 | 348 | ||
345 | ret = of_address_to_resource(node, 0, &res); | ||
346 | if (ret) | ||
347 | return; | ||
348 | |||
349 | qe_ic->regs = ioremap(res.start, res.end - res.start + 1); | 349 | qe_ic->regs = ioremap(res.start, res.end - res.start + 1); |
350 | 350 | ||
351 | qe_ic->irqhost->host_data = qe_ic; | 351 | qe_ic->irqhost->host_data = qe_ic; |