mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
With the Xen side of this interface (soon to be) fixed to return real sizes, userspace needs to be able to make the query. Introduce xenforeignmemory_resource_size() for the purpose, bumping the library minor version. Update both all osdep_xenforeignmemory_map_resource() implementations to understand size requests, skip the mmap() operation, and copy back the nr_frames field. For NetBSD, also fix up the ioctl() error path to issue an unmap(), which was overlooked by c/s 4a64e2bb39 "libs/foreignmemory: Implement on NetBSD". Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com> Reviewed-by: Roger Pau Monné <roger.pau@citrix.com> Reviewed-by: Paul Durrant <paul@xen.org> Acked-by: Wei Liu <wl@xen.org>
26 lines
459 B
Plaintext
26 lines
459 B
Plaintext
VERS_1.0 {
|
|
global:
|
|
xenforeignmemory_open;
|
|
xenforeignmemory_close;
|
|
xenforeignmemory_map;
|
|
xenforeignmemory_unmap;
|
|
local: *; /* Do not expose anything by default */
|
|
};
|
|
VERS_1.1 {
|
|
global:
|
|
xenforeignmemory_restrict;
|
|
} VERS_1.0;
|
|
VERS_1.2 {
|
|
global:
|
|
xenforeignmemory_map2;
|
|
} VERS_1.1;
|
|
VERS_1.3 {
|
|
global:
|
|
xenforeignmemory_map_resource;
|
|
xenforeignmemory_unmap_resource;
|
|
} VERS_1.2;
|
|
VERS_1.4 {
|
|
global:
|
|
xenforeignmemory_resource_size;
|
|
} VERS_1.3;
|