summaryrefslogtreecommitdiff
path: root/arch/arm
diff options
context:
space:
mode:
authorAngela Stegmaier <angelabaker@ti.com>2010-06-07 18:56:20 -0500
committerHari Kanigeri <h-kanigeri2@ti.com>2010-07-09 17:58:45 -0500
commit9650659c86125e3156c78e0b572891136f2c3ff0 (patch)
tree55fa3c90ee15095ced7c02f2b0100af4fac08d70 /arch/arm
parentf2c9428746a0145617a97597539a00f9770899c4 (diff)
omap: iommu- fix issues when building as modules
The function iommu_get_plat_data_size is used outside of the iommu and needs to be exported when building as modules. Also, the omap_iommu_class is created in the module init in iommu.c but isn't destroyed in the module exit which prevents the ability to repeatedly load and unload the module. These issues are fixed in this patch. Signed-off-by: Angela Stegmaier <angelabaker@ti.com>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-omap2/omap-iommu.c1
-rw-r--r--arch/arm/plat-omap/iommu.c3
2 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/omap-iommu.c b/arch/arm/mach-omap2/omap-iommu.c
index 8411c105c399..267b48cc4cf1 100644
--- a/arch/arm/mach-omap2/omap-iommu.c
+++ b/arch/arm/mach-omap2/omap-iommu.c
@@ -92,6 +92,7 @@ int iommu_get_plat_data_size()
{
return num_iommu_devices;
}
+EXPORT_SYMBOL(iommu_get_plat_data_size);
struct iommu_device *iommu_get_device_data(void)
{
diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
index c4442e06d426..aa0803e5e7b7 100644
--- a/arch/arm/plat-omap/iommu.c
+++ b/arch/arm/plat-omap/iommu.c
@@ -1132,6 +1132,9 @@ static void __exit omap_iommu_exit(void)
kmem_cache_destroy(iopte_cachep);
platform_driver_unregister(&omap_iommu_driver);
+
+ if (omap_iommu_class)
+ class_destroy(omap_iommu_class);
}
module_exit(omap_iommu_exit);