diff --git a/os_resource_classes/__init__.py b/os_resource_classes/__init__.py index 07b3082..53ecc01 100644 --- a/os_resource_classes/__init__.py +++ b/os_resource_classes/__init__.py @@ -64,6 +64,10 @@ STANDARDS = [ # guest. A dedicated CPU is a physical processor that has been marked # to be used for a single guest only 'PCPU', + # Resource class representing the number of guests a compute node can + # host with memory encrypted at the hardware level. See + # http://specs.openstack.org/openstack/nova-specs/specs/train/approved/amd-sev-libvirt-support.html + 'MEM_ENCRYPTION_CONTEXT', ] # Namespace used for custom resource classes diff --git a/os_resource_classes/tests/test_os_resource_classes.py b/os_resource_classes/tests/test_os_resource_classes.py index dd3e4e5..2976ce7 100644 --- a/os_resource_classes/tests/test_os_resource_classes.py +++ b/os_resource_classes/tests/test_os_resource_classes.py @@ -44,8 +44,8 @@ class TestOs_resource_classes(base.TestCase): of the STANDARDS list, otherwise database ids will get confused in the placement service. """ - expected_last_class = rc.PCPU - expected_length = 15 + expected_last_class = rc.MEM_ENCRYPTION_CONTEXT + expected_length = 16 self.assertEqual(expected_last_class, rc.STANDARDS[-1]) self.assertEqual(expected_length, len(rc.STANDARDS))