[libvirt] [PATCH 1/3] conf: Set rebootTimeout valid range to 0..0xffff

Han Han hhan at redhat.com
Tue Oct 8 08:36:42 UTC 2019


Adjust valid range of rebootTimeout according to qemu-4.0.0 commit
ee5d0f89de3.

Signed-off-by: Han Han <hhan at redhat.com>
---
 src/conf/domain_conf.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/src/conf/domain_conf.c b/src/conf/domain_conf.c
index a53cd6a725..57ab254f52 100644
--- a/src/conf/domain_conf.c
+++ b/src/conf/domain_conf.c
@@ -18090,10 +18090,12 @@ virDomainDefParseBootXML(xmlXPathContextPtr ctxt,
             /* that was really just for the check if it is there */
 
             if (virStrToLong_i(tmp, NULL, 0, &def->os.bios.rt_delay) < 0 ||
-                def->os.bios.rt_delay < -1 || def->os.bios.rt_delay > 65535) {
+                def->os.bios.rt_delay < 0 || def->os.bios.rt_delay > 65535) {
                 virReportError(VIR_ERR_CONFIG_UNSUPPORTED, "%s",
                                _("invalid value for rebootTimeout, "
-                                 "must be in range [-1,65535]"));
+                                 "must be in range [0,65535]. "
+                                 "To disable reboot, "
+                                 "just remove this attribute."));
                 return -1;
             }
             def->os.bios.rt_set = true;
-- 
2.20.1




More information about the libvir-list mailing list