Merge "[SR-IOV] Add support for ACCELERATOR_DIRECT VNIC type"

This commit is contained in:
Zuul 2021-03-10 11:11:18 +00:00 committed by Gerrit Code Review
commit 57af40eb31
3 changed files with 23 additions and 7 deletions

View File

@ -58,9 +58,12 @@ class SriovNicSwitchMechanismDriver(mech_agent.SimpleAgentMechanismDriverBase):
vif_details={portbindings.CAP_PORT_FILTER: False,
portbindings.VIF_DETAILS_CONNECTIVITY:
portbindings.CONNECTIVITY_L2},
supported_vnic_types=[portbindings.VNIC_DIRECT,
portbindings.VNIC_MACVTAP,
portbindings.VNIC_DIRECT_PHYSICAL]):
supported_vnic_types=[
portbindings.VNIC_DIRECT,
portbindings.VNIC_MACVTAP,
portbindings.VNIC_DIRECT_PHYSICAL,
portbindings.VNIC_ACCELERATOR_DIRECT,
]):
"""Initialize base class for SriovNicSwitch L2 agent type.
:param agent_type: Constant identifying agent type in agents_db

View File

@ -231,9 +231,11 @@ class SriovSwitchMechVnicTypesTestCase(SriovNicSwitchMechanismBaseTestCase):
mech_driver.SriovNicSwitchMechanismDriver(
supported_vnic_types=self.override_vnic_types)
self.default_supported_vnics = [
portbindings.VNIC_DIRECT,
portbindings.VNIC_MACVTAP,
portbindings.VNIC_DIRECT_PHYSICAL]
portbindings.VNIC_DIRECT,
portbindings.VNIC_MACVTAP,
portbindings.VNIC_DIRECT_PHYSICAL,
portbindings.VNIC_ACCELERATOR_DIRECT,
]
self.prohibit_list_cfg = {
'SRIOV_DRIVER': {
'vnic_type_prohibit_list': []
@ -284,7 +286,9 @@ class SriovSwitchMechVnicTypesTestCase(SriovNicSwitchMechanismBaseTestCase):
self.prohibit_list_cfg['SRIOV_DRIVER']['vnic_type_prohibit_list'] = \
[portbindings.VNIC_DIRECT,
portbindings.VNIC_MACVTAP,
portbindings.VNIC_DIRECT_PHYSICAL]
portbindings.VNIC_DIRECT_PHYSICAL,
portbindings.VNIC_ACCELERATOR_DIRECT,
]
fake_conf = cfg.CONF
fake_conf_fixture = base.MechDriverConfFixture(

View File

@ -0,0 +1,9 @@
---
features:
- |
Added support in SR-IOV agent for ``accelerator-direct`` VNIC
type. This type represents a port that supports any kind of
hardware acceleration and is provided by Cyborg
(https://wiki.openstack.org/wiki/Cyborg). `RFE: 1909100
<https://bugs.launchpad.net/neutron/+bug/1909100>`_.
``accelerator-direct-physical`` is still not supported.