aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/plat-omap/iommu.c
diff options
context:
space:
mode:
authorHiroshi DOYU <Hiroshi.DOYU@nokia.com>2010-02-15 10:03:32 -0800
committerTony Lindgren <tony@atomide.com>2010-02-15 10:03:32 -0800
commit8d33ea5881bce56f85de7fcc90e1c5618fa5b62d (patch)
tree9b9e409ac2932bf9c5a920db4dd492782473338d /arch/arm/plat-omap/iommu.c
parentomap iommu: cleanup iommu page address mask and definitions (diff)
downloadlinux-dev-8d33ea5881bce56f85de7fcc90e1c5618fa5b62d.tar.xz
linux-dev-8d33ea5881bce56f85de7fcc90e1c5618fa5b62d.zip
omap: iommu: fix incorrect address for supersection 1st entry
There was a potential risk that the following "memset" could override its range if a given address was not the 1st entry of a supersection. This is not the case for "iovmm". Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com> Signed-off-by: Hari Nagalla <hnagalla@ti.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
Diffstat (limited to 'arch/arm/plat-omap/iommu.c')
-rw-r--r--arch/arm/plat-omap/iommu.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/arm/plat-omap/iommu.c b/arch/arm/plat-omap/iommu.c
index 463d6386aff2..e74811920668 100644
--- a/arch/arm/plat-omap/iommu.c
+++ b/arch/arm/plat-omap/iommu.c
@@ -667,7 +667,7 @@ static size_t iopgtable_clear_entry_core(struct iommu *obj, u32 da)
if ((*iopgd & IOPGD_SUPER) == IOPGD_SUPER) {
nent *= 16;
/* rewind to the 1st entry */
- iopgd = (u32 *)((u32)iopgd & IOSUPER_MASK);
+ iopgd = iopgd_offset(obj, (da & IOSUPER_MASK));
}
bytes *= nent;
}