Re: [PATCH v11 04/10] iommu/vt-d: functions to copy data from old mem

From: Joerg Roedel
Date: Mon Jun 08 2015 - 11:22:01 EST


Hi David,

On Mon, Jun 08, 2015 at 03:15:35PM +0100, David Woodhouse wrote:
> Surely this isn't specific to the Intel IOMMU? Shouldn't it live
> elsewhere â either in generic IOMMU code or perhaps in generic kexec
> support code?

I put a bigger rework of this on-top of Zhen-Hua's patches, you can find
the result in my x86/vt-d branch. With my patches I also removed this
pointer collecting concept and do the iomap_cache and iounmap calls
before the spin-lock is taken, so this problem is now solved
differently.

> And I think you're misusing VTD_PAGE_{SHIFT,MASK} when you should be
> using the normal PAGE_{SHIFT,MASK}.

I think VT_PAGE_* is correct, since the VT-d driver also runs on ia64.
There the system page-size is different from the VT-d page-size.

>And shouldn't physical addresses be phys_addr_t?

This is changed where appropriate, I hope.


Joerg

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/