[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 10/11] libxc: add xc_domain_set_max_evtchn()
From: David Vrabel <david.vrabel@xxxxxxxxxx> Add xc_domain_set_max_evtchn(), a wrapper around the DOMCTL_set_max_evtchn hypercall. Signed-off-by: David Vrabel <david.vrabel@xxxxxxxxxx> Cc: Ian Campbell <ian.campbell@xxxxxxxxxx> Cc: Ian Jackson <ian.jackson@xxxxxxxxxxxxx> --- tools/libxc/xc_domain.c | 11 +++++++++++ tools/libxc/xenctrl.h | 12 ++++++++++++ 2 files changed, 23 insertions(+), 0 deletions(-) diff --git a/tools/libxc/xc_domain.c b/tools/libxc/xc_domain.c index 81316d3..2cea6e3 100644 --- a/tools/libxc/xc_domain.c +++ b/tools/libxc/xc_domain.c @@ -1766,6 +1766,17 @@ int xc_domain_set_virq_handler(xc_interface *xch, uint32_t domid, int virq) return do_domctl(xch, &domctl); } +int xc_domain_set_max_evtchn(xc_interface *xch, uint32_t domid, + uint32_t max_port) +{ + DECLARE_DOMCTL; + + domctl.cmd = XEN_DOMCTL_set_max_evtchn; + domctl.domain = domid; + domctl.u.set_max_evtchn.max_port = max_port; + return do_domctl(xch, &domctl); +} + /* * Local variables: * mode: C diff --git a/tools/libxc/xenctrl.h b/tools/libxc/xenctrl.h index 58d51f3..8cf3f3b 100644 --- a/tools/libxc/xenctrl.h +++ b/tools/libxc/xenctrl.h @@ -847,6 +847,18 @@ int xc_domain_set_access_required(xc_interface *xch, */ int xc_domain_set_virq_handler(xc_interface *xch, uint32_t domid, int virq); +/** + * Set the maximum event channel port a domain may bind. + * + * This does not affect ports that are already bound. + * + * @param xch a handle to an open hypervisor interface + * @param domid the domain id + * @param max_port maximum port number + */ +int xc_domain_set_max_evtchn(xc_interface *xch, uint32_t domid, + uint32_t max_port); + /* * CPUPOOL MANAGEMENT FUNCTIONS */ -- 1.7.2.5 _______________________________________________ Xen-devel mailing list Xen-devel@xxxxxxxxxxxxx http://lists.xen.org/xen-devel
|
Lists.xenproject.org is hosted with RackSpace, monitoring our |