[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [Xen-devel] Re: [XEN-IOMMU] Proposal of DMA protection/isolationsupport



> After looking into the grant mapping code (use block device as an
> example), I got some ideas to share with you and the list.  Please
> correct me if I missed something. There might be 2 places to trigger
> iommu mapping:
> 
> 1) Before submitting io request to generic block layer, block backend
> driver will invoke GNTTABOPs to map granted remote pages .  However
> creating iommu mapping only in GNTTABOP not very enough because local
> pages will also be submitted to block layer and they should also be
> translated by iommu.
> 
> 2) When dma layer is invoked to prepare a bus address for native block
> device driver. It would be better to have a "hypervisor-aware" dma
> layer
> which always maps virtual address to bus address via hypercall.
> __gnttab_dma_map_page() might be a good place to trigger this new
> hypercall. Both remote and local pages can be mapped by this way.


It's much better to create most mappings in #1 when the operations are
easily batchable into a single hypercall, and then fill in the missing
mappings when required at #2.

Since in many situations dom0 does very little IO for itself, this
should be a significant win, especially for networking.

Ian
 


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.