Han, Weidong wrote:
Oh, I see it now.  Different devices may need to go under different
iommus.
This really feels like it should be handled by the iommu API.  Users
shouldn't need to bother with it.

Why do you say it should be handled by iommu API?

Because the logic of which iommu controls which device is only understood by iommu developers. Also, because this logic would be duplicated by anyone attempting to do the same thing.

So it seems reasonable it should be implemented by the iommu API, not its users.

The direct way to
support multiple device assignment is keep a dmar_domain list for each
guest, each device corresponds to one dmar_domain. But this will cost
more memory because each dmar_domain has its own VT-d page table. Our
method lets the devices which are under smae iommu and assigned to the
same guest share the same VT-d page table.

If we devolve this to the iommu API, the same io page table can be shared by all iommus, so long as they all use the same page table format.


--
I have a truly marvellous patch that fixes the bug which this
signature is too narrow to contain.

--
To unsubscribe from this list: send the line "unsubscribe kvm" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to