aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2
diff options
context:
space:
mode:
authorFlorian Vaussard <florian.vaussard@epfl.ch>2014-02-28 15:42:36 -0500
committerJoerg Roedel <joro@8bytes.org>2014-03-04 11:01:57 -0500
commit3c92748df9941ff8f5be4655a04812ff4d0c7eeb (patch)
treecfcd9c51f714c5b0fe318f81b8e96c6fa983d1fc /arch/arm/mach-omap2
parenta8689f65de5a8c3e47bf29c2550dfebe0744e077 (diff)
iommu/omap: Add devicetree support
As OMAP2+ is moving to a full DT boot for all SoC families, commit 7ce93f3 "ARM: OMAP2+: Fix more missing data for omap3.dtsi file" adds basic DT bits for OMAP3. But the driver is not yet converted, so this will not work and driver will not be probed. Convert it! The legacy boot mode is still supported until OMAP3 is converted to DT-boot only. Signed-off-by: Florian Vaussard <florian.vaussard@epfl.ch> [s-anna@ti.com: dev_name adaptation and improved error checking] Signed-off-by: Suman Anna <s-anna@ti.com> [tony@atomide.com: Ack for arch/arm/*omap* parts] Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Joerg Roedel <joro@8bytes.org>
Diffstat (limited to 'arch/arm/mach-omap2')
-rw-r--r--arch/arm/mach-omap2/omap-iommu.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c
index f6daae821ebb..f1fab5684a24 100644
--- a/arch/arm/mach-omap2/omap-iommu.c
+++ b/arch/arm/mach-omap2/omap-iommu.c
@@ -10,6 +10,7 @@
10 * published by the Free Software Foundation. 10 * published by the Free Software Foundation.
11 */ 11 */
12 12
13#include <linux/of.h>
13#include <linux/module.h> 14#include <linux/module.h>
14#include <linux/platform_device.h> 15#include <linux/platform_device.h>
15#include <linux/err.h> 16#include <linux/err.h>
@@ -58,6 +59,10 @@ static int __init omap_iommu_dev_init(struct omap_hwmod *oh, void *unused)
58 59
59static int __init omap_iommu_init(void) 60static int __init omap_iommu_init(void)
60{ 61{
62 /* If dtb is there, the devices will be created dynamically */
63 if (of_have_populated_dt())
64 return -ENODEV;
65
61 return omap_hwmod_for_each_by_class("mmu", omap_iommu_dev_init, NULL); 66 return omap_hwmod_for_each_by_class("mmu", omap_iommu_dev_init, NULL);
62} 67}
63/* must be ready before omap3isp is probed */ 68/* must be ready before omap3isp is probed */