Skip to content

Commit

Permalink
q-dev: fix memory balancing
Browse files Browse the repository at this point in the history
  • Loading branch information
piotrbartman committed Jun 12, 2024
1 parent 00256e4 commit 8da3246
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion qubes/api/admin.py
Original file line number Diff line number Diff line change
Expand Up @@ -1216,7 +1216,8 @@ async def vm_device_available(self, endpoint):
scope='local', read=True)
async def vm_device_list(self, endpoint):
devclass = endpoint
device_assignments = self.dest.devices[devclass].get_assigned_devices()
device_assignments = list(
self.dest.devices[devclass].get_assigned_devices())
if self.arg:
select_backend, select_ident = self.arg.split('+', 1)
device_assignments = [dev for dev in device_assignments
Expand Down
2 changes: 1 addition & 1 deletion qubes/vm/qubesvm.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ def _setter_kbd_layout(self, prop, value):


def _default_virt_mode(self):
if self.devices['pci'].get_assigned_devices():
if list(self.devices['pci'].get_assigned_devices()):
return 'hvm'
try:
return self.template.virt_mode
Expand Down

0 comments on commit 8da3246

Please sign in to comment.