mirror of
https://github.com/virt-manager/virt-manager.git
synced 2025-02-25 18:55:27 -06:00
devicepanic: Don't return empty model list (bz #1505532)
Callers don't expect it, and it breaks opening the addhardware dialog for aarch64 VMs https://bugzilla.redhat.com/show_bug.cgi?id=1505532
This commit is contained in:
@@ -49,12 +49,13 @@ class VirtualPanicDevice(VirtualDevice):
|
|||||||
@staticmethod
|
@staticmethod
|
||||||
def get_models(os):
|
def get_models(os):
|
||||||
if os.is_x86():
|
if os.is_x86():
|
||||||
return [VirtualPanicDevice.MODEL_ISA, VirtualPanicDevice.MODEL_HYPERV]
|
return [VirtualPanicDevice.MODEL_ISA,
|
||||||
|
VirtualPanicDevice.MODEL_HYPERV]
|
||||||
elif os.is_pseries():
|
elif os.is_pseries():
|
||||||
return [VirtualPanicDevice.MODEL_PSERIES]
|
return [VirtualPanicDevice.MODEL_PSERIES]
|
||||||
elif os.is_s390x():
|
elif os.is_s390x():
|
||||||
return [VirtualPanicDevice.MODEL_S390]
|
return [VirtualPanicDevice.MODEL_S390]
|
||||||
return None
|
return []
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def get_default_model(os):
|
def get_default_model(os):
|
||||||
|
|||||||
Reference in New Issue
Block a user