From: Stefano Stabellini <[email protected]> get_free_port will soon be used to allocate the xenstore event channel for dom0less domains.
Signed-off-by: Stefano Stabellini <[email protected]> CC: Julien Grall <[email protected]> CC: Volodymyr Babchuk <[email protected]> CC: Bertrand Marquis <[email protected]> CC: Jan Beulich <[email protected]> CC: Andrew Cooper <[email protected]> --- xen/common/event_channel.c | 2 +- xen/include/xen/event.h | 3 +++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/xen/common/event_channel.c b/xen/common/event_channel.c index da88ad141a..5b0bcaaad4 100644 --- a/xen/common/event_channel.c +++ b/xen/common/event_channel.c @@ -232,7 +232,7 @@ int evtchn_allocate_port(struct domain *d, evtchn_port_t port) return 0; } -static int get_free_port(struct domain *d) +int get_free_port(struct domain *d) { int port; diff --git a/xen/include/xen/event.h b/xen/include/xen/event.h index 21c95e14fd..0b35d9d4d2 100644 --- a/xen/include/xen/event.h +++ b/xen/include/xen/event.h @@ -71,6 +71,9 @@ void evtchn_free(struct domain *d, struct evtchn *chn); /* Allocate a specific event channel port. */ int evtchn_allocate_port(struct domain *d, unsigned int port); +/* Get fix free event channel port */ +int get_free_port(struct domain *d); + /* Unmask a local event-channel port. */ int evtchn_unmask(unsigned int port); -- 2.25.1
