Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Robert, Sandhya, I have pushed the reference implementation SriovAgentMechanismDriverBase as part the following WIP: https://review.openstack.org/#/c/74464/ The code is in mech_agent.py, and very simple code for mech_sriov_nic_switch.py. Please take a look and review. BR, Irena -Original Message- From: Irena Berezovsky [mailto:ire...@mellanox.com] Sent: Wednesday, March 05, 2014 9:04 AM To: Robert Li (baoli); Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Robert, Seems to me that many code lines are duplicated following your proposal. For agent based MDs, I would prefer to inherit from SimpleAgentMechanismDriverBase and add there verify method for supported_pci_vendor_info. Specific MD will pass the list of supported pci_vendor_info list. The 'try_to_bind_segment_for_agent' method will call 'supported_pci_vendor_info', and if supported continue with binding flow. Maybe instead of a decorator method, it should be just an utility method? I think that the check for supported vnic_type and pci_vendor info support, should be done in order to see if MD should bind the port. If the answer is Yes, no more checks are required. Coming back to the question I asked earlier, for non-agent MD, how would you deal with updates after port is bound, like 'admin_state_up' changes? I'll try to push some reference code later today. BR, Irena -Original Message- From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Wednesday, March 05, 2014 4:46 AM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Sandhya, I agree with you except that I think that the class should inherit from MechanismDriver. I took a crack at it, and here is what I got: # Copyright (c) 2014 OpenStack Foundation # All Rights Reserved. # #Licensed under the Apache License, Version 2.0 (the License); you may #not use this file except in compliance with the License. You may obtain #a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # #Unless required by applicable law or agreed to in writing, software #distributed under the License is distributed on an AS IS BASIS, WITHOUT #WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the #License for the specific language governing permissions and limitations #under the License. from abc import ABCMeta, abstractmethod import functools import six from neutron.extensions import portbindings from neutron.openstack.common import log from neutron.plugins.ml2 import driver_api as api LOG = log.getLogger(__name__) DEFAULT_VNIC_TYPES_SUPPORTED = [portbindings.VNIC_DIRECT, portbindings.VNIC_MACVTAP] def check_vnic_type_and_vendor_info(f): @functools.wraps(f) def wrapper(self, context): vnic_type = context.current.get(portbindings.VNIC_TYPE, portbindings.VNIC_NORMAL) if vnic_type not in self.supported_vnic_types: LOG.debug(_(%(func_name)s: skipped due to unsupported vnic_type: %(vnic_type)s), {'func_name': f.func_name, 'vnic_type': vnic_type}) return if self.supported_pci_vendor_info: profile = context.current.get(portbindings.PROFILE, {}) if not profile: LOG.debug(_(%s: Missing profile in port binding), f.func_name) return pci_vendor_info = profile.get('pci_vendor_info') if not pci_vendor_info: LOG.debug(_(%s: Missing pci vendor info in profile), f.func_name) return if pci_vendor_info not in self.supported_pci_vendor_info: LOG.debug(_(%(func_name)s: unsupported pci vendor info: %(info)s), {'func_name': f.func_name, 'info': pci_vendor_info}) return f(self, context) return wrapper @six.add_metaclass(ABCMeta) class SriovMechanismDriverBase(api.MechanismDriver): Base class for drivers that supports SR-IOV The SriovMechanismDriverBase provides common code for mechanism drivers that supports SR-IOV. Such a driver may or may not require an agent to be running on the port's host. MechanismDrivers that uses this base class and requires an agent must pass the agent type to __init__(), and must implement try_to_bind_segment_for_agent() and check_segment_for_agent(). MechanismDrivers that uses this base class may provide supported vendor information, and must provide the supported vnic types
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Irena, My MD has to take care of admin state changes since I have no L2 agent. I think that is what Bob also alluded to. That being said, I am not doing anything specific to handle admin_state_up/down. The SR-IOV port on my device is always going to be up, for now atleast. Thanks, Sandhya On 3/5/14 1:56 AM, Irena Berezovsky ire...@mellanox.com wrote: Hi Robert, Seems to me that many code lines are duplicated following your proposal. For agent based MDs, I would prefer to inherit from SimpleAgentMechanismDriverBase and add there verify method for supported_pci_vendor_info. Specific MD will pass the list of supported pci_vendor_info list. The 'try_to_bind_segment_for_agent' method will call 'supported_pci_vendor_info', and if supported continue with binding flow. Maybe instead of a decorator method, it should be just an utility method? I think that the check for supported vnic_type and pci_vendor info support, should be done in order to see if MD should bind the port. If the answer is Yes, no more checks are required. Coming back to the question I asked earlier, for non-agent MD, how would you deal with updates after port is bound, like 'admin_state_up' changes? I'll try to push some reference code later today. BR, Irena -Original Message- From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Wednesday, March 05, 2014 4:46 AM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Sandhya, I agree with you except that I think that the class should inherit from MechanismDriver. I took a crack at it, and here is what I got: # Copyright (c) 2014 OpenStack Foundation # All Rights Reserved. # #Licensed under the Apache License, Version 2.0 (the License); you may #not use this file except in compliance with the License. You may obtain #a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # #Unless required by applicable law or agreed to in writing, software #distributed under the License is distributed on an AS IS BASIS, WITHOUT #WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the #License for the specific language governing permissions and limitations #under the License. from abc import ABCMeta, abstractmethod import functools import six from neutron.extensions import portbindings from neutron.openstack.common import log from neutron.plugins.ml2 import driver_api as api LOG = log.getLogger(__name__) DEFAULT_VNIC_TYPES_SUPPORTED = [portbindings.VNIC_DIRECT, portbindings.VNIC_MACVTAP] def check_vnic_type_and_vendor_info(f): @functools.wraps(f) def wrapper(self, context): vnic_type = context.current.get(portbindings.VNIC_TYPE, portbindings.VNIC_NORMAL) if vnic_type not in self.supported_vnic_types: LOG.debug(_(%(func_name)s: skipped due to unsupported vnic_type: %(vnic_type)s), {'func_name': f.func_name, 'vnic_type': vnic_type}) return if self.supported_pci_vendor_info: profile = context.current.get(portbindings.PROFILE, {}) if not profile: LOG.debug(_(%s: Missing profile in port binding), f.func_name) return pci_vendor_info = profile.get('pci_vendor_info') if not pci_vendor_info: LOG.debug(_(%s: Missing pci vendor info in profile), f.func_name) return if pci_vendor_info not in self.supported_pci_vendor_info: LOG.debug(_(%(func_name)s: unsupported pci vendor info: %(info)s), {'func_name': f.func_name, 'info': pci_vendor_info}) return f(self, context) return wrapper @six.add_metaclass(ABCMeta) class SriovMechanismDriverBase(api.MechanismDriver): Base class for drivers that supports SR-IOV The SriovMechanismDriverBase provides common code for mechanism drivers that supports SR-IOV. Such a driver may or may not require an agent to be running on the port's host. MechanismDrivers that uses this base class and requires an agent must pass the agent type to __init__(), and must implement try_to_bind_segment_for_agent() and check_segment_for_agent(). MechanismDrivers that uses this base class may provide supported vendor information, and must provide the supported vnic types. def __init__(self, agent_type=None, supported_pci_vendor_info=[], supported_vnic_types=DEFAULT_VNIC_TYPES_SUPPORTED): Initialize base class for SR-IOV capable Mechanism Drivers :param agent_type: Constant identifying agent type in agents_db
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Irena, The main reason for me to do it that way is how vif_details should be setup in our case. Do you need vlan in vif_details? The behavior in the existing base classes is that the vif_details is set during the driver init time. In our case, it needs to be setup during bind_port(). thanks, Robert On 3/5/14 7:37 AM, Irena Berezovsky ire...@mellanox.com wrote: Hi Robert, Sandhya, I have pushed the reference implementation SriovAgentMechanismDriverBase as part the following WIP: https://review.openstack.org/#/c/74464/ The code is in mech_agent.py, and very simple code for mech_sriov_nic_switch.py. Please take a look and review. BR, Irena -Original Message- From: Irena Berezovsky [mailto:ire...@mellanox.com] Sent: Wednesday, March 05, 2014 9:04 AM To: Robert Li (baoli); Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Robert, Seems to me that many code lines are duplicated following your proposal. For agent based MDs, I would prefer to inherit from SimpleAgentMechanismDriverBase and add there verify method for supported_pci_vendor_info. Specific MD will pass the list of supported pci_vendor_info list. The 'try_to_bind_segment_for_agent' method will call 'supported_pci_vendor_info', and if supported continue with binding flow. Maybe instead of a decorator method, it should be just an utility method? I think that the check for supported vnic_type and pci_vendor info support, should be done in order to see if MD should bind the port. If the answer is Yes, no more checks are required. Coming back to the question I asked earlier, for non-agent MD, how would you deal with updates after port is bound, like 'admin_state_up' changes? I'll try to push some reference code later today. BR, Irena -Original Message- From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Wednesday, March 05, 2014 4:46 AM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Sandhya, I agree with you except that I think that the class should inherit from MechanismDriver. I took a crack at it, and here is what I got: # Copyright (c) 2014 OpenStack Foundation # All Rights Reserved. # #Licensed under the Apache License, Version 2.0 (the License); you may #not use this file except in compliance with the License. You may obtain #a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # #Unless required by applicable law or agreed to in writing, software #distributed under the License is distributed on an AS IS BASIS, WITHOUT #WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the #License for the specific language governing permissions and limitations #under the License. from abc import ABCMeta, abstractmethod import functools import six from neutron.extensions import portbindings from neutron.openstack.common import log from neutron.plugins.ml2 import driver_api as api LOG = log.getLogger(__name__) DEFAULT_VNIC_TYPES_SUPPORTED = [portbindings.VNIC_DIRECT, portbindings.VNIC_MACVTAP] def check_vnic_type_and_vendor_info(f): @functools.wraps(f) def wrapper(self, context): vnic_type = context.current.get(portbindings.VNIC_TYPE, portbindings.VNIC_NORMAL) if vnic_type not in self.supported_vnic_types: LOG.debug(_(%(func_name)s: skipped due to unsupported vnic_type: %(vnic_type)s), {'func_name': f.func_name, 'vnic_type': vnic_type}) return if self.supported_pci_vendor_info: profile = context.current.get(portbindings.PROFILE, {}) if not profile: LOG.debug(_(%s: Missing profile in port binding), f.func_name) return pci_vendor_info = profile.get('pci_vendor_info') if not pci_vendor_info: LOG.debug(_(%s: Missing pci vendor info in profile), f.func_name) return if pci_vendor_info not in self.supported_pci_vendor_info: LOG.debug(_(%(func_name)s: unsupported pci vendor info: %(info)s), {'func_name': f.func_name, 'info': pci_vendor_info}) return f(self, context) return wrapper @six.add_metaclass(ABCMeta) class SriovMechanismDriverBase(api.MechanismDriver): Base class for drivers that supports SR-IOV The SriovMechanismDriverBase provides common code for mechanism drivers that supports SR-IOV. Such a driver may or may not require an agent to be running
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Robert, I think what you mentioned can be achieved by calling into specific MD method from SriovAgentMechanismDriverBase .try_to_bind_segment_for_agent mehod, maybe something like 'get_vif_details' before it calls to context.set_binding. Would you mind to continue discussion over patch gerrit review https://review.openstack.org/#/c/74464/ ? I think it will be easier to follow up the comments and decisions. Thanks, Irena -Original Message- From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Wednesday, March 05, 2014 6:10 PM To: Irena Berezovsky; OpenStack Development Mailing List (not for usage questions); Sandhya Dasu (sadasu); Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Irena, The main reason for me to do it that way is how vif_details should be setup in our case. Do you need vlan in vif_details? The behavior in the existing base classes is that the vif_details is set during the driver init time. In our case, it needs to be setup during bind_port(). thanks, Robert On 3/5/14 7:37 AM, Irena Berezovsky ire...@mellanox.com wrote: Hi Robert, Sandhya, I have pushed the reference implementation SriovAgentMechanismDriverBase as part the following WIP: https://review.openstack.org/#/c/74464/ The code is in mech_agent.py, and very simple code for mech_sriov_nic_switch.py. Please take a look and review. BR, Irena -Original Message- From: Irena Berezovsky [mailto:ire...@mellanox.com] Sent: Wednesday, March 05, 2014 9:04 AM To: Robert Li (baoli); Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Robert, Seems to me that many code lines are duplicated following your proposal. For agent based MDs, I would prefer to inherit from SimpleAgentMechanismDriverBase and add there verify method for supported_pci_vendor_info. Specific MD will pass the list of supported pci_vendor_info list. The 'try_to_bind_segment_for_agent' method will call 'supported_pci_vendor_info', and if supported continue with binding flow. Maybe instead of a decorator method, it should be just an utility method? I think that the check for supported vnic_type and pci_vendor info support, should be done in order to see if MD should bind the port. If the answer is Yes, no more checks are required. Coming back to the question I asked earlier, for non-agent MD, how would you deal with updates after port is bound, like 'admin_state_up' changes? I'll try to push some reference code later today. BR, Irena -Original Message- From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Wednesday, March 05, 2014 4:46 AM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Sandhya, I agree with you except that I think that the class should inherit from MechanismDriver. I took a crack at it, and here is what I got: # Copyright (c) 2014 OpenStack Foundation # All Rights Reserved. # #Licensed under the Apache License, Version 2.0 (the License); you may #not use this file except in compliance with the License. You may obtain #a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # #Unless required by applicable law or agreed to in writing, software #distributed under the License is distributed on an AS IS BASIS, WITHOUT #WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the #License for the specific language governing permissions and limitations #under the License. from abc import ABCMeta, abstractmethod import functools import six from neutron.extensions import portbindings from neutron.openstack.common import log from neutron.plugins.ml2 import driver_api as api LOG = log.getLogger(__name__) DEFAULT_VNIC_TYPES_SUPPORTED = [portbindings.VNIC_DIRECT, portbindings.VNIC_MACVTAP] def check_vnic_type_and_vendor_info(f): @functools.wraps(f) def wrapper(self, context): vnic_type = context.current.get(portbindings.VNIC_TYPE, portbindings.VNIC_NORMAL) if vnic_type not in self.supported_vnic_types: LOG.debug(_(%(func_name)s: skipped due to unsupported vnic_type: %(vnic_type)s), {'func_name': f.func_name, 'vnic_type': vnic_type}) return if self.supported_pci_vendor_info: profile = context.current.get(portbindings.PROFILE, {}) if not profile: LOG.debug(_(%s: Missing profile in port binding), f.func_name) return pci_vendor_info = profile.get
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi, During today's meeting, it was decided that we would re-purpose Robert's https://blueprints.launchpad.net/neutron/+spec/pci-passthrough-sriov to take care of adding a Base class to take care of common processing for SR-IOV ports. This class would: 1. Inherits from AgentMechanismDriverBase. 2. Implements bind_port() where the binding:profile would be checked to see if the port's vnic_type is VNIC_DIRECT or VNIC_MACVTAP. 3. Also checks to see that port belongs to vendor/product that supports SR-IOV. 4. This class could be used by MDs that may or may not have a valid L2 agent. 5. Implement validate_port_binding(). This will always return True for Mds that do not have an L2 agent. Please let me know if I left out anything. Thanks, Sandhya On 2/25/14 9:18 AM, Sandhya Dasu (sadasu) sad...@cisco.com wrote: Hi, As a follow up from today's IRC, Irena, are you looking to write the below mentioned Base/Mixin class that inherits from AgentMechanismDriverBase class? When you mentioned port state, were you referring to the validate_port_binding() method? Pls clarify. Thanks, Sandhya On 2/6/14 7:57 AM, Sandhya Dasu (sadasu) sad...@cisco.com wrote: Hi Bob and Irena, Thanks for the clarification. Irena, I am not opposed to a SriovMechanismDriverBase/Mixin approach, but I want to first figure out how much common functionality there is. Have you already looked at this? Thanks, Sandhya On 2/5/14 1:58 AM, Irena Berezovsky ire...@mellanox.com wrote: Please see inline my understanding -Original Message- From: Robert Kukura [mailto:rkuk...@redhat.com] Sent: Tuesday, February 04, 2014 11:57 PM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports On 02/04/2014 04:35 PM, Sandhya Dasu (sadasu) wrote: Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. I'll try, but I think these questions might be more about how the various SR-IOV implementations will work than about ML2 itself... 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? I think whether or not to use an L2 agent depends on the specific SR-IOV implementation. Some (Mellanox?) might use an L2 agent, while others (Cisco?) might put information in binding:vif_details that lets the nova VIF driver take care of setting up the port without an L2 agent. [IrenaB] Based on VIF_Type that MD defines, and going forward with other binding:vif_details attributes, VIFDriver should do the VIF pluging part. As for required networking configuration is required, it is usually done either by L2 Agent or external Controller, depends on MD. 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? My guess is that those SR-IOV MechanismDrivers that use an L2 agent would inherit the AgentMechanismDriverBase class if it provides useful functionality, but any MechanismDriver implementation is free to not use this base class if its not applicable. I'm not sure if an SriovMechanismDriverBase (or SriovMechanismDriverMixin) class is being planned, and how that would relate to AgentMechanismDriverBase. [IrenaB] Agree with Bob, and as I stated before I think there is a need for SriovMechanismDriverBase/Mixin that provides all the generic functionality and helper methods that are common to SRIOV ports. -Bob Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
mentioned Base/Mixin class that inherits from AgentMechanismDriverBase class? When you mentioned port state, were you referring to the validate_port_binding() method? Pls clarify. Thanks, Sandhya On 2/6/14 7:57 AM, Sandhya Dasu (sadasu) sad...@cisco.com wrote: Hi Bob and Irena, Thanks for the clarification. Irena, I am not opposed to a SriovMechanismDriverBase/Mixin approach, but I want to first figure out how much common functionality there is. Have you already looked at this? Thanks, Sandhya On 2/5/14 1:58 AM, Irena Berezovsky ire...@mellanox.com wrote: Please see inline my understanding -Original Message- From: Robert Kukura [mailto:rkuk...@redhat.com] Sent: Tuesday, February 04, 2014 11:57 PM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports On 02/04/2014 04:35 PM, Sandhya Dasu (sadasu) wrote: Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. I'll try, but I think these questions might be more about how the various SR-IOV implementations will work than about ML2 itself... 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? I think whether or not to use an L2 agent depends on the specific SR-IOV implementation. Some (Mellanox?) might use an L2 agent, while others (Cisco?) might put information in binding:vif_details that lets the nova VIF driver take care of setting up the port without an L2 agent. [IrenaB] Based on VIF_Type that MD defines, and going forward with other binding:vif_details attributes, VIFDriver should do the VIF pluging part. As for required networking configuration is required, it is usually done either by L2 Agent or external Controller, depends on MD. 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? My guess is that those SR-IOV MechanismDrivers that use an L2 agent would inherit the AgentMechanismDriverBase class if it provides useful functionality, but any MechanismDriver implementation is free to not use this base class if its not applicable. I'm not sure if an SriovMechanismDriverBase (or SriovMechanismDriverMixin) class is being planned, and how that would relate to AgentMechanismDriverBase. [IrenaB] Agree with Bob, and as I stated before I think there is a need for SriovMechanismDriverBase/Mixin that provides all the generic functionality and helper methods that are common to SRIOV ports. -Bob Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi all, Both openstack-meeting and openstack-meeting-alt are available today. Lets meet at UTC 2000 @ openstack-meeting-alt. Thanks, Sandhya From: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com Date: Monday, February 3, 2014 12:52 AM To: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Robert, Seems to me that many code lines are duplicated following your proposal. For agent based MDs, I would prefer to inherit from SimpleAgentMechanismDriverBase and add there verify method for supported_pci_vendor_info. Specific MD will pass the list of supported pci_vendor_info list. The 'try_to_bind_segment_for_agent' method will call 'supported_pci_vendor_info', and if supported continue with binding flow. Maybe instead of a decorator method, it should be just an utility method? I think that the check for supported vnic_type and pci_vendor info support, should be done in order to see if MD should bind the port. If the answer is Yes, no more checks are required. Coming back to the question I asked earlier, for non-agent MD, how would you deal with updates after port is bound, like 'admin_state_up' changes? I'll try to push some reference code later today. BR, Irena -Original Message- From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Wednesday, March 05, 2014 4:46 AM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Kukura; Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi Sandhya, I agree with you except that I think that the class should inherit from MechanismDriver. I took a crack at it, and here is what I got: # Copyright (c) 2014 OpenStack Foundation # All Rights Reserved. # #Licensed under the Apache License, Version 2.0 (the License); you may #not use this file except in compliance with the License. You may obtain #a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # #Unless required by applicable law or agreed to in writing, software #distributed under the License is distributed on an AS IS BASIS, WITHOUT #WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the #License for the specific language governing permissions and limitations #under the License. from abc import ABCMeta, abstractmethod import functools import six from neutron.extensions import portbindings from neutron.openstack.common import log from neutron.plugins.ml2 import driver_api as api LOG = log.getLogger(__name__) DEFAULT_VNIC_TYPES_SUPPORTED = [portbindings.VNIC_DIRECT, portbindings.VNIC_MACVTAP] def check_vnic_type_and_vendor_info(f): @functools.wraps(f) def wrapper(self, context): vnic_type = context.current.get(portbindings.VNIC_TYPE, portbindings.VNIC_NORMAL) if vnic_type not in self.supported_vnic_types: LOG.debug(_(%(func_name)s: skipped due to unsupported vnic_type: %(vnic_type)s), {'func_name': f.func_name, 'vnic_type': vnic_type}) return if self.supported_pci_vendor_info: profile = context.current.get(portbindings.PROFILE, {}) if not profile: LOG.debug(_(%s: Missing profile in port binding), f.func_name) return pci_vendor_info = profile.get('pci_vendor_info') if not pci_vendor_info: LOG.debug(_(%s: Missing pci vendor info in profile), f.func_name) return if pci_vendor_info not in self.supported_pci_vendor_info: LOG.debug(_(%(func_name)s: unsupported pci vendor info: %(info)s), {'func_name': f.func_name, 'info': pci_vendor_info}) return f(self, context) return wrapper @six.add_metaclass(ABCMeta) class SriovMechanismDriverBase(api.MechanismDriver): Base class for drivers that supports SR-IOV The SriovMechanismDriverBase provides common code for mechanism drivers that supports SR-IOV. Such a driver may or may not require an agent to be running on the port's host. MechanismDrivers that uses this base class and requires an agent must pass the agent type to __init__(), and must implement try_to_bind_segment_for_agent() and check_segment_for_agent(). MechanismDrivers that uses this base class may provide supported vendor information, and must provide the supported vnic types. def __init__(self, agent_type=None, supported_pci_vendor_info=[], supported_vnic_types=DEFAULT_VNIC_TYPES_SUPPORTED): Initialize base class for SR-IOV capable Mechanism Drivers :param agent_type: Constant identifying agent type in agents_db :param supported_pci_vendor_info: a list of vendor_id:product_id :param supported_vnic_types: The binding:vnic_type values we can bind self.supported_pci_vendor_info = supported_pci_vendor_info self.agent_type = agent_type self.supported_vnic_types = supported_vnic_types def initialize(self
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi, As a follow up from today's IRC, Irena, are you looking to write the below mentioned Base/Mixin class that inherits from AgentMechanismDriverBase class? When you mentioned port state, were you referring to the validate_port_binding() method? Pls clarify. Thanks, Sandhya On 2/6/14 7:57 AM, Sandhya Dasu (sadasu) sad...@cisco.com wrote: Hi Bob and Irena, Thanks for the clarification. Irena, I am not opposed to a SriovMechanismDriverBase/Mixin approach, but I want to first figure out how much common functionality there is. Have you already looked at this? Thanks, Sandhya On 2/5/14 1:58 AM, Irena Berezovsky ire...@mellanox.com wrote: Please see inline my understanding -Original Message- From: Robert Kukura [mailto:rkuk...@redhat.com] Sent: Tuesday, February 04, 2014 11:57 PM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports On 02/04/2014 04:35 PM, Sandhya Dasu (sadasu) wrote: Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. I'll try, but I think these questions might be more about how the various SR-IOV implementations will work than about ML2 itself... 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? I think whether or not to use an L2 agent depends on the specific SR-IOV implementation. Some (Mellanox?) might use an L2 agent, while others (Cisco?) might put information in binding:vif_details that lets the nova VIF driver take care of setting up the port without an L2 agent. [IrenaB] Based on VIF_Type that MD defines, and going forward with other binding:vif_details attributes, VIFDriver should do the VIF pluging part. As for required networking configuration is required, it is usually done either by L2 Agent or external Controller, depends on MD. 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? My guess is that those SR-IOV MechanismDrivers that use an L2 agent would inherit the AgentMechanismDriverBase class if it provides useful functionality, but any MechanismDriver implementation is free to not use this base class if its not applicable. I'm not sure if an SriovMechanismDriverBase (or SriovMechanismDriverMixin) class is being planned, and how that would relate to AgentMechanismDriverBase. [IrenaB] Agree with Bob, and as I stated before I think there is a need for SriovMechanismDriverBase/Mixin that provides all the generic functionality and helper methods that are common to SRIOV ports. -Bob Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi all, Both openstack-meeting and openstack-meeting-alt are available today. Lets meet at UTC 2000 @ openstack-meeting-alt. Thanks, Sandhya From: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com Date: Monday, February 3, 2014 12:52 AM To: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Sandhya, I mentioned the port state with regards to expected operation that can be applied to neutron port after neutron port is already bound to certain virtual interface. Since for my case, there will be neutron L2 agent on Host, it will manage port admin state locally. I am not sure how it should work for your case, and if you need L2 agent for this. BR, Irena -Original Message- From: Sandhya Dasu (sadasu) [mailto:sad...@cisco.com] Sent: Tuesday, February 25, 2014 4:19 PM To: OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Kukura; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports Hi, As a follow up from today's IRC, Irena, are you looking to write the below mentioned Base/Mixin class that inherits from AgentMechanismDriverBase class? When you mentioned port state, were you referring to the validate_port_binding() method? Pls clarify. Thanks, Sandhya On 2/6/14 7:57 AM, Sandhya Dasu (sadasu) sad...@cisco.com wrote: Hi Bob and Irena, Thanks for the clarification. Irena, I am not opposed to a SriovMechanismDriverBase/Mixin approach, but I want to first figure out how much common functionality there is. Have you already looked at this? Thanks, Sandhya On 2/5/14 1:58 AM, Irena Berezovsky ire...@mellanox.com wrote: Please see inline my understanding -Original Message- From: Robert Kukura [mailto:rkuk...@redhat.com] Sent: Tuesday, February 04, 2014 11:57 PM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports On 02/04/2014 04:35 PM, Sandhya Dasu (sadasu) wrote: Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. I'll try, but I think these questions might be more about how the various SR-IOV implementations will work than about ML2 itself... 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? I think whether or not to use an L2 agent depends on the specific SR-IOV implementation. Some (Mellanox?) might use an L2 agent, while others (Cisco?) might put information in binding:vif_details that lets the nova VIF driver take care of setting up the port without an L2 agent. [IrenaB] Based on VIF_Type that MD defines, and going forward with other binding:vif_details attributes, VIFDriver should do the VIF pluging part. As for required networking configuration is required, it is usually done either by L2 Agent or external Controller, depends on MD. 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? My guess is that those SR-IOV MechanismDrivers that use an L2 agent would inherit the AgentMechanismDriverBase class if it provides useful functionality, but any MechanismDriver implementation is free to not use this base class if its not applicable. I'm not sure if an SriovMechanismDriverBase (or SriovMechanismDriverMixin) class is being planned, and how that would relate to AgentMechanismDriverBase. [IrenaB] Agree with Bob, and as I stated before I think there is a need for SriovMechanismDriverBase/Mixin that provides all the generic functionality and helper methods that are common to SRIOV ports. -Bob Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi Bob and Irena, Thanks for the clarification. Irena, I am not opposed to a SriovMechanismDriverBase/Mixin approach, but I want to first figure out how much common functionality there is. Have you already looked at this? Thanks, Sandhya On 2/5/14 1:58 AM, Irena Berezovsky ire...@mellanox.com wrote: Please see inline my understanding -Original Message- From: Robert Kukura [mailto:rkuk...@redhat.com] Sent: Tuesday, February 04, 2014 11:57 PM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports On 02/04/2014 04:35 PM, Sandhya Dasu (sadasu) wrote: Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. I'll try, but I think these questions might be more about how the various SR-IOV implementations will work than about ML2 itself... 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? I think whether or not to use an L2 agent depends on the specific SR-IOV implementation. Some (Mellanox?) might use an L2 agent, while others (Cisco?) might put information in binding:vif_details that lets the nova VIF driver take care of setting up the port without an L2 agent. [IrenaB] Based on VIF_Type that MD defines, and going forward with other binding:vif_details attributes, VIFDriver should do the VIF pluging part. As for required networking configuration is required, it is usually done either by L2 Agent or external Controller, depends on MD. 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? My guess is that those SR-IOV MechanismDrivers that use an L2 agent would inherit the AgentMechanismDriverBase class if it provides useful functionality, but any MechanismDriver implementation is free to not use this base class if its not applicable. I'm not sure if an SriovMechanismDriverBase (or SriovMechanismDriverMixin) class is being planned, and how that would relate to AgentMechanismDriverBase. [IrenaB] Agree with Bob, and as I stated before I think there is a need for SriovMechanismDriverBase/Mixin that provides all the generic functionality and helper methods that are common to SRIOV ports. -Bob Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi all, Both openstack-meeting and openstack-meeting-alt are available today. Lets meet at UTC 2000 @ openstack-meeting-alt. Thanks, Sandhya From: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com Date: Monday, February 3, 2014 12:52 AM To: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: RE: [openstack-dev] [nova][neutron] PCI pass-through SRIOV on Jan. 30th Hi Sandhya, Can you please elaborate how do you suggest to extend the below bp for SRIOV Ports managed by different Mechanism Driver? I am
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? Thanks, Sandhya From: Sandhya Dasu sad...@cisco.commailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.orgmailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.orgmailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.commailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.commailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.commailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.commailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.commailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.orgmailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.commailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.commailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.commailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.orgmailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.commailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi all, Both openstack-meeting and openstack-meeting-alt are available today. Lets meet at UTC 2000 @ openstack-meeting-alt. Thanks, Sandhya From: Irena Berezovsky ire...@mellanox.commailto:ire...@mellanox.com Date: Monday, February 3, 2014 12:52 AM To: Sandhya Dasu sad...@cisco.commailto:sad...@cisco.com, Robert Li (baoli) ba...@cisco.commailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.commailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.orgmailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.commailto:brbo...@cisco.com Subject: RE: [openstack-dev] [nova][neutron] PCI pass-through SRIOV on Jan. 30th Hi Sandhya, Can you please elaborate how do you suggest to extend the below bp for SRIOV Ports managed by different Mechanism Driver? I am not biased to any specific direction here, just think we need common layer for managing SRIOV port at neutron, since there is a common pass between nova and neutron. BR, Irena From: Sandhya Dasu (sadasu) [mailto:sad...@cisco.com] Sent: Friday, January 31, 2014 6:46 PM To: Irena Berezovsky; Robert Li (baoli); Robert Kukura; OpenStack Development Mailing List (not for usage questions); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV on Jan. 30th Hi Irena, I was initially looking at https://blueprints.launchpad.net/neutron/+spec/ml2-typedriver-extra-port-info to take care of the extra information required to set up the SR-IOV port. When the scope of the BP was being decided, we had very little info about our own design so I didn't give any feedback about SR-IOV ports. But, I feel that this is the direction we should be going. Maybe we should target this in Juno. Introducing, SRIOVPortProfileMixin would be creating yet another way to take care of extra port config. Let me know what you think. Thanks, Sandhya From: Irena Berezovsky ire...@mellanox.commailto:ire...@mellanox.com Date: Thursday, January 30, 2014 4:13 PM To: Robert Li (baoli) ba...@cisco.commailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.commailto:rkuk...@redhat.com, Sandhya Dasu sad...@cisco.commailto:sad...@cisco.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.orgmailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.commailto:brbo...@cisco.com Subject: RE: [openstack-dev] [nova][neutron] PCI pass-through SRIOV on Jan. 30th Robert, Thank you very much for the summary. Please, see inline From: Robert Li (baoli) [mailto:ba...@cisco.com] Sent: Thursday, January 30, 2014 10:45 PM To: Robert Kukura; Sandhya Dasu (sadasu); Irena Berezovsky; OpenStack Development Mailing List (not for usage questions); Brian Bowen (brbowen) Subject: [openstack-dev] [nova][neutron] PCI pass-through SRIOV on Jan. 30th Hi, We made a lot of progress today. We agreed that: -- vnic_type will be a top level attribute
Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports
Please see inline my understanding -Original Message- From: Robert Kukura [mailto:rkuk...@redhat.com] Sent: Tuesday, February 04, 2014 11:57 PM To: Sandhya Dasu (sadasu); OpenStack Development Mailing List (not for usage questions); Irena Berezovsky; Robert Li (baoli); Brian Bowen (brbowen) Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV binding of ports On 02/04/2014 04:35 PM, Sandhya Dasu (sadasu) wrote: Hi, I have a couple of questions for ML2 experts regarding support of SR-IOV ports. I'll try, but I think these questions might be more about how the various SR-IOV implementations will work than about ML2 itself... 1. The SR-IOV ports would not be managed by ova or linuxbridge L2 agents. So, how does a MD for SR-IOV ports bind/unbind its ports to the host? Will it just be a db update? I think whether or not to use an L2 agent depends on the specific SR-IOV implementation. Some (Mellanox?) might use an L2 agent, while others (Cisco?) might put information in binding:vif_details that lets the nova VIF driver take care of setting up the port without an L2 agent. [IrenaB] Based on VIF_Type that MD defines, and going forward with other binding:vif_details attributes, VIFDriver should do the VIF pluging part. As for required networking configuration is required, it is usually done either by L2 Agent or external Controller, depends on MD. 2. Also, how do we handle the functionality in mech_agent.py, within the SR-IOV context? My guess is that those SR-IOV MechanismDrivers that use an L2 agent would inherit the AgentMechanismDriverBase class if it provides useful functionality, but any MechanismDriver implementation is free to not use this base class if its not applicable. I'm not sure if an SriovMechanismDriverBase (or SriovMechanismDriverMixin) class is being planned, and how that would relate to AgentMechanismDriverBase. [IrenaB] Agree with Bob, and as I stated before I think there is a need for SriovMechanismDriverBase/Mixin that provides all the generic functionality and helper methods that are common to SRIOV ports. -Bob Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 3:14 PM To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi, Since, openstack-meeting-alt seems to be in use, baoli and myself are moving to openstack-meeting. Hopefully, Bob Kukura Irena can join soon. Thanks, Sandhya From: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com Reply-To: OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org Date: Monday, February 3, 2014 1:26 PM To: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: Re: [openstack-dev] [nova][neutron] PCI pass-through SRIOV extra hr of discussion today Hi all, Both openstack-meeting and openstack-meeting-alt are available today. Lets meet at UTC 2000 @ openstack-meeting-alt. Thanks, Sandhya From: Irena Berezovsky ire...@mellanox.com mailto:ire...@mellanox.com Date: Monday, February 3, 2014 12:52 AM To: Sandhya Dasu sad...@cisco.com mailto:sad...@cisco.com, Robert Li (baoli) ba...@cisco.com mailto:ba...@cisco.com, Robert Kukura rkuk...@redhat.com mailto:rkuk...@redhat.com, OpenStack Development Mailing List (not for usage questions) openstack-dev@lists.openstack.org mailto:openstack-dev@lists.openstack.org, Brian Bowen (brbowen) brbo...@cisco.com mailto:brbo...@cisco.com Subject: RE: [openstack-dev] [nova][neutron] PCI pass-through SRIOV on Jan. 30th Hi Sandhya, Can you please elaborate how do you suggest to extend the below bp for SRIOV Ports managed by different Mechanism Driver? I am not biased to any specific direction here, just think we need common layer for managing SRIOV port at neutron, since there is a common pass between nova and neutron. BR, Irena *From:*Sandhya Dasu (sadasu) [mailto:sad...@cisco.com] *Sent