[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH v3 0/5] xen/arm: introduce GNTTABOP_cache_flush
Hi all, this patch series introduces a new hypercall to perform cache maintenance operations on behalf of the guest. It is useful for dom0 to be able to cache flush pages involved in a dma operation with non-coherent devices. It also removes XENFEAT_grant_map_identity as the feature is no longer necessary: it was used to achieve the same goal but the guest can now use the hypercall instead. Keeping the flag would also have a significant performance impact as a new p2m mapping gets created and then destroyed for every grant that is mapped and unmapped in dom0. Changes in v3: - introduce two different max_nr_dom0/domU_grant_frames parameters; - x86: introduce more cache maintenance operations; - reduce the time the grant_table lock is held; - fix warning message; - s/EFAULT/EPERM; - s/llx/PRIx64; - check offset and size independetly before checking their sum; - rcu_lock_current_domain cannot fail; - s/ENOSYS/EOPNOTSUPP; - use clean_and_invalidate_xen_dcache_va_range to do both operations at once; - fold grant_map_exists in this patch; - support "count" argument; - make correspondent changes to compat/grant_table.c; - introduce GNTTAB_CACHE_SOURCE_GREF to select the type of input in the union; - rename size field to length; - make length and offset uint16_t; - only take spin_lock if d != owner. Changes in v2: - make grant_map_exists static; - remove the spin_lock in grant_map_exists; - move the hypercall to GNTTABOP; - do not check for mfn_to_page errors in GNTTABOP_cache_flush; - take a reference to the page in GNTTABOP_cache_flush; - replace printk with gdprintk in GNTTABOP_cache_flush; - split long line in GNTTABOP_cache_flush; - remove out label in GNTTABOP_cache_flush; - move rcu_lock_current_domain down before the loop in GNTTABOP_cache_flush; - take a spin_lock before calling grant_map_exists in GNTTABOP_cache_flush. Stefano Stabellini (5): xen: introduce two different max_nr_dom0/domU_grant_frames parameters xen/arm: introduce invalidate_xen_dcache_va_range xen/x86: introduce more cache maintenance operations xen/arm: introduce GNTTABOP_cache_flush Revert "xen/arm: introduce XENFEAT_grant_map_identity" docs/misc/xen-command-line.markdown | 4 +- xen/arch/arm/domain.c | 2 +- xen/arch/arm/mm.c | 2 +- xen/arch/x86/mm.c | 2 +- xen/common/compat/grant_table.c | 16 ++- xen/common/grant_table.c | 237 +++++++++++++++++++++++++++-------- xen/common/kernel.c | 2 - xen/drivers/passthrough/arm/smmu.c | 33 +++++ xen/include/asm-arm/arm32/page.h | 3 + xen/include/asm-arm/arm64/page.h | 3 + xen/include/asm-arm/grant_table.h | 5 +- xen/include/asm-arm/page.h | 30 +++++ xen/include/asm-x86/page.h | 4 + xen/include/public/features.h | 4 +- xen/include/public/grant_table.h | 20 +++ xen/include/xen/grant_table.h | 6 +- xen/include/xlat.lst | 1 + 17 files changed, 305 insertions(+), 69 deletions(-) _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |