From b8126de23e957978b4d0403097cd8402f0c1d82a Mon Sep 17 00:00:00 2001 From: delphij Date: Wed, 12 Apr 2017 06:24:35 +0000 Subject: Fix multiple vulnerabilities of ntp. [SA-17:03] Xen migration enhancements. [EN-17:05] Approved by: so --- sys/xen/xenstore/xenstore.c | 17 +++++++++++++++++ sys/xen/xenstore/xenstorevar.h | 11 +++++++++++ 2 files changed, 28 insertions(+) (limited to 'sys/xen/xenstore') diff --git a/sys/xen/xenstore/xenstore.c b/sys/xen/xenstore/xenstore.c index d404862..2c193ac 100644 --- a/sys/xen/xenstore/xenstore.c +++ b/sys/xen/xenstore/xenstore.c @@ -1657,3 +1657,20 @@ xs_unregister_watch(struct xs_watch *watch) sx_xunlock(&xs.xenwatch_mutex); } } + +void +xs_lock(void) +{ + + sx_xlock(&xs.request_mutex); + return; +} + +void +xs_unlock(void) +{ + + sx_xunlock(&xs.request_mutex); + return; +} + diff --git a/sys/xen/xenstore/xenstorevar.h b/sys/xen/xenstore/xenstorevar.h index 208e5bf..4c612b4 100644 --- a/sys/xen/xenstore/xenstorevar.h +++ b/sys/xen/xenstore/xenstorevar.h @@ -338,4 +338,15 @@ void xs_unregister_watch(struct xs_watch *watch); */ struct sbuf *xs_join(const char *, const char *); +/** + * Lock the xenstore request mutex. + */ +void xs_lock(void); + +/** + * Unlock the xenstore request mutex. + */ +void xs_unlock(void); + #endif /* _XEN_XENSTORE_XENSTOREVAR_H */ + -- cgit v1.1