Merge branch 'hvm' of 10.141.1.101:/var/lib/qubes/git/marmarek/core into hvm
This commit is contained in:
commit
36e0c7518f
@ -9,6 +9,7 @@ builder='hvm'
|
||||
memory={mem}
|
||||
viridian=1
|
||||
kernel='hvmloader'
|
||||
stdvga=1
|
||||
#acpi=1
|
||||
#apic=1
|
||||
boot='dca'
|
||||
|
@ -815,7 +815,7 @@ class QubesVm(object):
|
||||
args['maxmem'] = str(self.maxmem)
|
||||
args['vcpus'] = str(self.vcpus)
|
||||
if self.netvm_vm is not None:
|
||||
args['netdev'] = "'script=/etc/xen/scripts/vif-route-qubes,ip={ip}".format(ip=self.ip)
|
||||
args['netdev'] = "'mac=00:16:3E:5E:6C:{qid:02X},script=/etc/xen/scripts/vif-route-qubes,ip={ip}".format(ip=self.ip, qid=self.qid)
|
||||
if self.netvm_vm.qid != 0:
|
||||
args['netdev'] += ",backend={0}".format(self.netvm_vm.name)
|
||||
args['netdev'] += "'"
|
||||
@ -1333,7 +1333,7 @@ class QubesVm(object):
|
||||
attrs["dir_path"] = self.dir_path
|
||||
# Simple paths
|
||||
for prop in ['conf_file', 'root_img', 'volatile_img', 'private_img']:
|
||||
if hasattr(self, prop):
|
||||
if hasattr(self, prop) and self.__getattribute__(prop) is not None:
|
||||
attrs[prop] = self.relative_path(self.__getattribute__(prop))
|
||||
# Simple string attrs
|
||||
for prop in ['memory', 'maxmem', 'pcidevs', 'vcpus', 'internal',\
|
||||
@ -2053,13 +2053,13 @@ class QubesHVm(QubesVm):
|
||||
super(QubesHVm, self).__init__(**kwargs)
|
||||
self.updateable = True
|
||||
self.config_file_template = config_template_hvm
|
||||
self.private_img = None
|
||||
self.volatile_img = None
|
||||
# remove settings not used by HVM (at least for now)
|
||||
self.__delattr__('kernel')
|
||||
self.__delattr__('kernelopts')
|
||||
self.__delattr__('uses_default_kernel')
|
||||
self.__delattr__('uses_default_kernelopts')
|
||||
self.__delattr__('private_img')
|
||||
self.__delattr__('volatile_img')
|
||||
# HVM doesn't support dynamic memory management
|
||||
self.maxmem = self.memory
|
||||
|
||||
|
@ -51,10 +51,10 @@ def do_list(vm):
|
||||
print fmt.format ("root COW img", vm.rootcow_img)
|
||||
if vm.template_vm is not None:
|
||||
print fmt.format ("root img", vm.template_vm.root_img)
|
||||
if hasattr(vm, 'volatile_img'):
|
||||
if hasattr(vm, 'volatile_img') and vm.volatile_img is not None:
|
||||
print fmt.format ("root volatile img", vm.volatile_img)
|
||||
|
||||
if hasattr(vm, 'private_img'):
|
||||
if hasattr(vm, 'private_img') and vm.private_img is not None:
|
||||
print fmt.format ("private img", vm.private_img)
|
||||
print fmt.format ("vcpus", str(vm.vcpus))
|
||||
print fmt.format ("memory", vm.memory)
|
||||
|
Loading…
Reference in New Issue
Block a user