cli: --cpu: make numa.cell[0-9]*.discard an on/off type option

This commit is contained in:
Hugues Fafard 2021-08-03 19:47:54 +02:00 committed by Cole Robinson
parent bf3bd824c1
commit 42bb522f0d
2 changed files with 2 additions and 2 deletions

View File

@ -2335,7 +2335,7 @@ class ParserCPU(VirtCLIParser):
cls.add_arg("numa.cell[0-9]*.memAccess", "memAccess",
find_inst_cb=cls.cell_find_inst_cb)
cls.add_arg("numa.cell[0-9]*.discard", "discard",
find_inst_cb=cls.cell_find_inst_cb)
find_inst_cb=cls.cell_find_inst_cb, is_onoff=True)
cls.add_arg("numa.cell[0-9]*.memory", "memory",
find_inst_cb=cls.cell_find_inst_cb)
cls.add_arg("numa.cell[0-9]*.unit", "unit",

View File

@ -33,7 +33,7 @@ class _CPUCell(XMLBuilder):
memory = XMLProperty("./@memory", is_int=True)
unit = XMLProperty("./@unit")
memAccess = XMLProperty("./@memAccess")
discard = XMLProperty("./@discard")
discard = XMLProperty("./@discard", is_yesno=True)
siblings = XMLChildProperty(_CPUCellSibling, relative_xpath="./distances")