tools/libs/store: add get- and set-feature related functions

Add functions for getting and setting Xenstore features to libxenstore:

xs_get_features_supported(): return the features supported by the
running Xenstore implementation as defined in xs_wire.h via the
XENSTORE_SERVER_FEATURE_* macros.

xs_get_features_domain(): return the features offered for a specific
domain.

xs_set_features_domain(): set the features available for a specific
domain.

Signed-off-by: Juergen Gross <jgross@suse.com>
Reviewed-by: Jason Andryuk <jason.andryuk@amd.com>
This commit is contained in:
Juergen Gross authored and Jan Beulich committed 2025-07-28 13:06:20 +02:00
1 parent f2927d8343
commit 5234b61eab
4 files changed
+69 -1

No files matched your search

+13
View File
@@ -264,6 +264,19 @@ bool xs_path_is_subpath(const char *parent, const char *child);
*/
bool xs_is_domain_introduced(struct xs_handle *h, unsigned int domid);
/* Get the features supported by Xenstore.
* Returned as a bitmap of XENSTORE_SERVER_FEATURE_* values.
*/
bool xs_get_features_supported(struct xs_handle *h, unsigned int *features);
/* Get the features available for a given domain. */
bool xs_get_features_domain(struct xs_handle *h, unsigned int domid,
unsigned int *features);
/* Set the features available for a given domain. */
bool xs_set_features_domain(struct xs_handle *h, unsigned int domid,
unsigned int features);
char *xs_control_command(struct xs_handle *h, const char *cmd,
void *data, unsigned int len);
/* Deprecated: use xs_control_command() instead. */
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.