Report availability of stateless firmware support
This is the first step to support launching instances with stateless firmware. At this stage none of the virt drivers report the trait to support the feature. Depends-on: https://review.opendev.org/c/openstack/os-traits/+/908885 Partially-Implements: blueprint libvirt-stateless-firmware Change-Id: I4c1df950af11687ae5a52e4eba7943029ec36e69
This commit is contained in:
parent
7a7427691e
commit
b475f0f99b
@ -47,6 +47,7 @@ class ProviderTreeTests(integrated_helpers.ProviderUsageBaseTestCase):
|
|||||||
os_traits.COMPUTE_TRUSTED_CERTS,
|
os_traits.COMPUTE_TRUSTED_CERTS,
|
||||||
os_traits.COMPUTE_ADDRESS_SPACE_EMULATED,
|
os_traits.COMPUTE_ADDRESS_SPACE_EMULATED,
|
||||||
os_traits.COMPUTE_ADDRESS_SPACE_PASSTHROUGH,
|
os_traits.COMPUTE_ADDRESS_SPACE_PASSTHROUGH,
|
||||||
|
os_traits.COMPUTE_SECURITY_STATELESS_FIRMWARE,
|
||||||
]
|
]
|
||||||
])
|
])
|
||||||
|
|
||||||
|
@ -21829,6 +21829,13 @@ class LibvirtConnTestCase(test.NoDBTestCase,
|
|||||||
self.assertTrue(
|
self.assertTrue(
|
||||||
driver.capabilities.get('supports_address_space_emulated'))
|
driver.capabilities.get('supports_address_space_emulated'))
|
||||||
|
|
||||||
|
def test_update_host_specific_capabilities_without_stateless_firmware(
|
||||||
|
self):
|
||||||
|
driver = libvirt_driver.LibvirtDriver(fake.FakeVirtAPI())
|
||||||
|
driver._update_host_specific_capabilities()
|
||||||
|
self.assertFalse(
|
||||||
|
driver.capabilities.get('supports_stateless_firmware'))
|
||||||
|
|
||||||
@mock.patch.object(fakelibvirt.Connection, 'getLibVersion',
|
@mock.patch.object(fakelibvirt.Connection, 'getLibVersion',
|
||||||
return_value=versionutils.convert_version_to_int(
|
return_value=versionutils.convert_version_to_int(
|
||||||
libvirt_driver.MIN_LIBVIRT_MAXPHYSADDR))
|
libvirt_driver.MIN_LIBVIRT_MAXPHYSADDR))
|
||||||
|
@ -167,6 +167,8 @@ CAPABILITY_TRAITS_MAP = {
|
|||||||
os_traits.COMPUTE_ADDRESS_SPACE_PASSTHROUGH,
|
os_traits.COMPUTE_ADDRESS_SPACE_PASSTHROUGH,
|
||||||
"supports_address_space_emulated":
|
"supports_address_space_emulated":
|
||||||
os_traits.COMPUTE_ADDRESS_SPACE_EMULATED,
|
os_traits.COMPUTE_ADDRESS_SPACE_EMULATED,
|
||||||
|
"supports_stateless_firmware":
|
||||||
|
os_traits.COMPUTE_SECURITY_STATELESS_FIRMWARE,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -121,6 +121,7 @@ class FakeDriver(driver.ComputeDriver):
|
|||||||
"supports_remote_managed_ports": True,
|
"supports_remote_managed_ports": True,
|
||||||
"supports_address_space_passthrough": True,
|
"supports_address_space_passthrough": True,
|
||||||
"supports_address_space_emulated": True,
|
"supports_address_space_emulated": True,
|
||||||
|
"supports_stateless_firmware": True,
|
||||||
|
|
||||||
# Supported image types
|
# Supported image types
|
||||||
"supports_image_type_raw": True,
|
"supports_image_type_raw": True,
|
||||||
|
@ -163,6 +163,7 @@ class IronicDriver(virt_driver.ComputeDriver):
|
|||||||
"supports_remote_managed_ports": False,
|
"supports_remote_managed_ports": False,
|
||||||
"supports_address_space_passthrough": False,
|
"supports_address_space_passthrough": False,
|
||||||
"supports_address_space_emulated": False,
|
"supports_address_space_emulated": False,
|
||||||
|
"supports_stateless_firmware": False,
|
||||||
|
|
||||||
# Image type support flags
|
# Image type support flags
|
||||||
"supports_image_type_aki": False,
|
"supports_image_type_aki": False,
|
||||||
|
@ -74,6 +74,7 @@ class VMwareVCDriver(driver.ComputeDriver):
|
|||||||
"supports_remote_managed_ports": False,
|
"supports_remote_managed_ports": False,
|
||||||
"supports_address_space_passthrough": False,
|
"supports_address_space_passthrough": False,
|
||||||
"supports_address_space_emulated": False,
|
"supports_address_space_emulated": False,
|
||||||
|
"supports_stateless_firmware": False,
|
||||||
|
|
||||||
# Image type support flags
|
# Image type support flags
|
||||||
"supports_image_type_aki": False,
|
"supports_image_type_aki": False,
|
||||||
|
@ -49,6 +49,7 @@ class ZVMDriver(driver.ComputeDriver):
|
|||||||
"supports_remote_managed_ports": False,
|
"supports_remote_managed_ports": False,
|
||||||
"supports_address_space_passthrough": False,
|
"supports_address_space_passthrough": False,
|
||||||
"supports_address_space_emulated": False,
|
"supports_address_space_emulated": False,
|
||||||
|
"supports_stateless_firmware": False,
|
||||||
|
|
||||||
# Image type support flags
|
# Image type support flags
|
||||||
"supports_image_type_aki": False,
|
"supports_image_type_aki": False,
|
||||||
|
@ -52,7 +52,7 @@ psutil>=3.2.2 # BSD
|
|||||||
oslo.versionedobjects>=1.35.0 # Apache-2.0
|
oslo.versionedobjects>=1.35.0 # Apache-2.0
|
||||||
os-brick>=5.2 # Apache-2.0
|
os-brick>=5.2 # Apache-2.0
|
||||||
os-resource-classes>=1.1.0 # Apache-2.0
|
os-resource-classes>=1.1.0 # Apache-2.0
|
||||||
os-traits>=3.0.0 # Apache-2.0
|
os-traits>=3.1.0 # Apache-2.0
|
||||||
os-vif>=3.1.0 # Apache-2.0
|
os-vif>=3.1.0 # Apache-2.0
|
||||||
castellan>=0.16.0 # Apache-2.0
|
castellan>=0.16.0 # Apache-2.0
|
||||||
microversion-parse>=0.2.1 # Apache-2.0
|
microversion-parse>=0.2.1 # Apache-2.0
|
||||||
|
Loading…
Reference in New Issue
Block a user