domain: features: treat <vmcoreinfo/> as a tristate

When it was initially introduced, vmcoreinfo was a boolean option,
but that was changed a release latest to be a tristate.
This commit is contained in:
Cole Robinson
2019-05-11 19:57:33 -04:00
parent 12440b00c1
commit 913c9de29b
4 changed files with 5 additions and 5 deletions

View File

@@ -88,7 +88,7 @@
<synic state="on"/>
</hyperv>
<vmport state="off"/>
<vmcoreinfo/>
<vmcoreinfo state="on"/>
</features>
<cpu mode="custom" match="strict">
<model>foobar</model>
@@ -283,7 +283,7 @@
<synic state="on"/>
</hyperv>
<vmport state="off"/>
<vmcoreinfo/>
<vmcoreinfo state="on"/>
</features>
<cpu mode="custom" match="strict">
<model>foobar</model>

View File

@@ -27,7 +27,7 @@
</hyperv>
<vmport state="on"/>
<viridian/>
<vmcoreinfo/>
<vmcoreinfo state="on"/>
<kvm>
<hidden state="on"/>
</kvm>

View File

@@ -177,7 +177,7 @@ class XMLParseTest(unittest.TestCase):
check("hyperv_spinlocks", True, True)
check("hyperv_spinlocks_retries", 12287, 54321)
check("vmport", False, True)
check("vmcoreinfo", False, True)
check("vmcoreinfo", None, True)
check("kvm_hidden", None, True)
check("pvspinlock", None, True)
check("gic_version", None, False)

View File

@@ -39,7 +39,7 @@ class DomainFeatures(XMLBuilder):
pvspinlock = XMLProperty("./pvspinlock/@state", is_onoff=True)
smm = XMLProperty("./smm/@state", is_onoff=True)
vmcoreinfo = XMLProperty("./vmcoreinfo", is_bool=True)
vmcoreinfo = XMLProperty("./vmcoreinfo/@state", is_onoff=True)
##################