mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
During migration there are a lot of mmap/munmap calls, because xc_get_pfn_type_batch() exceeds the default hypercall bounce buffer cache size, and needs to allocate every time it is called. munmap() is slow, especially in a PV Dom0 (takes an emulation fault), so is best avoided. Eventually it'd be good if the memory pool from xmalloc_tlsf.c was reused here, but for now make it handle the commonly encountered sizes (so far up to 4 pages). Signed-off-by: Edwin Török <edwin.torok@citrix.com> Signed-off-by: Frediano Ziglio <frediano.ziglio@citrix.com> Reviewed-by: Anthony PERARD <anthony.perard@vates.tech>