aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-omap2/board-omap3beagle.c23
1 files changed, 10 insertions, 13 deletions
diff --git a/arch/arm/mach-omap2/board-omap3beagle.c b/arch/arm/mach-omap2/board-omap3beagle.c
index 32f5f895568..3ae16b4e3f5 100644
--- a/arch/arm/mach-omap2/board-omap3beagle.c
+++ b/arch/arm/mach-omap2/board-omap3beagle.c
@@ -491,23 +491,22 @@ static void __init beagle_opp_init(void)
491 491
492 /* Custom OPP enabled for all xM versions */ 492 /* Custom OPP enabled for all xM versions */
493 if (cpu_is_omap3630()) { 493 if (cpu_is_omap3630()) {
494 struct omap_hwmod *mh = omap_hwmod_lookup("mpu"); 494 struct device *mpu_dev, *iva_dev;
495 struct omap_hwmod *dh = omap_hwmod_lookup("iva");
496 struct device *dev;
497 495
498 if (!mh || !dh) { 496 mpu_dev = omap2_get_mpuss_device();
497 iva_dev = omap2_get_iva_device();
498
499 if (!mpu_dev || !iva_dev) {
499 pr_err("%s: Aiee.. no mpu/dsp devices? %p %p\n", 500 pr_err("%s: Aiee.. no mpu/dsp devices? %p %p\n",
500 __func__, mh, dh); 501 __func__, mpu_dev, iva_dev);
501 return; 502 return;
502 } 503 }
503 /* Enable MPU 1GHz and lower opps */ 504 /* Enable MPU 1GHz and lower opps */
504 dev = &mh->od->pdev.dev; 505 r = opp_enable(mpu_dev, 800000000);
505 r = opp_enable(dev, 800000000);
506 /* TODO: MPU 1GHz needs SR and ABB */ 506 /* TODO: MPU 1GHz needs SR and ABB */
507 507
508 /* Enable IVA 800MHz and lower opps */ 508 /* Enable IVA 800MHz and lower opps */
509 dev = &dh->od->pdev.dev; 509 r |= opp_enable(iva_dev, 660000000);
510 r |= opp_enable(dev, 660000000);
511 /* TODO: DSP 800MHz needs SR and ABB */ 510 /* TODO: DSP 800MHz needs SR and ABB */
512 if (r) { 511 if (r) {
513 pr_err("%s: failed to enable higher opp %d\n", 512 pr_err("%s: failed to enable higher opp %d\n",
@@ -516,10 +515,8 @@ static void __init beagle_opp_init(void)
516 * Cleanup - disable the higher freqs - we dont care 515 * Cleanup - disable the higher freqs - we dont care
517 * about the results 516 * about the results
518 */ 517 */
519 dev = &mh->od->pdev.dev; 518 opp_disable(mpu_dev, 800000000);
520 opp_disable(dev, 800000000); 519 opp_disable(iva_dev, 660000000);
521 dev = &dh->od->pdev.dev;
522 opp_disable(dev, 660000000);
523 } 520 }
524 } 521 }
525 return; 522 return;