From d3c49ebbe26b48615e14b8baa88a59cd33761ea6 Mon Sep 17 00:00:00 2001 From: Paul Durrant Date: Tue, 15 May 2018 17:40:53 +0100 Subject: xen-hvm: try to use xenforeignmemory_map_resource() to map ioreq pages Xen 4.11 has a new API to directly map guest resources. Among the resources that can be mapped using this API are ioreq pages. This patch modifies QEMU to attempt to use the new API should it exist, falling back to the previous mechanism if it is unavailable. Signed-off-by: Paul Durrant Reviewed-by: Anthony PERARD Signed-off-by: Stefano Stabellini --- configure | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'configure') diff --git a/configure b/configure index a6a4616c3e..be6edc7b81 100755 --- a/configure +++ b/configure @@ -2231,12 +2231,17 @@ EOF #undef XC_WANT_COMPAT_DEVICEMODEL_API #define __XEN_TOOLS__ #include +#include int main(void) { xendevicemodel_handle *xd; + xenforeignmemory_handle *xfmem; xd = xendevicemodel_open(0, 0); xendevicemodel_pin_memory_cacheattr(xd, 0, 0, 0, 0); + xfmem = xenforeignmemory_open(0, 0); + xenforeignmemory_map_resource(xfmem, 0, 0, 0, 0, 0, NULL, 0, 0); + return 0; } EOF -- cgit v1.2.3-55-g7522