xen-devel.lists.xenproject.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v5 0/4] introduce XENMEM_exchange_and_pin and XENMEM_unpin
@ 2013-09-09 16:04 Stefano Stabellini
  2013-09-09 16:06 ` [PATCH v5 1/4] xen: move steal_page and donate_page to common code Stefano Stabellini
                   ` (3 more replies)
  0 siblings, 4 replies; 32+ messages in thread
From: Stefano Stabellini @ 2013-09-09 16:04 UTC (permalink / raw)
  To: xen-devel; +Cc: Tim Deegan, Ian Campbell, Stefano Stabellini

Hi all,
this patch series introduces two new hypercalls to allow autotranslate
guests to allocate a contiguous buffer in machine addresses.
The XENMEM_exchange_and_pin returns the mfns and makes sure to pin the
pages so that the hypervisor won't change their p2m mappings while in
use.
XENMEM_unpin simply unpins the pages.

Cheers,

Stefano


Changes in v5:
- move donate_page to common code;
- update commit message;
- align tests;
- comment p2m_walker;
- fix return codes in p2m_walker;
- handle superpages in p2m_walker;
- rename _p2m_lookup to p2m_lookup_f;
- return -EBUSY when the P2M_DMA_PIN check fails;
- rename _guest_physmap_pin_range to pin_one_pte;
- rename _guest_physmap_unpin_range to unpin_one_pte;
- memory_exchange: handle guest_physmap_pin_range failures;
- make i an unsigned long in unpinned;
- add nr_unpinned to xen_unpin to report partial success.

Changes in v4:
- move steal_page to common code;
- introduce a generic p2m walker and use it in p2m_lookup,
  guest_physmap_pin_range and guest_physmap_unpin_range;
- return -EINVAL when the P2M_DMA_PIN check fails;
- change the printk into a gdprintk;
- add a comment on what type of page can be pinned;
- rename XENMEM_get_dma_buf to XENMEM_exchange_and_pin;
- rename XENMEM_get_dma_buf to XENMEM_unpin;
- move the pinning before we copy back the mfn to the guest;
- propagate errors returned by guest_physmap_pin_range;
- use xen_memory_exchange_t as parameter for XENMEM_exchange_and_pin;
- use an unsigned iterator in unpin;
- improve the documentation of the new hypercalls;
- add a note about out.address_bits for XENMEM_exchange.

Changes in v3:
- implement guest_physmap_pin_range and guest_physmap_unpin_range on
  ARM;
- implement XENMEM_put_dma_buf.

Changes in v2:
- actually don't print the warning more than once.



Stefano Stabellini (4):
      xen: move steal_page and donate_page to common code
      xen/arm: introduce a generic p2m walker and use it in p2m_lookup
      xen: implement guest_physmap_pin_range and guest_physmap_unpin_range
      xen: introduce XENMEM_exchange_and_pin and XENMEM_unpin

 xen/arch/arm/mm.c           |   12 ---
 xen/arch/arm/p2m.c          |  177 +++++++++++++++++++++++++++++-----
 xen/arch/x86/mm.c           |   85 ----------------
 xen/common/memory.c         |  226 +++++++++++++++++++++++++++++++++++++------
 xen/include/asm-arm/mm.h    |    9 +-
 xen/include/asm-arm/page.h  |    7 +-
 xen/include/asm-x86/mm.h    |    5 -
 xen/include/asm-x86/p2m.h   |   12 +++
 xen/include/public/memory.h |   47 +++++++++
 xen/include/xen/mm.h        |    3 +
 10 files changed, 418 insertions(+), 165 deletions(-)

^ permalink raw reply	[flat|nested] 32+ messages in thread

end of thread, other threads:[~2013-09-27 15:27 UTC | newest]

Thread overview: 32+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-09 16:04 [PATCH v5 0/4] introduce XENMEM_exchange_and_pin and XENMEM_unpin Stefano Stabellini
2013-09-09 16:06 ` [PATCH v5 1/4] xen: move steal_page and donate_page to common code Stefano Stabellini
2013-09-10  9:08   ` Ian Campbell
2013-09-10 10:39   ` Jan Beulich
2013-09-10 17:20     ` Stefano Stabellini
2013-09-10 18:06       ` Tim Deegan
2013-09-10 18:14         ` Stefano Stabellini
2013-09-11  6:31       ` Jan Beulich
2013-09-09 16:06 ` [PATCH v5 2/4] xen/arm: introduce a generic p2m walker and use it in p2m_lookup Stefano Stabellini
2013-09-10  9:26   ` Ian Campbell
2013-09-10 18:00     ` Stefano Stabellini
2013-09-10 18:38       ` Ian Campbell
2013-09-11 16:55         ` Stefano Stabellini
2013-09-09 16:06 ` [PATCH v5 3/4] xen: implement guest_physmap_pin_range and guest_physmap_unpin_range Stefano Stabellini
2013-09-10  9:30   ` Ian Campbell
2013-09-10 19:11     ` Stefano Stabellini
2013-09-10 19:42       ` Ian Campbell
2013-09-27 14:46         ` Stefano Stabellini
2013-09-10  9:33   ` Ian Campbell
2013-09-27 15:23     ` Stefano Stabellini
2013-09-27 15:27       ` Ian Campbell
2013-09-09 16:06 ` [PATCH v5 4/4] xen: introduce XENMEM_exchange_and_pin and XENMEM_unpin Stefano Stabellini
2013-09-10  9:47   ` Ian Campbell
2013-09-10 12:15   ` Jan Beulich
2013-09-10 12:50     ` Ian Campbell
2013-09-10 13:28       ` Jan Beulich
2013-09-10 18:32         ` Stefano Stabellini
2013-09-10 18:37           ` Tim Deegan
2013-09-10 18:40             ` Ian Campbell
2013-09-10 18:50               ` Tim Deegan
2013-09-11  6:33           ` Jan Beulich
2013-09-27 14:49     ` Stefano Stabellini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).