aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/ide
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2005-11-07 00:57:33 -0500
committerPaul Mackerras <paulus@samba.org>2005-11-07 19:19:51 -0500
commit42596ec5edc8efb9e24397ef656df7ebb2c4f8d5 (patch)
treeef58c24c27589f9d157d26be71129b7f8aecc5f5 /drivers/ide
parent7b007de8a90604000329154e87d269db3427d099 (diff)
[PATCH] ppc: Fix PowerBook HD led on ARCH=powerpc
The PowerBook HD led code uses obsoletes device-tree accessors which do not work anymore for getting the root of the tree. Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Signed-off-by: Paul Mackerras <paulus@samba.org>
Diffstat (limited to 'drivers/ide')
-rw-r--r--drivers/ide/ppc/pmac.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/drivers/ide/ppc/pmac.c b/drivers/ide/ppc/pmac.c
index d8c3d8ebad30..b3e65a65d202 100644
--- a/drivers/ide/ppc/pmac.c
+++ b/drivers/ide/ppc/pmac.c
@@ -497,16 +497,19 @@ pmu_hd_blink_init(void)
497 if (pmu_get_model() != PMU_KEYLARGO_BASED) 497 if (pmu_get_model() != PMU_KEYLARGO_BASED)
498 return 0; 498 return 0;
499 499
500 dt = find_devices("device-tree"); 500 dt = of_find_node_by_path("/");
501 if (dt == NULL) 501 if (dt == NULL)
502 return 0; 502 return 0;
503 model = (const char *)get_property(dt, "model", NULL); 503 model = (const char *)get_property(dt, "model", NULL);
504 if (model == NULL) 504 if (model == NULL)
505 return 0; 505 return 0;
506 if (strncmp(model, "PowerBook", strlen("PowerBook")) != 0 && 506 if (strncmp(model, "PowerBook", strlen("PowerBook")) != 0 &&
507 strncmp(model, "iBook", strlen("iBook")) != 0) 507 strncmp(model, "iBook", strlen("iBook")) != 0) {
508 of_node_put(dt);
508 return 0; 509 return 0;
509 510 }
511 of_node_put(dt);
512
510 pmu_blink_on.complete = 1; 513 pmu_blink_on.complete = 1;
511 pmu_blink_off.complete = 1; 514 pmu_blink_off.complete = 1;
512 spin_lock_init(&pmu_blink_lock); 515 spin_lock_init(&pmu_blink_lock);