[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [SUSPECTED SPAM][PATCH v4] tools/xl: fix autoballoon regex
- To: Dmitry Isaykin <isaikin-dmitry@xxxxxxxxx>
- From: Anthony PERARD <anthony.perard@xxxxxxxxxx>
- Date: Fri, 1 Oct 2021 12:36:16 +0100
- Authentication-results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
- Cc: <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
- Delivery-date: Fri, 01 Oct 2021 11:36:50 +0000
- Ironport-data: A9a23:US57Y6/xiDlTIj9HVq9gDrUDY3mTJUtcMsCJ2f8bNWPcYEJGY0x3n 2EYXjyOaKuPNGf0L4p+b9u2/B8D6sfXydJnSgpq+Xw8E34SpcT7XtnIdU2Y0wF+jyHgoOCLy +1EN7Es+ehtFie0Si9AttENlFEkvU2ybuOU5NXsZ2YhGGeIdA970Ug6wrZh29Yy6TSEK1jlV e3a8pW31GCNg1aYAkpMg05UgEoy1BhakGpwUm0WPZinjneH/5UmJMt3yZWKB2n5WuFp8tuSH I4v+l0bElTxpH/BAvv9+lryn9ZjrrT6ZWBigVIOM0Sub4QrSoXfHc/XOdJFAXq7hQllkPhD0 f9XkaygTD0JI/zho8QYFBYHFntxaPguFL/veRBTsOSWxkzCNXDt3+9vHAc9OohwFuRfWD8Us 6ZCcXZUM07F17neLLGTE4GAguwqKtXrO4UO/Glt1zjDAd4tQIzZQrWM7thdtNs1rp0SRK2HO JRGAdZpRAzOPwVPAHcHM58zvsinukahaQR8hU3A8MLb5ECMlVcsgdABKuH9e8OIbdVYmF6Co WDL9Hi/BQsVXPSAzRKV/3TqgfXA9Qv6Q4sTF7y+s/JvgUGJ10QCARsaWEv9u+TRol6zXZdTJ lIZ/gIqrLMu7wq7Q9/lRRq6rXWY+BkGVLJt//YSsV/XjPCOukDAWzZCHmUphMEaWNEedyUAz Hu5j9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: +50nVW9FiLNllIiudHsg9bxE2UEAxWZ30B09aScdgmk7ByzklQrj6vnRB/24Wzat64PnP5ZhwH JOZitmVbwNcPTRsao4djVwaMYWrZGp1i/zPyYinkMJEpt1kIbQaVAi0c2+qCgEQHmC5lJ9WdsV Aw763X11BAVobbS2zA5JoVWGMs1scYCRBeMWivZUkG+REVQvqG32lFCrZBvHrjMPdEcEm8hfsN ceN9f9mYm1KvNUSC1LbgmhHfdoGgK+XnCQ5WrrXAwyvTl9BDWMtJoZ2LSXtPHH6DuAlcWAf2s1 O+li8fkWPX0/HWHludtNeudt
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Wed, Sep 29, 2021 at 03:44:33PM +0300, Dmitry Isaykin wrote:
> This regex is used for auto-balloon mode detection based on Xen command line.
>
> The case of specifying a negative size was handled incorrectly.
> From misc/xen-command-line documentation:
>
> dom0_mem (x86)
> = List of ( min:<sz> | max:<sz> | <sz> )
>
> If a size is positive, it represents an absolute value.
> If a size is negative, it is subtracted from the total available memory.
>
> Also add support for [tT] granularity suffix.
> Also add support for memory fractions (i.e. '50%' or '1G+25%').
>
> Signed-off-by: Dmitry Isaykin <isaikin-dmitry@xxxxxxxxx>
> ---
> +#define SIZE_PATTERN "-?[0-9]+[bBkKmMgGtT]?"
> +
> ret = regcomp(®ex,
> - "(^| )dom0_mem=((|min:|max:)[0-9]+[bBkKmMgG]?,?)+($| )",
> + "(^| )dom0_mem=((|min:|max:)(" SIZE_PATTERN "|("
> SIZE_PATTERN "\\+)?[0-9]{1,2}%),?)+($| )",
> REG_NOSUB | REG_EXTENDED);
Reviewed-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
Thanks,
--
Anthony PERARD
|