[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 11/11] tools/xl: add support for xenstore quota setting via domain config



On Thu, Mar 05, 2026 at 02:52:08PM +0100, Juergen Gross wrote:
> Add a new "xenstore-quota" domain config parameter for setting the

You mean `xenstore_quota` ^ here.

> Xenstore quota of a new domain via a list of <quota>=<val> items.
> 
> Signed-off-by: Juergen Gross <jgross@xxxxxxxx>
> ---
> diff --git a/tools/xl/xl_parse.c b/tools/xl/xl_parse.c
> index 934ad4eeef..06a5b60736 100644
> --- a/tools/xl/xl_parse.c
> +++ b/tools/xl/xl_parse.c
> @@ -1467,6 +1468,26 @@ void parse_config_data(const char *config_source,
>      if (!xlu_cfg_get_long (config, "xenstore_feature_mask", &l, 0))
>          b_info->xenstore_feature_mask = l;
>  
> +    if (!xlu_cfg_get_list(config, "xenstore_quota", &xs_quota, 
> &num_xs_quota, 0)) {
> +        b_info->xenstore_quota.num_quota = num_xs_quota;
> +        b_info->xenstore_quota.quota = calloc(num_xs_quota, sizeof(* 
> b_info->xenstore_quota.quota));

You can call xcalloc() instead, and then not need to check for
allocation failure.

And with the two changes: Reviewed-by: Anthony PERARD 
<anthony.perard@xxxxxxxxxx>

Thanks,


--
Anthony Perard | Vates XCP-ng Developer

XCP-ng & Xen Orchestra - Vates solutions

web: https://vates.tech




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.