Add lan9118 as valid nic for hw_vif_model property for qemu

DocImpact
This introduces an additional VNI so the hw_vif_model doc needs updating
to reflect this at:
https://docs.openstack.org/cli-reference/glance-property-keys.html

Change-Id: Ifc1636bff53cf74f889e1f4b632fa62c52d07b8e
Closes-Bug: 1638059
Signed-off-by: Thomas Stewart <thomas@stewarts.org.uk>
This commit is contained in:
Thomas Stewart 2016-11-03 21:08:04 +00:00
parent 3ee4b0cf0e
commit af8d93fa9d
6 changed files with 16 additions and 2 deletions

View File

@ -117,6 +117,7 @@ VIF_MODEL_E1000 = 'e1000'
VIF_MODEL_E1000E = 'e1000e'
VIF_MODEL_NETFRONT = 'netfront'
VIF_MODEL_SPAPR_VLAN = 'spapr-vlan'
VIF_MODEL_LAN9118 = 'lan9118'
VIF_MODEL_SRIOV = 'sriov'
VIF_MODEL_VMXNET = 'vmxnet'
@ -131,6 +132,7 @@ VIF_MODEL_ALL = (
VIF_MODEL_E1000E,
VIF_MODEL_NETFRONT,
VIF_MODEL_SPAPR_VLAN,
VIF_MODEL_LAN9118,
VIF_MODEL_SRIOV,
VIF_MODEL_VMXNET,
VIF_MODEL_VMXNET3,

View File

@ -165,7 +165,8 @@ class ImageMetaProps(base.NovaObject):
# Version 1.14: Added 'hw_pointer_model' field
# Version 1.15: Added hw_rescue_bus and hw_rescue_device.
# Version 1.16: WatchdogActionField supports 'disabled' enum.
VERSION = '1.16'
# Version 1.17: Add lan9118 as valid nic for hw_vif_model property for qemu
VERSION = '1.17'
def obj_make_compatible(self, primitive, target_version):
super(ImageMetaProps, self).obj_make_compatible(primitive,

View File

@ -1096,7 +1096,7 @@ object_data = {
'HVSpec': '1.2-de06bcec472a2f04966b855a49c46b41',
'IDEDeviceBus': '1.0-29d4c9f27ac44197f01b6ac1b7e16502',
'ImageMeta': '1.8-642d1b2eb3e880a367f37d72dd76162d',
'ImageMetaProps': '1.16-3e5ad8e86f2ea36e565702162acc3e65',
'ImageMetaProps': '1.17-54f21e339d153fe30be6b8999dd83148',
'Instance': '2.3-4f98ab23f4b0a25fabb1040c8f5edecc',
'InstanceAction': '1.1-f9f293e526b66fca0d05c3b3a2d13914',
'InstanceActionEvent': '1.1-e56a64fa4710e43ef7af2ad9d6028b33',

View File

@ -671,6 +671,13 @@ class LibvirtVifTestCase(test.NoDBTestCase):
if virt == 'parallels':
supported = (network_model.VIF_MODEL_RTL8139,
network_model.VIF_MODEL_E1000)
elif virt == 'qemu':
supported = (network_model.VIF_MODEL_LAN9118,
network_model.VIF_MODEL_NE2K_PCI,
network_model.VIF_MODEL_PCNET,
network_model.VIF_MODEL_RTL8139,
network_model.VIF_MODEL_E1000,
network_model.VIF_MODEL_SPAPR_VLAN)
else:
supported = (network_model.VIF_MODEL_NE2K_PCI,
network_model.VIF_MODEL_PCNET,

View File

@ -57,6 +57,7 @@ def is_vif_model_valid_for_virt(virt_type, vif_model):
network_model.VIF_MODEL_PCNET,
network_model.VIF_MODEL_RTL8139,
network_model.VIF_MODEL_E1000,
network_model.VIF_MODEL_LAN9118,
network_model.VIF_MODEL_SPAPR_VLAN],
'kvm': [network_model.VIF_MODEL_VIRTIO,
network_model.VIF_MODEL_NE2K_PCI,

View File

@ -0,0 +1,3 @@
---
features:
- Add support for LAN9118 as a valid nic for hw_vif_model property in qemu.