diff options
Diffstat (limited to 'drivers/macintosh/via-pmu.c')
-rw-r--r-- | drivers/macintosh/via-pmu.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/drivers/macintosh/via-pmu.c b/drivers/macintosh/via-pmu.c index d6dabee55f2f..79c7b44a94ee 100644 --- a/drivers/macintosh/via-pmu.c +++ b/drivers/macintosh/via-pmu.c | |||
@@ -298,7 +298,7 @@ static struct backlight_controller pmu_backlight_controller = { | |||
298 | 298 | ||
299 | int __init find_via_pmu(void) | 299 | int __init find_via_pmu(void) |
300 | { | 300 | { |
301 | phys_addr_t taddr; | 301 | u64 taddr; |
302 | u32 *reg; | 302 | u32 *reg; |
303 | 303 | ||
304 | if (via != 0) | 304 | if (via != 0) |
@@ -337,7 +337,7 @@ int __init find_via_pmu(void) | |||
337 | else if (device_is_compatible(vias->parent, "Keylargo") | 337 | else if (device_is_compatible(vias->parent, "Keylargo") |
338 | || device_is_compatible(vias->parent, "K2-Keylargo")) { | 338 | || device_is_compatible(vias->parent, "K2-Keylargo")) { |
339 | struct device_node *gpiop; | 339 | struct device_node *gpiop; |
340 | phys_addr_t gaddr = 0; | 340 | u64 gaddr = OF_BAD_ADDR; |
341 | 341 | ||
342 | pmu_kind = PMU_KEYLARGO_BASED; | 342 | pmu_kind = PMU_KEYLARGO_BASED; |
343 | pmu_has_adb = (find_type_devices("adb") != NULL); | 343 | pmu_has_adb = (find_type_devices("adb") != NULL); |
@@ -352,7 +352,7 @@ int __init find_via_pmu(void) | |||
352 | reg = (u32 *)get_property(gpiop, "reg", NULL); | 352 | reg = (u32 *)get_property(gpiop, "reg", NULL); |
353 | if (reg) | 353 | if (reg) |
354 | gaddr = of_translate_address(gpiop, reg); | 354 | gaddr = of_translate_address(gpiop, reg); |
355 | if (gaddr != 0) | 355 | if (gaddr != OF_BAD_ADDR) |
356 | gpio_reg = ioremap(gaddr, 0x10); | 356 | gpio_reg = ioremap(gaddr, 0x10); |
357 | } | 357 | } |
358 | if (gpio_reg == NULL) | 358 | if (gpio_reg == NULL) |
@@ -479,9 +479,6 @@ static int __init via_pmu_dev_init(void) | |||
479 | if (vias == NULL) | 479 | if (vias == NULL) |
480 | return -ENODEV; | 480 | return -ENODEV; |
481 | 481 | ||
482 | #ifndef CONFIG_PPC64 | ||
483 | request_OF_resource(vias, 0, NULL); | ||
484 | #endif | ||
485 | #ifdef CONFIG_PMAC_BACKLIGHT | 482 | #ifdef CONFIG_PMAC_BACKLIGHT |
486 | /* Enable backlight */ | 483 | /* Enable backlight */ |
487 | register_backlight_controller(&pmu_backlight_controller, NULL, "pmu"); | 484 | register_backlight_controller(&pmu_backlight_controller, NULL, "pmu"); |