public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] omap iommu: avoid remapping if it's been mapped in MPU side
       [not found] <1251283037-19573-1-git-send-email-sakari.ailus@maxwell.research.nokia.com>
@ 2009-08-26 10:45 ` Hiroshi DOYU
  2009-10-20 19:27   ` [APPLIED] [PATCH] omap iommu: avoid remapping if it&#39;s " Tony Lindgren
  0 siblings, 1 reply; 2+ messages in thread
From: Hiroshi DOYU @ 2009-08-26 10:45 UTC (permalink / raw)
  To: linux-omap@vger.kernel.org

From: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>

MPU side (v)-(p) mapping is necessary only if IOVMF_MMIO is set in
"flags".

Signed-off-by: Hiroshi DOYU <Hiroshi.DOYU@nokia.com>
---
 arch/arm/plat-omap/iovmm.c |   10 ++++++----
 1 files changed, 6 insertions(+), 4 deletions(-)

diff --git a/arch/arm/plat-omap/iovmm.c b/arch/arm/plat-omap/iovmm.c
index 6fc52fc..004fd83 100644
--- a/arch/arm/plat-omap/iovmm.c
+++ b/arch/arm/plat-omap/iovmm.c
@@ -615,7 +615,7 @@ u32 iommu_vmap(struct iommu *obj, u32 da, const struct sg_table *sgt,
 		 u32 flags)
 {
 	size_t bytes;
-	void *va;
+	void *va = NULL;
 
 	if (!obj || !obj->dev || !sgt)
 		return -EINVAL;
@@ -625,9 +625,11 @@ u32 iommu_vmap(struct iommu *obj, u32 da, const struct sg_table *sgt,
 		return -EINVAL;
 	bytes = PAGE_ALIGN(bytes);
 
-	va = vmap_sg(sgt);
-	if (IS_ERR(va))
-		return PTR_ERR(va);
+	if (flags & IOVMF_MMIO) {
+		va = vmap_sg(sgt);
+		if (IS_ERR(va))
+			return PTR_ERR(va);
+	}
 
 	flags &= IOVMF_HW_MASK;
 	flags |= IOVMF_DISCONT;
-- 
1.5.6.5


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* [APPLIED] [PATCH] omap iommu: avoid remapping if it&#39;s been mapped in MPU side
  2009-08-26 10:45 ` [PATCH] omap iommu: avoid remapping if it's been mapped in MPU side Hiroshi DOYU
@ 2009-10-20 19:27   ` Tony Lindgren
  0 siblings, 0 replies; 2+ messages in thread
From: Tony Lindgren @ 2009-10-20 19:27 UTC (permalink / raw)
  To: linux-omap

This patch has been applied to the linux-omap
by youw fwiendly patch wobot.

Branch in linux-omap: for-next

Initial commit ID (Likely to change): 3b61e08a6ea37d353d98979040aef10f7cf6f83d

PatchWorks
http://patchwork.kernel.org/patch/44014/

Git (Likely to change, and takes a while to get mirrored)
http://git.kernel.org/?p=linux/kernel/git/tmlind/linux-omap-2.6.git;a=commit;h=3b61e08a6ea37d353d98979040aef10f7cf6f83d



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-10-20 19:27 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <1251283037-19573-1-git-send-email-sakari.ailus@maxwell.research.nokia.com>
2009-08-26 10:45 ` [PATCH] omap iommu: avoid remapping if it's been mapped in MPU side Hiroshi DOYU
2009-10-20 19:27   ` [APPLIED] [PATCH] omap iommu: avoid remapping if it&#39;s " Tony Lindgren

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox