diff options
Diffstat (limited to 'arch/arm/plat-omap/omap_device.c')
-rw-r--r-- | arch/arm/plat-omap/omap_device.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/arm/plat-omap/omap_device.c b/arch/arm/plat-omap/omap_device.c index f9dec0d32fa4..dee4629b7b47 100644 --- a/arch/arm/plat-omap/omap_device.c +++ b/arch/arm/plat-omap/omap_device.c | |||
@@ -655,6 +655,25 @@ struct powerdomain *omap_device_get_pwrdm(struct omap_device *od) | |||
655 | return omap_hwmod_get_pwrdm(od->hwmods[0]); | 655 | return omap_hwmod_get_pwrdm(od->hwmods[0]); |
656 | } | 656 | } |
657 | 657 | ||
658 | /** | ||
659 | * omap_device_get_mpu_rt_va - return the MPU's virtual addr for the hwmod base | ||
660 | * @od: struct omap_device * | ||
661 | * | ||
662 | * Return the MPU's virtual address for the base of the hwmod, from | ||
663 | * the ioremap() that the hwmod code does. Only valid if there is one | ||
664 | * hwmod associated with this device. Returns NULL if there are zero | ||
665 | * or more than one hwmods associated with this omap_device; | ||
666 | * otherwise, passes along the return value from | ||
667 | * omap_hwmod_get_mpu_rt_va(). | ||
668 | */ | ||
669 | void __iomem *omap_device_get_rt_va(struct omap_device *od) | ||
670 | { | ||
671 | if (od->hwmods_cnt != 1) | ||
672 | return NULL; | ||
673 | |||
674 | return omap_hwmod_get_mpu_rt_va(od->hwmods[0]); | ||
675 | } | ||
676 | |||
658 | /* | 677 | /* |
659 | * Public functions intended for use in omap_device_pm_latency | 678 | * Public functions intended for use in omap_device_pm_latency |
660 | * .activate_func and .deactivate_func function pointers | 679 | * .activate_func and .deactivate_func function pointers |