@@ -37,7 +37,7 @@ Supported features
3737- UDP RSS hashing (1400 series and later adapters)
3838- Scattered Rx
3939- MTU update
40- - SR-IOV on UCS managed servers connected to Fabric Interconnects
40+ - SR-IOV virtual function
4141- Flow API
4242- Overlay offload
4343
@@ -135,103 +135,87 @@ Configuration information
135135 TCP, IPv4, TCP-IPv4, IPv6, TCP-IPv6, IPv6 Extension, TCP-IPv6 Extension.
136136
137137
138- SR-IOV mode utilization
138+ SR-IOV Virtual Function
139139-----------------------
140140
141- UCS blade servers configured with dynamic vNIC connection policies in UCSM
142- are capable of supporting SR-IOV. SR-IOV virtual functions (VFs) are
143- specialized vNICs, distinct from regular Ethernet vNICs. These VFs can be
144- directly assigned to virtual machines (VMs) as 'passthrough' devices.
141+ VIC 1400 and later series supports SR-IOV. It can be enabled via both
142+ UCSM and CIMC. Please refer to the following guides to enable SR-IOV
143+ virtual functions (VFs).
145144
146- In UCS, SR-IOV VFs require the use of the Cisco Virtual Machine Fabric Extender
147- (VM-FEX), which gives the VM a dedicated
148- interface on the Fabric Interconnect (FI). Layer 2 switching is done at
149- the FI. This may eliminate the requirement for software switching on the
150- host to route intra-host VM traffic.
145+ - CIMC: `Managing vNICs <https://www.cisco.com/c/en/us/td/docs/unified_computing/ucs/c/sw/gui/config/guide/4_3/b_cisco_ucs_c-series_gui_configuration_guide_43/b_Cisco_UCS_C-series_GUI_Configuration_Guide_41_chapter_01011.html#d77871e5874a1635 >`_
151146
152- Please refer to `Creating a Dynamic vNIC Connection Policy
153- <http://www.cisco.com/c/en/us/td/docs/unified_computing/ucs/sw/vm_fex/vmware/gui/config_guide/b_GUI_VMware_VM-FEX_UCSM_Configuration_Guide/b_GUI_VMware_VM-FEX_UCSM_Configuration_Guide_chapter_010.html#task_433E01651F69464783A68E66DA8A47A5> `_
154- for information on configuring SR-IOV adapter policies and port profiles
155- using UCSM.
147+ - UCSM: `Configuring SRIOV HPN Connection Policies <https://www.cisco.com/c/en/us/td/docs/unified_computing/ucs/ucs-manager/GUI-User-Guides/Network-Mgmt/4-3/b_UCSM_Network_Mgmt_Guide_4_3/b_UCSM_Network_Mgmt_Guide_chapter_01010.html#d21438e9555a1635 >`_
156148
157- Once the policies are in place and the host OS is rebooted, VFs should be
158- visible on the host, E.g.:
149+ Note that the previous SR-IOV implementation that is tied to VM-FEX
150+ (Cisco Virtual Machine Fabric Extender) has been discontinued, and
151+ ENIC PMD no longer supports it. The current SR-IOV implementation does
152+ not require the Fabric Interconnect (FI), as layer 2 switching is done
153+ within the VIC adapter.
154+
155+ Once SR-IOV is enabled, reboot the host OS and follow OS specific
156+ steps to create VFs and assign them to virtual machines (VMs) or
157+ containers as necessary. The VIC physical function (PF) drivers for ESXi
158+ and Linux support SR-IOV. The following shows simplified steps for
159+ Linux.
159160
160161.. code-block :: console
161162
163+ # echo 4 > /sys/class/net/<pf-interface>/device/sriov_numvfs
164+
162165 # lspci | grep Cisco | grep Ethernet
163- 0d:00.0 Ethernet controller: Cisco Systems Inc VIC Ethernet NIC (rev a2)
164- 0d:00.1 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
165- 0d:00.2 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
166- 0d:00.3 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
167- 0d:00.4 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
168- 0d:00.5 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
169- 0d:00.6 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
170- 0d:00.7 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
171-
172- Enable Intel IOMMU on the host and install KVM and libvirt, and reboot again as
173- required. Then, using libvirt, create a VM instance with an assigned device.
174- Below is an example ``interface `` block (part of the domain configuration XML)
175- that adds the host VF 0d:00:01 to the VM. ``profileid='pp-vlan-25' `` indicates
176- the port profile that has been configured in UCSM.
166+ 12:00.0 Ethernet controller: Cisco Systems Inc VIC Ethernet NIC (rev a2)
167+ 12:00.1 Ethernet controller: Cisco Systems Inc Device 02b7 (rev a2)
168+ 12:00.2 Ethernet controller: Cisco Systems Inc Device 02b7 (rev a2)
169+ 12:00.3 Ethernet controller: Cisco Systems Inc Device 02b7 (rev a2)
170+ 12:00.4 Ethernet controller: Cisco Systems Inc Device 02b7 (rev a2)
171+
172+ Writing 4 to ``sriov_numvfs `` creates 4 VFs. ``lspci `` shows VFs and
173+ their PCI locations. Interfaces with device ID ``02b7 `` are the
174+ VFs. The following snippet for libvirt XML assigns VF at ``12:00.1 ``
175+ to VM.
177176
178177.. code-block :: console
179178
180- <interface type=' hostdev' managed=' yes' >
181- <mac address='52:54:00:ac:ff:b6' />
179+ <interface type=" hostdev" managed=" yes" >
180+ <mac address="fa:16:3e:46:39:c5" />
182181 <driver name='vfio'/>
183182 <source>
184- <address type=' pci' domain=' 0x0000' bus='0x0d' slot=' 0x00' function=' 0x1' />
183+ <address type=" pci" domain=" 0x0000" bus="0x12" slot=" 0x00" function=" 0x1" />
185184 </source>
186- <virtualport type='802.1Qbh' >
187- <parameters profileid='pp-vlan-25' />
188- </virtualport >
185+ <vlan >
186+ <tag id="1000" />
187+ </vlan >
189188 </interface>
190189
191-
192- Alternatively, the configuration can be done in a separate file using the
193- ``network `` keyword. These methods are described in the libvirt documentation for
194- `Network XML format <https://libvirt.org/formatnetwork.html >`_.
195-
196190 When the VM instance is started, libvirt will bind the host VF to
197- vfio, complete provisioning on the FI and bring up the link.
198-
199- .. note ::
200-
201- It is not possible to use a VF directly from the host because it is not
202- fully provisioned until libvirt brings up the VM that it is assigned
203- to.
204-
205- In the VM instance, the VF will now be visible. E.g., here the VF 00:04.0 is
206- seen on the VM instance and should be available for binding to a DPDK.
191+ vfio-pci. In the VM instance, the VF will now be visible. In this
192+ example, VF at ``07:00.0 `` is seen on the VM instance and is available
193+ for binding to DPDK.
207194
208195.. code-block :: console
209196
210- # lspci | grep Ether
211- 00:04 .0 Ethernet controller: Cisco Systems Inc VIC SR-IOV VF (rev a2)
197+ # lspci | grep Cisco
198+ 07:00 .0 Ethernet controller: Cisco Systems Inc Device 02b7 (rev a2)
212199
213- Follow the normal DPDK install procedure, binding the VF to either ``igb_uio ``
214- or ``vfio `` in non-IOMMU mode.
200+ There are two known limitations of the current SR-IOV implementation.
215201
216- In the VM, the kernel enic driver may be automatically bound to the VF during
217- boot. Unbinding it currently hangs due to a known issue with the driver. To
218- work around the issue, block the enic module as follows.
219- Please see :ref: `Limitations <enic_limitations >` for limitations in
220- the use of SR-IOV.
202+ - Software Rx statistics
221203
222- .. code-block :: console
204+ VF on old VIC models does not have hardware Rx counters. In this case,
205+ ENIC PMD counts packets/bytes and reports them as device statistics.
223206
224- # cat /etc/modprobe.d/enic.conf
225- blacklist enic
207+ - Backward compatibility mode
226208
227- # dracut --force
209+ Old PF drivers on ESXi may lack full admin channel support. ENIC PMD
210+ detects such PF driver during initialization and reverts to the
211+ compatibility mode. In this mode, ENIC PMD does not use the admin channel,
212+ and trust mode (e.g. enabling promiscuous mode on VF) is not supported.
228213
229214.. note ::
230215
231- Passthrough does not require SR-IOV. If VM-FEX is not desired, the user
216+ Passthrough does not require SR-IOV. If SR-IOV is not desired, the user
232217 may create as many regular vNICs as necessary and assign them to VMs as
233- passthrough devices. Since these vNICs are not SR-IOV VFs, using them as
234- passthrough devices do not require libvirt, port profiles, and VM-FEX.
218+ passthrough devices.
235219
236220
237221.. _enic-generic-flow-api :
0 commit comments