[openib-general] How to support IOMMUs for ipath driver

Ralph Campbell ralphc at pathscale.com
Wed Sep 13 10:33:09 PDT 2006


On Tue, 2006-09-12 at 21:10 -0600, Jason Gunthorpe wrote:
> On Tue, Sep 12, 2006 at 05:40:10PM -0700, Ralph Campbell wrote:
> 
> > The ib_ipath driver needs kernel virtual addresses in order to be able
> > to copy data to/from the posted work requests since it does not
> > use HW DMA. It currently relies on the mapping being one-to-one
> > and cannot reasonably reverse the mapping when an IOMMU is present.
> 
> I'm sure this must have been answered, but given a PCI
> domain:bus:device:function tuple and a DMA address, shouldn't any
> effects of an IOMMU be easially duplicated in software to result in a
> cpu-bus physical address? Ie on AMD64 it is just a matter of following
> the GART tables in software - assuming the address in question hits
> the GART region (which for ipath, I expect, it never would)
> 
> Jason

The problem is that this reverse mapping code would either need to
be added to every device driver for every possible IOMMU or
it would need to be added to the general dma interface as a new
architecture dependent interface. Neither of these is acceptable
to the kernel community.





More information about the general mailing list