Messages in this thread Patch in this message | | | Date | Sat, 16 Feb 2008 15:03:43 +0900 | Subject | Re: more iommu sg merging fallout | From | FUJITA Tomonori <> |
| |
Sorry for the late response,
On Mon, 11 Feb 2008 21:40:36 -0800 (PST) David Miller <davem@davemloft.net> wrote:
> From: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> > Date: Thu, 07 Feb 2008 10:38:01 +0900 > > > Great, thanks! SPARC IOMMUs use bitmap for the free area management > > like POWER IOMMUs so it could use lib/iommu-helper as POWER does. > > Please look at Linus's current tree, I believe I have things > in a working state, and the DMA mask portions should be easier > to add now.
Thanks! It looks great.
iommu->page_table_map_base is on IO_PAGE_SIZE boundary? If so, the following patch works, I think (sorry, it's only compile tested again).
Thanks,
= From 91af83802c30d071f98444846e85310a8d58ab3d Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> Date: Sat, 16 Feb 2008 14:29:02 +0900 Subject: [PATCH] sparc64: make IOMMU code respect the segment boundary limits
Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp> --- arch/sparc64/kernel/iommu.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/arch/sparc64/kernel/iommu.c b/arch/sparc64/kernel/iommu.c index d3276eb..ffefbf7 100644 --- a/arch/sparc64/kernel/iommu.c +++ b/arch/sparc64/kernel/iommu.c @@ -134,7 +134,8 @@ unsigned long iommu_range_alloc(struct device *dev, else boundary_size = ALIGN(1UL << 32, 1 << IO_PAGE_SHIFT); - n = iommu_area_alloc(arena->map, limit, start, npages, 0, + n = iommu_area_alloc(arena->map, limit, start, npages, + iommu->page_table_map_base >> IO_PAGE_SHIFT, boundary_size >> IO_PAGE_SHIFT, 0); if (n == -1) { if (likely(pass < 1)) { -- 1.5.3.4
| |