iommu: Fix flags passed to iommu map functions.

iommu map functions requires clients to specify whether
the mappings should be read only or read-write (write only
is not supported). Ensure clients specify the appropriate
flags when calling map functions.

Change-Id: If42b4b0367b4311aa36d3063979ef04af3a43fc6
Signed-off-by: Olav Haugan <ohaugan@codeaurora.org>
diff --git a/arch/arm/mach-msm/subsystem_map.c b/arch/arm/mach-msm/subsystem_map.c
index d6a17e6..96c3d49 100644
--- a/arch/arm/mach-msm/subsystem_map.c
+++ b/arch/arm/mach-msm/subsystem_map.c
@@ -392,7 +392,8 @@
 					temp_phys += SZ_4K,
 					temp_va += SZ_4K) {
 				ret = iommu_map(d, temp_va, temp_phys,
-						 get_order(SZ_4K), 0);
+						get_order(SZ_4K),
+						(IOMMU_READ | IOMMU_WRITE));
 				if (ret) {
 					pr_err("%s: could not map iommu for"
 						" domain %p, iova %lx,"
@@ -406,7 +407,8 @@
 
 			if (flags & MSM_SUBSYSTEM_MAP_IOMMU_2X)
 				msm_iommu_map_extra
-					(d, temp_va, length, 0);
+					(d, temp_va, length,
+					(IOMMU_READ | IOMMU_WRITE));
 		}
 
 	}