Home

MLNX_EN for Linux User Manual

image

Contents

1. Note for receive side time stamping currently only HWTSTAMP FILTER NONE and HWTSTAMP FILTER ALL are supported 3 2 2 Getting Time Stamping Once time stamping is enabled time stamp 1s placed in the socket Ancillary data recvmsg can be used to get this control message for regular incoming packets For send time stamps the outgo ing packet is looped back to the socket s error queue with the send time stamp s attached It can be received with recvmsg flags MSG ERRQUEUE The call returns the original outgoing packet data including all headers preprended down to and including the link layer the scm timestamping control message and a sock extended err control message with ee errno ENOMSG and ee origin SO EE ORIGIN TIMESTAMPING A socket with such a pending bounced packet is ready for reading as far as select is concerned If the outgoing Mellanox Technologies 31 Rev 2 4 Feature Overview and Configuration packet has to be fragmented then only the first fragment is time stamped and returned to the sending socket When time stamping is enabled VLAN stripping is disabled k For more info please refer to Documentation networking timestamping txt in kernel org 3 3 Flow Steering Flow Steering is applicable to the mlx4 driver only Flow steering is a new model which steers network flows based on flow specifications to specific QPs Those flows can be either unicast or multicast network flow
2. sk prio 4 TOS 16 sk prio 6 3 The Socket Priority is mapped to the UP Ifthe underlying device is a VLAN device egress map is used controlled by the vconfig command This is per VLAN mapping Ifthe underlying device is not a VLAN device the tc command is used In this case even though tc manual states that the mapping is from the sk prio to the TC number the mlx4 en driver interprets this as a sk prio to UP mapping Mellanox Technologies 23 J Rev 2 4 Feature Overview and Configuration Mapping the sk prio to the UP is done by using tc wrap py i dev name gt u 0 1 2 3 4 5 6 7 4 The the UP is mapped to the TC as configured by the m1nx qos tool or by the 11dpad daemon if DCBX is used Socket applications can use setsockopt SK_PRIO value to directly set the sk_prio of the socket In this case the ToS to sk_prio fixed mapping is not needed This allows the application and the administrator to utilize more than the 4 values possible via ToS In case of VLAN interface the UP obtained according to the above mapping is also used P in the VLAN tag of the traffic 3 1 3 Map Priorities with tc wrap py mlnx qos Network flow that can be managed by QoS attributes is described by a User Priority UP A user s sk priois mapped to UP which in turn is mapped into TC Indicating the UP e When the user uses sk prio it is mapped into a UP by the tc tool This is done by the tc wrap py tool w
3. Mellanox TECHNOLOGIES Mellanox Technologies Mellanox Technologies Ltd 350 Oakmead Parkway Suite 100 Hakidma 26 Sunnyvale CA 94085 Ofer Industrial Park U S A Yokneam 2069200 www mellanox com Israel Tel 408 970 3400 www mellanox com Fax 408 970 3403 Tel 972 0 74 723 7200 Fax 972 0 4 959 3245 Copyright 2015 Mellanox Technologies All Rights Reserved Mellanox Mellanox logo BridgeX ConnectX Connect IB CoolBox CORE Direct InfiniBridge InfiniHost InfiniScale MetroX MLNX OS TestX PhyX ScalableHPC SwitchX UFM Virtual Protocol Interconnect and Voltaire are registered trademarks of Mellanox Technologies Ltd ExtendX FabricIT HPC X Mellanox Open Ethernet Mellanox PeerDirect Mellanox Virtual Modular Switch MetroDX Unbreakable Link are trademarks of Mellanox Technologies Ltd All other trademarks are property of their respective owners 2 Mellanox Technologies Document Number 2950 Rev 2 4 Table of Contents Table of Contents cce e a ee iS Eist f Tables sm sid bs coe A ied A da rd Chapter 1 Overview eoe yere XR AS 1 1 MLNX EN Package Contents lesse 13 LT 1 Tarball Packagesz b e ee tte le e e pee 13 1 1 2 Software Components decenie KEA QoS KR ASSR E REN 14 1213 Bir wares oO b te vod phat ewer oss Melee ioe ah dale mh ee EIU eee ales 14 1 1 4 Directory Structure id ee ee a ER 14 1 2 Module Par
4. Software modules Source code for all software modules for use under conditions mentioned in the modules LICENSE files Documentation Release Notes User Manual 1 1 3 Firmware The tarball image includes the following firmware items Firmware images bin format for ConnectX 2 ConnectX 3 ConnectX 3 Pro network adapters Firmware configuration INI files for Mellanox standard network adapter cards and custom cards 1 1 4 Directory Structure The tarball image of MLNX EN contains the following files and directories e installsh This is the MLNX EN installation script e minx en uninstall sh This is the MLNX EN un installation script firmware Directory of the Mellanox HCA firmware images SOURCES Directory of the MLNX EN source tarball SRPM based A script required to rebuild MLNX EN for customized kernel version on supported RPM based Linux Distribution 14 Mellanox Technologies Rev 2 4 1 2 Module Parameters 1 2 1 mlx4 Module Parameters In order to set m1x4 parameters add the following line s to etc modprobe conf options mlx4 core parameter lt value gt and or options mlx4 en parameter lt value gt The following sections list the available m1x4 parameters 1 2 1 1 mlx4 core Parameters Mellanox Technologies 15 set_4k mtu debug level msi X enable sys tune block loopback num vfs probe vf log num mgm entry size high rate steer fast dr
5. mapping Usage tc_wrap py i lt interface gt options Options version show program s version number and exit h help show this help message and exit u SKPRIO UP skprio up SKPRIO UP maps sk prio to UP LIST is lt 16 comma separated UP index of element is sk prio i INTF interface INTF Interface name Example set skprio 0 2 to UPO and skprio 3 7 to UP1 on eth4 UP 0 Skprio 0 Skprio 1 Skprio 2 tos 8 Skprio 7 Skprio 8 Skprio 9 Skprio 10 Skprio 11 Skprio 12 Skprio 13 Skprio 14 Skprio 15 DEC Skprio 3 Skprio 4 tos 24 Skprio 5 Skprio 6 tos 16 UP 2 we 3 UP 4 UES UP 6 UP 7 28 Mellanox Technologies Rev 2 4 3 1 5 3 Additional Tools tc tool compiled with the sch mqprio module is required to support kernel v2 6 32 or higher This is a part of iproute2 package v2 6 32 19 or higher Otherwise an alternative custom sysfs interface 1s available mlnx qos tool package ofed scripts requires python gt 2 5 toc wrap py package ofed scripts requires python gt 2 5 3 2 Time Stamping Service P Time Stamping is currently at beta level d Please be aware that everything listed here is subject to change Time Stamping is currently supported in ConnectX 3 ConnectX 3 Pro adapter cards only Time stamping is the process of keeping track of the creation of a packet A time stamping ser vice supports assertions of proof that a datum existed bef
6. 3 4 1 1 System Requirements To set up an SR IOV environment the following is required MLNX EN Driver Aserver blade with an SR IOV capable motherboard BIOS Hypervisor that supports SR IOV such as Red Hat Enterprise Linux Server Version 6 Mellanox ConnectX VPI Adapter Card family with SR IOV capability 3 4 1 2 Setting Up SR IOV Depending on your system perform the steps below to set up your BIOS The figures used in this section are for illustration purposes only For further information please refer to the appropriate BIOS User Manual Step 1 Enable SR IOV in the system BIOS BIOS SETUP UTILITY Step 2 Enable Intel Virtualization Technology lun dering Step 3 Install the hypervisor that supports SR IOV 36 Mellanox Technologies Rev 2 4 Step 4 Depending on your system update the boot grub grub conf file to include a similar command line load parameter for the Linux kernel For example to Intel systems add default 0 timeout 5 splashimage hd0 0 grub splash xpm gz hiddenmenu title Red Hat Enterprise Linux Server 2 6 32 36 x86 645 root hd0 0 kernel vmlinuz 2 6 32 36 x86 64 ro root dev VolGroup00 LogVol00 rhgb quiet intel iommu on initrd initrd 2 6 32 36 x86 64 img a Please make sure the parameter intel jiommu on exists when updating the boot grub grub conf file otherwise SR IOV cannot be loaded Step 5 Install the MLNX EN driver for Linux that supports SR
7. http www mellanox com gt Products gt Software gt Ethernet Drivers Step 3 Use the md5sum utility to confirm the file integrity of your tarball image 2 3 Installing MLNX_EN The installation script minx_en install performs the following Discover the currently installed kernel Uninstall any previously installed MLNX OFED MLNX EN packages Install the MLNX_EN binary if they are available for the current kernel Identifies the currently installed Ethernet network adapters and automatically upgrades the firmware 2 3 1 Installation Modes mlnx_en installer supports 2 modes of installation The install scripts selects the mode of driver installation depending of the running OS kernel version Kernel Module Packaging KMP mode where the source rpm is rebuilt for each installed flavor of the kernel This mode is used for RedHat and SUSE distributions e Non KMP installation mode where the sources are rebuilt with the running kernel This mode is used for vanilla kernels If the Vanilla kernel is installed as rpm please use the disable kmp flag when installing the driver Mellanox Technologies 17 Rev 2 4 Installation The package consists of several source RPMs The install script rebuilds the source RPMs and then installs the created binary RPMs The created kernel module binaries are located at For KMP RPMs installation OnSLES mellanox mlnx en kmp RPM 1ib modules kernel ver upda
8. int Threshold for using inline data int Default and max value is 104 bytes Saves PCI read operation transaction packet less then threshold size will be copied to hw buffer directly Enable RSS for incoming UDP traffic uint On by default Once disabled no RSS for incoming UDP traffic will be done Priority based Flow Control policy on TX 7 0 Per priority bit mask uint Priority based Flow Control policy on RX 7 0 Per priority bit mask uint 16 Mellanox Technologies Rev 2 4 2 Installation This chapter describes how to install and test the MLNX_EN for Linux package on a single host machine with Mellanox InfiniBand and or Ethernet adapter hardware installed 2 1 Software Dependencies To install the driver software kernel sources must be installed on the machine MLNX EN driver cannot coexist with OFED software on the same machine Hence when installing MLNX EN all OFED packages should be removed run the mlnx_en install script 2 2 Downloading MLNX_EN Step 1 Verify that the system has a Mellanox network adapter HCA NIC installed The following example shows a system with an installed Mellanox HCA lspci v grep Mellanox 06 00 0 Network controller Mellanox Technologies MT27500 Family ConnectX 3 Subsystem Mellanox Technologies Device 0024 Step 2 Download the tarball image to your host The image s name has the format MLNX_EN lt ver gt tgz You can download it from
9. please refer to the Performance Tuning Guide for Mellanox Network Adapters www mellanox com gt Products gt InfiniBand VPI Drivers gt Linux SW Drivers Out of the box throughput IRQ affinity is not set properly For additional performance tuning please performance in by the irq balancer refer to Performance Tuning Guide Ubuntu14 04 is not opti mal and may achieve results below the line rate in 40GE link speed UDP receiver throughput This is caused by the adaptive Disable adaptive interrupt moderation and may be lower then interrupt moderation routine set lower values for the interrupt coalescing expected when running which sets high values of manually over mlx4_en Ethernet interrupt coalescing causing ethtool C lt eth gt X adaptive rx off driver the driver to process large rx usecs 64 rx frames 24 number of packets in the same interrupt leading UDP to drop Values above may need tuning depending packets due to overflow in its the system configuration and link speed buffers 68 Mellanox Technologies Rev 2 4 1 0 0 1 4 4 SR IOV Related Issues Table 18 SR IOV Related Issues Issue Cause Solution Failed to enable The number of VFs config 1 Check the firmware SR IOV configura SR IOV ured in the driver is higher tion run the mlxconfig tool The following message than configured in the firm 2 Set the same number of VFS for the is reported in dmesg ware
10. 9 gt sys class net eth5 vf 0 vlan_set Where o specifies if untagged priority tagged traffic is allowed Meaning if the below command is ran you will not be able to send receive untagged traf fic echo 1234567 8 9 10 gt sys class net eth5 v 0 vlan set Step2 Reboot the relevant VM for changes to take effect or run etc init d openibd restart gt To disable VGT mode Step1 Set the VLAN echo gt sys class net eth5 v 0 vlan_set Step 2 Reboot the relevant VM for changes to take effect or run etc init d openibd restart gt To add a VLAN In the example below the following state exist cat sys class net eth5 v 0 vlan set oper 012 3 admin 0 1 2 3 Step 1 Make an operational VLAN set identical to the administration VLAN echo 2 3 4 5 6 gt sys class net eth5 vf0 vlan set The delta will be added to the operational state immediately 4 5 6 cat sys class net eth5 v 0 vlan set open MOMPER 45 G admin 23 45 6 Step 2 Reset the VF for changes to take effect Mellanox Technologies 47 Rev 2 4 Feature Overview and Configuration 3 4 2 VXLAN Hardware Stateless Offloads VXLAN technology introduced for solving scalability and security challenges requires exten sion of the traditional stateless offloads to avoid performance drop ConnectX 3 Pro adapter card offers the following stateless offloads for a VXLAN packet similar to the ones offered to non encapsulated packets VXLAN protocol encapsulates
11. IOV SR IOV can be enabled and managed by using one of the following methods Burn firmware with SR IOV support where the number of virtual functions VFs will be set to 16 enable sriov Runthe mlxconfig tool and set the SRIOV EN parameter to 1 without re burning the firmware SRIOV EN 1 For further information please refer to section mlxconfig Changing Device Configuration Tool in the MFT User Manual www mellanox com gt Products gt Software gt Firmware Tools Step 6 Verify the HCA is configured to support SR IOV root selene mstflint dev lt PCI Device gt dc 1 Verify in the HCA section the following fields appear HCA num pfs 1 Goul vis 0265 sriov_en true Parameter Recommended Value num pfs 1 Note This field is optional and might not always appear total_vfs When using firmware version 2 31 5000 and above the recommended value is 126 When using firmware version 2 30 8000 and below the recommended value is 63 Note Before setting number of VFs in SR IOV please make sure your system can support that amount of VFs Setting number of VFs larger than what your Hardware and Software can support may cause your system to cease working Mellanox Technologies 37 Rev 2 4 Feature Overview and Configuration Step 7 Step 8 Parameter Recommended Value sriov en true 2 Add the above fields to the INI if they are missing 3 Set t
12. ULPs are notified about the incident and outstanding WQEs are simulated to be returned with flush in error message to enable each ULP to close its resources and not get stuck via calling its remove one callback as part of Reset Flow Once the unload part is terminated each ULP is called with its add_one callback its resources are re initialized and it is re activated 3 5 1 2 SR IOV If the Physical Function recognizes the error it notifies all the VFs about it by marking their communication channel with that information consequently all the VFs and the PF are reset If the VF encounters an error only that VF is reset whereas the PF and other VFs continue to work unaffected 3 5 1 3 Forcing the VF to Reset If an outside reset is forced by using the PCI sysfs entry for a VF a reset is executed on that VF once it runs any command over its communication channel For example the below command can be used on a hypervisor to reset a VF defined by 0000 04 00 1 echo 1 gt sys bus pci devices 0000 04 00 1 reset 1 A fatal device error can be a timeout from a firmware command an error on a firmware closing command communication channel not being responsive in a VF etc Mellanox Technologies 49 Rev 2 4 Feature Overview and Configuration 3 5 1 4 Advanced Error Reporting AER AER a mechanism used by the driver to get notifications upon PCI errors is supported only in native mode ULPs are c
13. VXLAN tunnel over UDP port 4789 To add the UDP port to etc modprobe d vxlan conf options vxlan udp port number decided above 48 Mellanox Technologies Rev 2 4 3 4 2 3 Important Notes VXLAN tunneling adds 50 bytes 14 eth 20 ip 8 udp 8 vxlan to the VM Ethernet frame Please verify that either the MTU of the NIC who sends the packets e g the VM virtio net NIC or the host side veth device or the uplink takes into account the tunneling overhead Meaning the MTU of the sending NIC has to be decremented by 50 bytes e g 1450 instead of 1500 or the uplink NIC MTU has to be incremented by 50 bytes e g 1550 instead of 1500 From upstream 3 15 rcl and onward it is possible to use arbitrary UDP port for VXLAN Note that this requires firmware version 2 31 2800 or higher Additionally you need to enable this kernel configuration option CONFIG MLX4 EN VXLAN y On upstream kernels 3 12 3 13 GRO with VXLAN is not supported 3 5 Resiliency 3 5 1 Reset Flow Reset Flow is activated by default once a fatal device error is recognized Both the HCA and the software are reset the ULPs and user application are notified about it and a recovery process is performed once the event is raised The Reset Flow is activated by the mlx4 core module parameter internal_err_reset and its default value is 1 3 5 1 1 Kernel ULPs Once a fatal device error is recognized an IB_EVENT_DEVICE_FATAL event is created
14. driver mlx4 core 0000 xx xx 0 Failed to enable SR IOV continuing without SR IOV err 22 Failed to enable SR IOV is disabled in the Check that the SR IOV is enabled in the SR IOV BIOS BIOS see Section 3 4 1 2 Setting Up The following message SR IOV on page 36 is reported in dmesg mlx4 core 0000 xx xx 0 Failed to enable SR IOV continuing without SR IOV err 12 When assigning a VF to SR IOV and virtualization 1 Verify they are both enabled in the BIOS a VM the following are not enabled in the 2 Add to the GRUB configuration file to message is reported on BIOS the following kernel parameter the screen intel immun on PCI assgine error see Section 3 4 1 2 Setting Up SR requires KVM sup IOV on page 36 port Mellanox Technologies 69
15. is above this value rx usecs will be set to rx usecs high rx frame low Lower watermark of the routine when rate is lower than that mark sus pension will be used when increasing CPU utilization cost in latency 3 14 RSS Support for IP Fragments As of MLNX EN for Linux v2 4 1 0 0 RSS will distribute incoming IP fragmented datagrams according to its hash function considering the L3 IP header values Different IP fragmented data grams flows will be directed to different rings When the first packet in IP fragments chain contains upper layer transport header e g UDP packets larger than MTU it will be directed to the same target as the pro ceeding IP fragments that follows it to prevent out of order processing 64 Mellanox Technologies Rev 2 4 Mellanox Technologies 65 Rev 2 4 1 0 0 1 Troubleshooting 4 Troubleshooting You may be able to easily resolve the issues described in this section If a problem persists and you are unable to resolve it yourself please contact your Mellanox representative or Mellanox Support at support mellanox com 4 1 General Related Issues Table 15 General Related Issues Issue Cause Solution Ra The system panics when Malfunction hardware com Remove the failed adapter it is booted with a failed ponent 2 Reboot the system adapter installed Mellanox adapter is not PCI slot or adapter PCI 1 Run 1spci identified as a PCI connector dysfunc
16. novlan packets Total packets successfully transmitted with no VLAN priority tx novlan bytes Total bytes in successfully transmitted packets with no VLAN priority Table 11 Port Pause where i is in the range 0 7 Counter Description IX pause prio lt i gt The total number of PAUSE frames received from the far end port rx pause duration prio i The total time in microseconds that far end port was requested to gt pause transmission of packets rx pause transition prio lt i The number of receiver transitions from XON state paused to gt XOFF state non paused tx pause prio lt i gt The total number of PAUSE frames sent to the far end port tx pause duration prio i The total time in microseconds that transmission of packets has been paused tx pause transition prio i The number of transmitter transitions from XON state paused gt to XOFF state non paused Mellanox Technologies 61 Table 12 VPort Statistics where lt i gt lt empty_string gt is the PF and ranges 1 NumOfVf per VF Rev 2 4 Feature Overview and Configuration Counter Description vport lt i gt _rx_unicast_packet S Unicast packets received successfully vport lt i gt rx unicast bytes Unicast packet bytes received successfully vport lt i gt rx multicast pack ets Multicast packets received successfully vportci rx multicast byte S Multicas
17. rpg ai rate 10 rpg hai rate 50 rpg gd 8 rpg min dec fac 2 rpg min rate 10 cndd state machine 0 priority 1 rpg enable 0 rppp max rps 1000 rpg time reset 1464 rpg byte reset 150000 rpg threshold 5 rpg max rate 40000 rpg ai rate 10 rpg hai rate 50 rpg gd 8 rpg min dec fac 2 rpg min rate 10 cndd state machine 0 priority 7 rpg enable 0 rppp max rps 1000 rpg time reset 1464 rpg byte reset 150000 rpg threshold 5 Mellanox Technologies 55 Rev 2 4 Feature Overview and Configuration rpg max rate 40000 rpg ai rate 10 rpg hai rate 50 rpg gd 8 rpg min dec fac 2 rpg min rate 10 cndd state machine 0 3 8 2 Setting QCN Configuration Setting the QCN parameters requires updating its value for each priority 1 indicates no change in the current value Example for setting rp g enable in order to enable QCN for priorities 3 5 6 Wilde Gigs i Biel o Gao lt 1 X X nm 3 2 i Example for setting rpg hai rate for priorities 1 6 7 mlnx qcn i eth2 rpg hai rate 60 1 1 1 1 1 60 60 3 9 Explicit Congestion Notification ECN ECN is an extension to the IP protocol It allows reliable communication by notifying all ends of communication when a congestion occurs This is done without dropping packets Please note that since this feature requires all nodes in the path nodes routers etc between the communicating nodes to support ECN to ensure reliable communication ECN is marked
18. the InfiniBand Architecture Specification Table 3 Glossary Channel Adapter CA An IB device that terminates an IB link and executes transport functions This Host Channel Adapter may be an HCA Host CA or a TCA Target CA HCA HCA Card A network adapter card based on an InfiniBand channel adapter device IB Devices Integrated circuit implementing InfiniBand compliant communication In Band A term assigned to administration activities traversing the IB connectivity only Local Port The IB port of the HCA through which IBDIAG tools connect to the IB fabric Master Subnet Manager The Subnet Manager that is authoritative that has the reference configuration information for the subnet See Subnet Manager Multicast Forwarding Tables A table that exists in every switch providing the list of ports to forward received multicast packet The table is organized by MLID Network Interface Card NIC A network adapter card that plugs into the PCI Express slot and provides one or more ports to an Ethernet network Unicast Linear For warding Tables LFT A table that exists in every switch providing the port through which packets should be sent to each LID Virtual Protocol Inter connet VPI A Mellanox Technologies technology that allows Mellanox channel adapter devices ConnectX to simultaneously connect to an InfiniBand subnet and a 10GigE subnet each subnet connects to one of t
19. this mode the driver indicates to the Linux Networking Stack that the hardware successfully validated the IP and L4 checksum so the Linux Networking Stack does not need to deal with IP L4 Checksum validation Rev 2 4 Checksum Unnecessary is passed to the OS when all of the following are true Ethtool k lt DEV gt shows rx checksumming on Received TCP UDP packet and both IP checksum and L4 protocol checksum are correct CHECKSUM COMPLETE When the checksum validation cannot be done or fails the driver still reports to the OS the calculated by hardware checksum value This allows accelerating checksum validation in Linux Networking Stack since it does not have to calculate the whole checksum including payload by itself Checksum Complete is passed to OS when all of the following are true Ethtool k lt DEV gt shows rx checksumming on Using ConnectX 3 firmware version 2 31 7000 and up Received IpV4 IpV6 non TCP UDP packet The ingress parser of the ConnectX 3 Pro card comes by default without checksum offload support for non TCP UDP packets To change that please set the value of the module parameter ingress parser mode in mlx4 core to 1 In this mode IPv4 IPv6 non TCP UDP packets will be passed up to the protocol stack with CHECKSUM COMPLETE tag In this mode of the ingress parser the following features are unavailable NVGRE stateless offloads VXLAN stateless offloads RoCE v2 R RoCE
20. 0 Ssingle VFs on port 1 Osingle VFs on port 2 10 dual port VFs Applies when all ports are configure as Ethernet in dual port HCAs Notes PFs not included in the above list will not activate any of their VFs in the PF driver Triplets and single port VFs are only valid when all ports are configured as Ethernet When an InfiniBand port exist only probe vf a syntax is valid where a is a single value that represents the number of VFs The second parameter in a triplet is valid only when there are more than 1 physical port Every value either a value in a triplet or a single value should be less than or equal to the respective value of num v s parameter The example above loads the driver with 5 VFs num vfs The standard use of a VF is a single VF per a single VM However the number of VFs varies upon the working mode requirements Step 9 Reboot the server gt d If the SR IOV is not supported by the server the machine might not come out of boot load Step 10 Load the driver and verify the SR IOV is supported Run lspci grep Mellanox 03 00 0 InfiniBand Mellanox Technologies MT26428 ConnectX VPI PCIe 2 0 5GT s IB QDR 10GigE rev b0 03 00 1 InfiniBand Mellanox Technologies MT27500 Family ConnectX 3 Virtual Function rev b0 03 00 2 InfiniBand Mellanox Technologies MT27500 Family ConnectX 3 Virtual Function rev b0 03 00 3 InfiniBand Mellanox Technologies MT27500 Family Connec
21. 0 ccc ees 56 3 9 1 Enabling ECON ci ii RR e Rede EN A 56 3 9 2 Various ECN Paths ss oss zm ee Aa eR ORBE UR A ET tus 58 3 10 Power Management lisse ence ene n eee 58 3 11 XOR RSS Hash Function sses 222 1 82 a slev be eka sie bn vn ks nes 58 3 12 Ethernet Performance Counters eee 58 3 13 Adaptive Interrupt Moderation Algorithm 21 1 2 2 ss kakak kaa a 63 3 14 RSS Support for IP Fragments 1 sss ssak kakak 64 Chapter 4 Troubleshooting s ssssssnsnnnnnsnsnnnnnnnnnnnannan a 06 41 General Related Issues crier Gan tale hg enn alee Baya alan baga ha 66 4 2 Ethernet Related Issues 0 ccc cette ene aaa 66 4 3 Performance Related Issues 0 0 20 0 ccc ccc ccc teen ees 68 4 Mellanox Technologies Rev 2 4 4 4 SR IOV Related Issues 2 0 00 cece eee eee 69 Mellanox Technologies 5 Rev 2 4 6 Mellanox Technologies Rev 2 4 List of Tables Table 1 Document Revision History 0 ccc eee rr rr rr reser 8 Table 2 Abbreviations and Acronyms ssusssakkakkkakaa kakak ehh 11 Table 3 COSSA beeen es ba a NB GR 12 Table 4 Reference Documents ssussusssakaaaaakkak rer rr rr teenies 12 Table 5 MLNX EN Software Components i ssssssssssaksaaaaaakakaaaa 14 Table 6 Flow Specific Parameters 0 0 cece ea 34 Table 7 ethtool Supported Options 0 0 0 0 00 ere rer rr rr rr rr kak
22. 10 bus info 0000 1a 00 0 gt To query stateless offload status gt ethtool k eth lt x gt gt To set stateless offload status gt ethtool K eth x rx on off tx on off sg on off tso on off lro on off To query interrupt coalescing settings gt ethtool c eth x To enable disable adaptive interrupt moderation gt ethtool C eth x adaptive rx on off By default the driver uses adaptive interrupt moderation for the receive path which adjusts the mod eration time to the traffic pattern gt To set the values for packet rate limits and for moderation time high and low gt ethtool C eth x pkt rate low N pkt rate high N rx usecs low N rx usecs high N Above an upper limit of packet rate adaptive moderation will set the moderation time to its highest value Below a lower limit of packet rate the moderation time will be set to its lowest value gt To set interrupt coalescing settings when adaptive moderation is disabled gt ethtool C eth x rx usecs N rx frames N Pp usec settings correspond to the time to wait after the last packet 1s sent received before triggering an interrupt Aha To query pause frame settings gt ethtool a eth lt x gt gt To set pause frame settings gt ethtool A eth lt x gt rx on off tx on off gt To query ring size values gt ethtool g eth lt x gt gt To modify rings size gt ethtool G eth lt x g
23. 53 Rev 2 4 Feature Overview and Configuration 3 8 1 QCN Tool mInx qcn mlnx_qcn is a tool used to configure QCN attributes of the local host It communicates directly with the driver thus does not require setting up a DCBX daemon on the system The mlnx qcn enables the user to Inspect the current QCN configurations for a certain port sorted by priority Inspect the current QCN statistics and counters for a certain port sorted by priority Set values of chosen QCN parameters Usage minx gcn i interface options Options version Show program s version number and exit h help Show this help message and exit i INTF interface INTF Interface name g TYPE get type TYPE Type of information to get statistics param eters rpg enable RPG ENABLE LIST Set value of rpg enable according to prior ity use spaces between values and 1 for unknown values rppp max rps RPPP MAX RPS LIST Set value of rppp max rps according to prior ity use spaces between values and 1 for unknown values rpg time reset RPG TIME RESET LIST Set value of rpg time reset according to pri ority use spaces between values and 1 for unknown values rpg byte reset RPG BYTE RESET LIST Set value of rpg byte reset according to pri ority use spaces between values and 1 for unknown values rpg threshold RPG THRESHOLD LIST Set value of rpg threshold according to pri ority use spaces between val
24. C is assigned with the QoS attributes and the different flows behave accordingly 3 1 1 Mapping Traffic to Traffic Classes Mapping traffic to TCs consists of several actions which are user controllable some controlled by the application itself and others by the system network administrators The following is the general mapping traffic to Traffic Classes flow 1 The application sets the required Type of Service ToS 2 The ToS is translated into a Socket Priority sk_prio 3 The sk_prio is mapped to a User Priority UP by the system administrator some applica tions set sk_prio directly 4 The UP is mapped to TC by the network system administrator 5 TCs hold the actual QoS parameters QoS can be applied on the following types of traffic However the general QoS flow may vary among them Plain Ethernet Applications use regular inet sockets and the traffic passes via the ker nel Ethernet driver e RoCE Applications use the ROMA API to transmit using QPs Raw Ethernet QP Application use VERBs API to transmit using a Raw Ethernet QP 3 1 2 Plain Ethernet Quality of Service Mapping Applications use regular inet sockets and the traffic passes via the kernel Ethernet driver The following is the Plain Ethernet QoS mapping flow 1 The application sets the ToS of the socket using setsockopt IP TOS value 2 ToS is translated into the sk prio using a fixed translation TOS 0 sk prio 0 TOS 8 sk prio 2 TOS 24
25. IX csum none Number of packets received with no checksum indication tx chksum offload Number of packets transmitted with checksum offload tx queue stopped Number of times transmit queue suspended tx wake queue Number of times transmit queue resumed tx timeout Number of times transmitter timeout tx tso packets Number of packet that were aggregated Table 14 Per Ring SW Statistics where lt i gt is the ring I per configuration Counter Description rx lt i gt _packets Total packets successfully received on ring i rx lt i gt bytes Total bytes in successfully received packets on ring i tx lt i gt packets Total packets successfully transmitted on ring i tx lt i gt bytes Total bytes in successfully transmitted packets on ring i 3 13 Adaptive Interrupt Moderation Algorithm When Ethernet NIC receives packets it generates CPU interrupts in the OS in order for the driver to process incoming packets The rate in which those interrupts are issued correlates greatly with CPU utilization and perfor mance measurements mainly latency but also throughput and message rate While the coalescing parameters rx frames and rx usecs from ethtool C section can be set manually by users the m1x4 en Ethernet driver has an adaptive coalescing moderation scheme which configures the rx usecs value according to a set of terms described below rx frames is unaffected by the routine so every change in it will be enfor
26. Mellanox TECHNOLOGIES Connect Accelerate Outperform MLNX_EN for Linux User Manual Rev 2 4 1 0 0 1 www mellanox com Rev 2 4 NOTE THIS HARDWARE SOFTWARE OR TEST SUITE PRODUCT PRODUCT S AND ITS RELATED DOCUMENTATION ARE PROVIDED BY MELLANOX TECHNOLOGIES AS IS WITH ALL FAULTS OF ANY KIND AND SOLELY FOR THE PURPOSE OF AIDING THE CUSTOMER IN TESTING APPLICATIONS THAT USE THE PRODUCTS IN DESIGNATED SOLUTIONS THE CUSTOMER S MANUFACTURING TEST ENVIRONMENT HAS NOT MET THE STANDARDS SET BY MELLANOX TECHNOLOGIES TO FULLY QUALIFY THE PRODUCT S AND OR THE SYSTEM USING IT THEREFORE MELLANOX TECHNOLOGIES CANNOT AND DOES NOT GUARANTEE OR WARRANT THAT THE PRODUCTS WILL OPERATE WITH THE HIGHEST QUALITY ANY EXPRESS OR IMPLIED WARRANTIES INCLUDING BUT NOT LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT ARE DISCLAIMED IN NO EVENT SHALL MELLANOX BE LIABLE TO CUSTOMER OR ANY THIRD PARTIES FOR ANY DIRECT INDIRECT SPECIAL EXEMPLARY OR CONSEQUENTIAL DAMAGES OF ANY KIND INCLUDING BUT NOT LIMITED TO PAYMENT FOR PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES LOSS OF USE DATA OR PROFITS OR BUSINESS INTERRUPTION HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY WHETHER IN CONTRACT STRICT LIABILITY OR TORT INCLUDING NEGLIGENCE OR OTHERWISE ARISING IN ANY WAY FROM THE USE OF THE PRODUCT S AND RELATED DOCUMENTATION EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE
27. Mellanox Technologies Rev 2 4 1 0 0 1 About this Manual This Preface provides general information concerning the scope and organization of this User s Manual Intended Audience This manual is intended for system administrators responsible for the installation configuration management and maintenance of the software and hardware of VPI InfiniBand Ethernet adapter cards It is also intended for application developers Common Abbreviations and Acronyms Table 2 Abbreviations and Acronyms RN j Whole Word Description B Capital B is used to indicate size in bytes or multiples of bytes e g IKB 1024 bytes and 1MB 1048576 bytes b Small b is used to indicate size in bits or multiples of bits e g IKb 1024 bits FW Firmware HW Hardware LSB Least significant byte Isb Least significant bit MSB Most significant byte msb Most significant bit NIC Network Interface Card SW Software VPI Virtual Protocol Interconnect PFC Priority Flow Control PR Path Record RDS Reliable Datagram Sockets SL Service Level QoS Quality of Service ULP Upper Level Protocol VL Virtual Lane Mellanox Technologies 11 Glossary Rev 2 4 1 0 0 1 The following is a list of concepts and terms related to InfiniBand in general and to Subnet Man agers in particular It is included here for ease of reference but the main reference remains
28. N on page 56 Section 4 1 General Related Issues on page 66 Section 4 2 Ethernet Related Issues on page 66 Section 4 3 Performance Related Issues on page 68 Section 4 4 SR IOV Related Issues on page 69 Updated the following section Section 3 3 1 Enable Disable Flow Steering on page 32 Section 3 4 1 2 Setting Up SR IOV on page 36 Section 3 6 Ethtool on page 50 2 2 1 0 1 May 2014 Added the following sections e Section 3 4 1 6 3 Mapping VFs to Ports using the minx get vfs pl Tool on page 45 Section 3 6 Ethtool on page 50 Section 3 8 Quantized Congestion Control on page 53 Section 3 8 Quantized Congestion Control on page 53 Section 3 10 Power Management on page 58 Section 3 11 XOR RSS Hash Function on page 58 Updated the following section Section 3 4 1 2 Setting Up SR IOV on page 36 Removed the following sections Burning Firmware with SR IOV Performance 2 1 1 0 0 January 2014 Added Section 3 12 Ethernet Performance Counters on page 58 Mellanox Technologies 9 Rev 2 4 1 0 0 1 Table 1 Document Revision History Release Date Description 2 0 3 0 0 October 2013 Added the following sections Section 3 4 1 Single Root IO Virtualization SR IOV on page 35 Section 3 3 Flow Steering on page 32 Section 32 Time Stamping Service on page 29 10
29. X bytes 19232 18 7 KiB Interrupt 10 Base address 0xa000 42 Mellanox Technologies Rev 2 4 Step 5 Add the MAC 52 54 00 E7 77 99 to the sys class net eth5 fdb table on HV Before cat sys class net eth5 fdb 3335533100510 011021302 33 33 ff 2e 66 52 01 00 5e 00 00 01 33 33 00 00 00 01 Do echo 52 54 00 E7 77 99 gt sys class net eth5 fdb After cat sys class net eth5 fdb 52 54 00 e7 77 99 33 53 00200 02 02 BBR F 26 166552 01 005 52 00 00507 argo OO OI 3 4 1 4 Assigning a Virtual Function to a Virtual Machine This section will describe a mechanism for adding a SR IOV VF to a Virtual Machine 3 4 1 4 1 Assigning the SR IOV Virtual Function to the Red Hat KVM VM Server Step 1 Run the virt manager Step2 Double click on the virtual machine and open its Properties Step 3 Goto Details Add hardware gt PCI host device Bie Virtual Machine View Send Key 0 G gt Add new virtual hardware DA x Adding Virtual Hardware This assistant will guide you through adding a new piece of virtual hardware First select what type of hardware you wish to add Hardware type __ Storage W Network Input arale O Physical Host Device BD video BB watchdog X Cancel gt Forward Add Hardware Remove Step 4 Choose a Mellanox virtual function according to its PCI device e g 00 03 1 Step 5 If the Virtual Machine is up reboot it otherwise start it Step 6 Log into the v
30. a 50 Table Port IN Counters cti sasa baa aA ada ake Mae eR I ge nce 59 Table9 PortOU T Counters a ne a aes ack nce ae E any S NS o GAN ee 60 Table 10 Port VLAN Priority Tagging where lt i gt is in the range 0 7 61 Table 11 Port Pause where lt i gt is in the range 0 7 20 ccc rer rer rer rena 61 Table 12 VPort Statistics where lt i gt lt empty_string gt is the PF and ranges 1 NumOfVf per VF 62 Table 13 SW Statistics a a gee bala SO ela e teda 62 Table 14 Per Ring SW Statistics where lt i gt is the ring I per configuration 63 Table 15 General Related Issues 0 0 0 eect tenn een ees 66 Table 16 Ethernet Related Issues 0 1 ete nee ene n ene 66 Table 17 Performance Related Issues sssssssssaa kakak akak kaka 68 Table 18 SR IOV Related ISSUES alvan Sl Ra R R RTA hh 69 Mellanox Technologies 7 Rev 2 4 1 0 0 1 Document Revision History Table 1 Document Revision History Release Date Description 2 4 1 0 0 1 January 26 2015 Added the following new sections Section 2 8 2 Updating the Device Online on page 20 Section 3 4 1 7 1 FDB Status Reporting on page 45 Section 3 13 Adaptive Interrupt Moderation Algo rithm on page 63 Section 3 14 RSS Support for IP Fragments on page 64 Updated Table 7 ethtool Supported Options on page 50 Updated ethtool K eth lt x gt opt
31. ad pra s desde tastes das AG vas oe Wd 36 3 4 1 3 Enabling SR IOV and Para Virtualization on the Same Setup 42 3 4 1 4 Assigning a Virtual Function to a Virtual Machine 2 43 3 4 1 5 Uninstalling SR IOV Driver uana cece eee 44 3 4 1 6 Ethernet Virtual Function Configuration when Running SR IOV 44 3 4 1 7 MAC Forwarding DataBase FDB Management 45 3 4 1 8 Virtual Guest Tagging VGT 06 ce cece rr rr rr et 46 3 42 VXLAN Hardware Stateless Offloads 2 1 ssskss eee ee 48 VN Prerequisites idc ke ise ive LV oe Me Erde UC ET mei 48 3 4 2 2 Enabling VXLAN Hardware Stateless OffloadS o oooooooooo o o 48 3 42 3 Important Notes sse osse edie ke eee ee ate agate ade ada dae anaes 49 3 5 ON 49 3 51 Reset Flows ec edie cid ii ek 49 3 5 ET Kernel VEPS S sess steal yeas IA AAA ete eens 49 IS A A bor dae carnal 49 3 5 1 3 Forcing the VF to Reset 49 3 5 1 4 Advanced Error Reporting AER 1 2 00 0 50 3 5 1 5 Extended Error Handling EEH 0 0 c cece eee ee 50 3 65 EN 151070 nag o Whe hb b ERE 50 3 7 Checksum Offload vag ds kr dod erence ada A Bae as oes 32 3 8 Quantized Congestion Control 00 cece eens 53 3 8 1 QCN Tool mlnx dcn a sasse ns eed a eae RA 54 3 8 2 Setting QCN Configuration 0 0 0 cece teen ees 56 3 9 Explicit Congestion Notification ECN 0 0 0
32. ae d mons utilities that could enable it i e Ildpad should be turned OFF Mellanox Technologies 57 Rev 2 4 Feature Overview and Configuration 3 9 2 Various ECN Paths The following are the paths to ECM algorithm general parameters and counters The path to an algorithm attribute is except for general parameters sys kernel debug mlx4_ib DEVICE ecn algorithm ports port params prios prio attribute The path to a general parameter is sys kernel debug mlx4_ib DEVICE ecn r roce ecn np gen params attribute The path to a counter is sys kernel debug mlx4 ib DEVICE ecn algorithm ports port statistics prios prio counter 3 10 Power Management pm qos API is used by mlx4 en to enforce minimum DMA latency requirement on the system when ingress traffic is detected Additionally it decreases packet loss on systems configured with abundant power state profile when Flow Control is disabled The pm_qos API contains the following functions pm qos add request pm qos update request pm qos remove request pm qos feature is both global and static once a request is issued it is enforced on all CPUs and does not change in time MLNX EN v2 2 1 0 1 and onwards provides an option to trigger a request when required and to remove it when no longer required It is disabled by default and can be set unset through the eth tool priv flags For further information on how to enable disable t
33. affic pattern For further information please refer to Adaptive Interrupt Moderation section ethtool C eth lt x gt pkt rate low N pkt rate high N rx usecs low N rx usecs high N Sets the values for packet rate limits and for moderation time high and low values For further information please refer to Adaptive Interrupt Moderation section ethtool C eth lt x gt rx usecs N rx frames N Sets the interrupt coalescing setting rx frames will be enforced immediately rx usecs will be enforced only when adaptive moderation is disabled Note usec settings correspond to the time to wait after the last packet is sent received before triggering an inter rupt ethtool a eth lt x gt Queries the pause frame settings Mellanox Technologies 51 Rev 2 4 Feature Overview and Configuration Table 7 ethtool Supported Options 3 7 52 Mellanox Technologies Options Description ethtool A eth lt x gt rx on off tx on off Sets the pause frame settings ethtool g eth lt x gt Queries the ring size values ethtool G eth lt x gt rx lt N gt tx lt N gt Modifies the rings size ethtool S eth lt x gt Obtains additional device statistics ethtool t eth lt x gt Performs a self diagnostics test ethtool s eth lt x gt msglvl N Changes the current driver message level ethtool T eth lt x gt Shows time stamping c
34. alled with remove_one add_one and expect to continue working prop erly after that flow User space application will work in same mode as defined in the Reset Flow above 3 5 1 5 Extended Error Handling EEH Extended Error Handling EEH is a PowerPC mechanism that encapsulates AER thus exposing AER events to the operating system as EEH events The behavior of ULPs and user space applications is identical to the behavior of AER 3 6 Ethtool ethtool is a standard Linux utility for controlling network drivers and hardware particularly for wired Ethernet devices It can be used to Get identification and diagnostic information Get extended device statistics e Control speed duplex autonegotiation and flow control for Ethernet devices Control checksum offload and other hardware offload features Control DMA ring sizes and interrupt moderation The following are the ethtool supported options Table 7 ethtool Supported Options Options Description ethtool i eth lt x gt Checks driver and device information For example d ethtool i eth2 driver mlx4 en MT 0DD0120009 CX3 version 2 1 6 Aug 2013 firmware version 2 30 3000 bus info 0000 1a 00 0 ethtool k eth lt x gt Queries the stateless offload status 50 Mellanox Technologies Rev 2 4 Table 7 ethtool Supported Options Options Description ethtool K eth lt x gt rx onloff tx onjoff sg on off tso onloff I
35. ameters 0 0 2 0 ec G N DL al B G a lk rl B Gala 15 1 2 1 mlx4 Module Parameters 1 1 1 aaaksss aka e 15 1 211 ilk Gore Parameters oy t Rata Rn AR Na YER densi 15 12 T2 im n Parameters u 6 epe dae da odes beri dee cere caved 16 Chapter 2 Installation 4 estet ret RR EI 9 ERE EERPXRH RAE TER E x IE IF 2 1 Software Dependencie s sasoi sul a na sd b Ree ee eee eia 17 2 2 Downloading MLNX EN ssssese ere rer rer ere era 17 2 3 Installing MENX EN usa Deer Ie PAN ex SY ale 17 231 Installation Modesz s a al say Sie Seas See eee ah KNEE r rss 17 2 3 2 Installation Procedure 22243003 bet a ads 18 2 3 2 1 Installing MLNX EN on XenServer6 1 2 0 0 0 0 eee 18 2 4 Loading MLNX EN sssseseee n 18 2 5 Unloading MLNX EN ssssee en 19 2 6 Uninstalling MLNX EN sesseseeee me 19 27 Recompiling MENA EN utu San tad La atid velt er do qus abe etos 19 2 8 Firmware Programming llle ern 19 2 8 1 Installing Firmware Tools 19 2 8 2 Updating the Device Online ees 20 2 8 3 Updating Adapter Card Firmware 0 0 ccc cece eee eee eee 20 2 9 Ethernet Driver Usage and Configuration sssssass eee ee 20 2 10 Performance Tunining 0 0 cece eee rer reser 22 Chapter 3 Feature Overview and Configuration ooooooooooomo mo 23 3 1 Quality of Service ti A bad ee ahd Mesa wi ead 23 3 1 1 Mapping Traffic to Traffic ClaSSeS ssesee
36. and Priorities Flow steering defines the concept of domain and priority Each domain represents a user agent that can attach a flow The domains are prioritized A higher priority domain will always super sede a lower priority domain when their flow specifications overlap Setting a lower priority value will result in higher priority In addition to the domain there is priority within each of the domains Each domain can have at most 2112 priorities in accordance to its needs The following are the domains at a descending order of priority Ethtool Ethtool domain is used to attach an RX ring specifically its QP to a specified flow Please refer to the most recent ethtool manpage for all the ways to specify a flow Examples e ethtool U eth5 flow type ether dst 00 11 22 33 44 55 loc 5 action 2 All packets that contain the above destination MAC address are to be steered into rx ring 2 its underlying QP with priority 5 within the ethtool domain ethtool U eth5 flow type tcp4 src ip 1 2 3 4 dst port 8888 loc 5 action 2 All packets that contain the above destination IP address and source port are to be steered into rx ring 2 When destination MAC is not given the user s destination MAC is filled automatically e ethtool u eth5 Shows all of ethtool s steering rule When configuring two rules with the same priority the second rule will overwrite the first one so this ethtool interface is effectively a table Inserting Flo
37. apabilities ethtool 1 eth lt x gt Shows the number of channels ethtool L eth lt x gt rx lt N gt tx lt N gt Sets the number of channels etthtool m dump module eeprom eth lt x gt raw onloff hex onjoff offset N length N Queries Decodes the cable module eeprom information ethtool show priv flags eth lt x gt Shows driver private flags and their states on off Private flags are pm qos request low latency mlx4 rss xor hash function qcn disable 32 14 4 e ethtool set priv flags eth lt x gt lt priv flag gt lt on off gt Enables disables driver feature matching the given private flag ethtool s eth lt x gt speed lt SPEED gt autoneg off Changes the link speed to requested lt SPEED gt To check the supported speeds run ethtool eth lt x gt NOTE autoneg off does not set autoneg OFF it only hints the driver to set a specific speed ethtool s eth lt x gt advertise lt N gt autoneg on Changes the advertised link modes to requested link modes lt N gt To check the link modes hex values run man ethtool gt and to check the supported link modes run ethtoo eth lt x gt NOTE lt autoneg on gt only sends a hint to the driver that the user wants to modify advertised link modes and not speed Checksum Offload MLNX_EN supports the following Receive IP L4 Checksum Offload modes CHECKSUM UNNECESSARY By setting
38. as 2 bits in the traffic control IP header This ENC implementation refers to both RoCE and Routable RoCE ECN command interface is use to configure ECN activity The access to it is through the file sys tem mount of debugfs is required The interface provides a set of changeable attributes and information regarding ECN s counters and statistics Enabling the ECN command interface is done by setting the en ecn module parameter of mlx4 ib to 1 options mlx4 ib en ecn 1 3 9 1 Enabling ECN To enable ECN on the hosts Step 1 Enable ECN in sysfs proc sys net ipv4 tcp ecn 1 Step 2 Enable ECN CLI options mlx4 ib en ecn 1 Step 3 Restart the driver etc init d openibd restart Step 4 Mount debugfs to access ECN attributes mount t debugfs none sys kernel debug Please note mounting of debugfs is required 56 Mellanox Technologies Rev 2 4 The following is an example for ECN configuration through debugfs echo 1 to enable attribute sys kernel debug mlx4_ib lt device gt ecn lt algo gt ports 1 params prios lt prio gt lt the requested attribute gt ENC supports the following algorithms e r roce ecn rp r roce ecn np Each algorithm has a set of relevant parameters and statistics which are defined per device per port per priority r roce ecn np has an extra set of general parameters which are defined per device ECN and QCN are not compatible When using ECN QCN and all its related d
39. ced immedi de ately affecting the behavior of the routine CPU utilization is the preferred method of the adaptive scheme while preserving low values for latency oriented applications However when required latency oriented applications can disable the adaptive scheme and set static low coalescing values Mellanox Technologies 63 Rev 2 4 Feature Overview and Configuration Receive side UDP applications may want to disable this routine as well setting low mid values for interrupt coalescing UDP kernel layer has limited number of packets it can store in a single interrupt so high moderation values may results in packet drop For further information please refer to Section 5 6 Performance Related Issues on page 212 When ingress rate it steady and not affected by changes in the interrupt generation rate rx usecs value is increased until a maximum of rx usecs high value can be set from ethtool C When ingress rate is affected by the routine increasing steps it will lower back to previous rx usecs values and enter suspension state to reduce the future attempts for increasing the rx usecs value gt To disable the adaptive scheme ethtool C eth lt X gt adaptive rx off The relevant configurable values through ethtool e rx usecs low Minimum rx usecs value for the adaptive routine rx usecs high Maximum rx usecs value for adaptive routine rx frames high Upper watermark for the routine When ingress rx rate
40. e untagged or priority tagged outgoing packets from the guest will have the VLAN tag inserted and incoming packets will have the VLAN tag removed Any vlan tagged packets sent by the VF are silently dropped The default behavior is VGT The feature may be controlled on the Hypervisor from userspace via iprout2 netlink ip link set dev DEVICE group DEVGROUP up down vf NUM mac LLADDR vlan VLANID qos VLAN QOS spoofchk on off use ip link set dev PF device vf NUM vlan vlan id qos lt qos gt where NUM 0 max vf num e vlan id 0 4095 4095 means set VGT e qos 0 7 For example ip link set dev eth2 vf 2 qos 3 sets VST mode for VF 2 belonging to PF eth2 with qos 3 ip link set dev eth2 vf 4095 sets mode for VF 2 back to VGT 44 Mellanox Technologies Rev 2 4 3 4 1 6 2 Additional Ethernet VF Configuration Options Guest MAC configuration By default guest MAC addresses are configured to be all zeroes In the MLNX EN guest driver if a guest sees a zero MAC it generates a random MAC address for itself If the administrator wishes the guest to always start up with the same MAC he she should configure guest MACS before the guest driver comes up The guest MAC may be configured by using ip link set dev PF device vf NUM mac lt LLADDR gt For legacy guests which do not generate random MACS the adminstrator should always configure their MAC addres
41. eater than MTU octets and a bad CRC rx in range length error Number of received frames with a length type field value in the decimal range 1500 46 42 1s also counted for VLANtagged frames Mellanox Technologies 59 Rev 2 4 Feature Overview and Configuration Table 8 Port IN Counters Counter Description rx_out range length error Number of received frames with a length type field value in the decimal range 1535 1501 rx_lt 64 bytes packets Number of received 64 or less octet frames rx 127 bytes packets Number of received 65 to 127 octet frames rx 255 bytes packets Number of received 128 to 255 octet frames rx 511 bytes packets Number of received 256 to 511 octet frames rx 1023 bytes packets Number of received 512 to 1023 octet frames rx 1518 bytes packets Number of received 1024 to 1518 octet frames rx 1522 bytes packets Number of received 1519 to 1522 octet frames rx 1548 bytes packets Number of received 1523 to 1548 octet frames rx gt 1548 bytes packets Number of received 1549 or greater octet frames Table 9 Port OUT Counters Counter Description tx packets Total packets successfully transmitted tx bytes Total bytes in successfully transmitted packets tx multicast packets Total multicast packets successfully transmitted tx broadcast packets Total broadcast packets successfully transmitted tx errors Number of
42. ed for VF 1 counter for each port All other counters if exist are allocated by demand e RoCE counters are available only through sysfs located under e sys class infiniband mlx4 ports counters e sys class infiniband mlx4_ ports counters_ext Physical Function can also read Virtual Functions port counters through sysfs located under e sys class net eth vf _statistics To display the network device Ethernet statistics you can run Ethtool S lt devname gt Table 8 Port IN Counters Counter Description rx_packets Total packets successfully received rx_bytes Total bytes in successfully received packets rx_multicast_packets Total multicast packets successfully received rx_broadcast_packets Total broadcast packets successfully received rx_errors Number of receive packets that contained errors preventing them from being deliverable to a higher layer protocol rx_dropped Number of receive packets which were chosen to be discarded even though no errors had been detected to prevent their being deliverable to a higher layer protocol rx_length_errors Number of received frames that were dropped due to an error in frame length TX_OVer_errors Number of received frames that were dropped due to overflow IX CIC errors Number of received frames with a bad CRC that are not runts jabbers or alignment errors rx jabbers Number of received frames with a length gr
43. eds to be used with care as it may easily cause starvation of other TCs A higher strict priority TC is always given the first chance to transmit Only if the highest strict priority TC has nothing more to transmit will the next highest TC be considered Non strict priority TCs will be considered last to transmit This property is extremely useful for low latency low bandwidth traffic Traffic that needs to get immediate service when it exists but is not of high volume to starve other transmitters in the sys tem 3 1 4 2 Minimal Bandwidth Guarantee ETS After servicing the strict priority TCs the amount of bandwidth BW left on the wire may be split among other TCs according to a minimal guarantee policy If for instance TCO is set to 80 guarantee and TC1 to 20 the TCs sum must be 100 then the BW left after servicing all strict priority TCs will be split according to this ratio Since this is a minimal guarantee there is no maximum enforcement This means in the same example that if TC1 did not use its share of 20 the reminder will be used by TCO 3 1 4 3 Rate Limit Rate limit defines a maximum bandwidth allowed for a TC Please note that 10 deviation from the requested values is considered acceptable 3 1 5 Quality of Service Tools 3 1 5 1 minx_qos mlnx qos is a centralized tool used to configure QoS features of the local host It communicates directly with the driver thus does not require setting up a DCBX daem
44. ew and Configuration Enabled by ifreq hwtstamp config tx type when 30 Mellanox Technologies Rev 2 4 Receive side time sampling Enabled by ifreq hwtstamp config rx filter when possible values for hwtstamp config rx filter enum hwtstamp rx filters time stamp no incoming packet at all HWTSTAMP FILTER NONE time stamp any incoming packet HWTSTAMP FILTER ALL return value time stamp all packets requested plus some others HWTSTAMP FILTER SOME PTP v1 UDP any kind of event packet HWTSTAMP FILTER PTP V1 L4 EVENT PTP v1 UDP Sync packet HWTSTAMP FILTER PTP V1 L4 SYNC PTP vl UDP Delay reg packet HWTSTAMP FILTER PTP V1 L4 DELAY REQ PTP v2 UDP any kind of event packet HWTSTAMP FILTER PTP V2 L4 EVENT PTP v2 UDP Sync packet HWTSTAMP FILTER PTP V2 L4 SYNC PTP v2 UDP Delay reg packet HWTSTAMP FILTER PTP V2 L4 DELAY REQ 802 AS1 Ethernet any kind of event packet HWTSTAMP FILTER PTP V2 L2 EVENT 802 AS1 Ethernet Sync packet HWTSTAMP FILTER PTP V2 L2 SYNC 802 AS1 Ethernet Delay req packet HWTSTAMP FILTER PTP V2 L2 DELAY REQ PTP v2 802 A81 any layer any kind of event packet HWTSTAMP FILTER PTP V2 EVENT PTP v2 802 AS1 any layer Sync packet HWTSTAMP FILTER PTP V2 SYNC PTP v2 802 AS1 any layer Delay req packet HWTSTAMP FILTER PTP V2 DELAY REQ
45. frames that failed to transmit tx dropped Number of transmitted frames that were dropped tx lt 64 bytes packets Number of transmitted 64 or less octet frames tx 127 bytes packets Number of transmitted 65 to 127 octet frames tx 255 bytes packets Number of transmitted 128 to 255 octet frames tx 511 bytes packets Number of transmitted 256 to 511 octet frames tx 1023 bytes packets Number of transmitted 512 to 1023 octet frames tx 1518 bytes packets Number of transmitted 1024 to 1518 octet frames tx 1522 bytes packets Number of transmitted 1519 to 1522 octet frames tx 1548 bytes packets Number of transmitted 1523 to 1548 octet frames 60 Mellanox Technologies Rev 2 4 Table 9 Port OUT Counters Counter Description tx gt 1548 bytes packets Number of transmitted 1549 or greater octet frames Table 10 Port VLAN Priority Tagging where i is in the range O 7 Counter Description IX prio lt i gt packets Total packets successfully received with priority 1 IX prio lt i gt bytes Total bytes in successfully received packets with priority i rx novlan packets Total packets successfully received with no VLAN priority rx novlan bytes Total bytes in successfully received packets with no VLAN pri ority tx prio i packets Total packets successfully transmitted with priority 1 tx prio i bytes Total bytes in successfully transmitted packets with priority i tx
46. he adpater ports Related Documentation Table 4 Reference Documents Document Name Description IEEE Std 802 3ae 2002 Amendment to IEEE Std 802 3 2002 Document PDF SS94996 Part 3 Carrier Sense Multiple Access with Collision Detection CSMA CD Access Method and Physical Layer Specifications Amendment Media Access Control MAC Parame ters Physical Layers and Management Parameters for 10 Gb s Operation Support and Updates Webpage Please visit http www mellanox com gt Products gt Software gt Ethernet Drivers gt Linux Drivers for downloads FAQ troubleshooting future updates to this manual etc 12 Mellanox Technologies Rev 2 4 1 Overview This document provides information on the MLNX_EN Linux driver and instructions for install ing the driver on Mellanox ConnectX adapter cards supporting 10Gb s and 40Gb s Ethernet The MLNX EN driver release exposes the following capabilities Single Dual port Upto 16 Rx queues per port 6 Tx queues per port Rxsteering mode Receive Core Affinity RCA e MSI X or INTx Adaptive interrupt moderation HW Tx Rx checksum calculation Large Send Offload 1 e TCP Segmentation Offload Large Receive Offload Multi core NAPI support VLAN Tx Rx acceleration HW VLAN stripping insertion Ethtool support Net device statistics SR IOV support Flow steering Ethernet Time Stamping at beta leve
47. he total vfs parameter to the desired number if you need to change the num ber of total VFs 4 Reburn the firmware using the mlxburn tool if the fields above were added to the INI or the total v s parameter was modified If the mlxburn is not installed please downloaded it from the Mellanox website http www mellanox com gt products gt Firmware tools mlxburn fw fw ConnectX3 rel mlx dev dev mst mt4099 pci cr0 conf MCX341A XCG Ax ini If the current firmware version is the same as one provided with MLNX EN run it in combination with the force fw update parameter This configuration option is supported only in HCAs that their configuration file INI is included in MLNX EN ae Create the text file etc modprobe d mlx4 core conf if it does not exist otherwise delete its contents Insert an option line in the etc modprobe d mlx4 core conf file to set the number of VFs the protocol type per port and the allowed number of virtual functions to be used by the physical function driver probe vf options mlx4 core num vfs 5 probe vf 1 1 2 If SR IOV is supported to enable SR IOV if it is not enabled it is sufficient to set sriov_en true in the INI If the HCA does not support SR IOV please contact Mellanox Support support mellanox com 38 Mellanox Technologies Rev 2 4 Parameter Recommended Value num vfs If absent or zero no VFs will be available e Ifits value is a single nu
48. hich gets a list of lt 16 comma separated UP and maps the sk prio to the specified UP For example tc wrap py ieth0 u 1 5 maps sk prio 0 of etho device to UP 1 and sk prio 1to UP 5 Setting set egress map in VLAN maps the skb priority of the VLAN to a v1an qos The v1an qos is represents a UP for the VLAN device n RoCE rdma set option with ROMA OPTION ID TOS could be used to set the UP When creating QPs the s1 field in ibv modify qp command represents the UP Indicating the TC After mapping the skb priority to UP one should map the UP into a TC This assigns the user priority to a specific hardware traffic class In order to do that n1nx qos should be used m1nx qos gets a list of a mapping between UPs to TCs For example m1nx qos ieth0 p 0 0 0 0 1 1 1 1 maps UPs 0 3 to Tco and Ups 4 7 to Tc1 3 1 4 Quality of Service Properties The different QoS properties that can be assigned to a TC are Strict Priority see Strict Priority e Minimal Bandwidth Guarantee ETS see Minimal Bandwidth Guarantee ETS Rate Limit see Rate Limit 3 1 4 1 Strict Priority When setting a TC s transmission algorithm to be strict then this TC has absolute strict prior ity over other TC strict priorities coming before it as determined by the TC number TC 7 is highest priority TC 0 is lowest It also has an absolute priority over non strict TCs ETS 24 Mellanox Technologies Rev 2 4 This property ne
49. his feature please refer to Table 7 ethtool Supported Options on page 50 3 11 XOR RSS Hash Function The device has the ability to use XOR as the RSS distribution function instead of the default Toplitz function The XOR function can be better distributed among driver s receive queues in small number of streams where it distributes each TCP UDP stream to a different queue MLNX EN v2 2 1 0 0 and onwards provides an option to change the working RSS hash function from Toplitz to XOR and vice versa through ethtool priv flags For further information please refer to Table 7 ethtool Supported Options on page 50 3 12 Ethernet Performance Counters Counters are used to provide information about how well an operating system an application a service or a driver is performing The counter data helps determine system bottlenecks and fine tune the system and application performance The operating system network and devices pro vide counter data that an application can consume to provide users with a graphical view of how well the system is performing 58 Mellanox Technologies Rev 2 4 The counter index is a QP attribute given in the QP context Multiple QPs may be associated with the same counter set If multiple QPs share the same counter its value represents the cumulative total ConnectX 3 support 127 different counters which allocated e 4 counters reserved for PF 2 counters for each port 2counters reserv
50. host Ifits a triplet x y z applies only if all ports are config ured as Ethernet the driver probes x single port VFs on physical port 1 y single port VFs on physical port 2 applies only if such a port exist zn port VFs where n is the number of physical ports on device Those VFs are attached to the hypervisor Ifits format is a string the string specifies the probe_vf parameter separately per installed HCA The string format is bb dd f v bb dd f v bb dd f bus device function of the PF of the HCA y number of VFs to use in the PF driver for that HCA which is either a single value or a triplet as described above For example probe vfs 5 The PF driver will activate 5 VFs on the HCA and this will be applied to all ConnectX HCAs on the host probe vfs 00 04 0 5 00 07 0 8 The PF driver will activate 5 VFs on the HCA positioned in BDF 00 04 0 and 8 for the one in 00 07 0 40 Mellanox Technologies Rev 2 4 Parameter Recommended Value probe_vf probe_vf 1 2 3 The PF driver will activate 1 VF on physical port 1 2 VFs on physical port 2 and 3 dual port VFs applies only to dual port HCA when all ports are Ethernet ports This applies to all ConnectX HCAs in the host probe vf 00 04 0 5 6 7 00 07 0 8 9 10 The PF driver will activate HCA positioned in BDF 00 04 0 Ssingle VFs on port 1 6single VFs on port 2 7 dual port VFs HCA positioned in BDF 00 07
51. ions flag options Added the following new flags ethtool s eth lt x gt speed lt SPEED gt autoneg off and ethtool s eth lt x gt advertise lt N gt autoneg on Updated port type array parameter description in Section 3 4 1 2 Setting Up SR IOV on page 36 Updated the following sections Section 3 7 Checksum Offload on page 52 Section 3 4 2 VXLAN Hardware Stateless Offloads on page 48 Section 3 4 22 Enabling VXLAN Hardware Stateless Offloads on page 48 Section 4 3 Performance Related Issues on page 68 2 3 2 0 1 November 27 2014 Added Section 3 5 1 5 Extended Error Handling EEH on page 50 8 Mellanox Technologies Rev 2 4 1 0 0 1 Table 1 Document Revision History Release Date Description 2 3 1 0 0 September 2014 e Added the following sections Section 1 1 1 Tarball Package on page 13 Section 1 1 3 Firmware on page 14 Section 1 1 4 Directory Structure on page 14 Section 1 2 1 mlx4 Module Parameters on page 15 Section 2 2 Downloading MLNX EN on page 17 Section 2 3 1 Installation Modes on page 17 Section 3 3 2 Flow Steering Support on page 33 Section 3 3 3 AO Static Device Managed Flow Steer ing on page 33 Section 3 4 1 8 Virtual Guest Tagging VGT on page 46 Section 3 5 1 Reset Flow on page 49 and its subsections Section 3 9 Explicit Congestion Notification EC
52. irtual machine and verify that it recognizes the Mellanox card Run lspci grep Mellanox 00 03 0 InfiniBand Mellanox Technologies MT27500 Family ConnectX 3 Virtual Function rev b0 Mellanox Technologies 43 J Rev 2 4 Feature Overview and Configuration 3 4 1 5 3 4 1 6 3 4 1 6 1 Step 7 Add the device to the etc sysconfig network scripts ifcfg ethx configuration file The MAC address for every virtual function is configured randomly therefore it is not necessary to add it Uninstalling SR IOV Driver gt To uninstall SR IOV driver perform the following Step 1 For Hypervisors detach all the Virtual Functions VF from all the Virtual Machines VM or stop the Virtual Machines that use the Virtual Functions Please be aware stopping the driver when there are VMs that use the VFs will cause machine to hang Step2 Run the script below Please be aware uninstalling the driver deletes the entire driver s file but does not unload the driver sbin mlnx en uninstall sh MLNX EN uninstall done Step3 Restart the server Ethernet Virtual Function Configuration when Running SR IOV VLAN Guest Tagging VGT and VLAN Switch Tagging VST When running ETH ports on VFs the ports may be configured to simply pass through packets as is from VFs Vlan Guest Tagging or the administrator may configure the Hypervisor to silently force packets to be associated with a VLan Qos Vlan Switch Tagging In the latter cas
53. isconfiguration of the switch s split ports Use supported ports on the switch with proper configuration For fur ther information please refer to the MLNX OS User Manual Make sure the QSFP break out cable side is connected to the SwitchX Physical link fails to The adapter is running an Install the latest firmware on the negotiate to maximum outdated firmware adapter supported rate Physical link fails to The cable is not connected Ensure that the cable is connected on come up while port physical state is Polling to the port or the port on the other end of the cable is disabled both ends or use a known working cable Check the status of the connected port using the ibportstate com mand and enable it if necessary Physical link fails to come up while port physical state is Dis abled The port was manually dis abled Restart the driver etc init d openibd restart Mellanox Technologies 67 Rev 2 4 1 0 0 1 Troubleshooting 4 3 Performance Related Issues Table 17 Performance Related Issues Issue Cause Solution The driver works but the These recommendations may assist with transmit and or receive gaining immediate improvement data rates are not opti 1 Confirm PCI link negotiated uses its mal maximum capability 2 Stop the IRQ Balancer service etc init d irq balancer stop 3 Start mInx affinity service mlnx affinity start For best performance practices
54. its packets using outer UDP header Available hardware stateless offloads e Checksum generation Inner IP and Inner TCP UDP e Checksum validation Inner IP and Inner TCP UDP This will allow the use of GRO for inner TCP packets e TSO support for inner TCP packets RSS distribution according to inner packets attributes Receive queue selection inner frames may be steered to specific QPs 3 4 2 1 Prerequisites e HCA ConnectX 3 Pro Firmware 2 32 5100 or higher RHEL7 Ubuntu 14 04 or upstream kernel 3 12 10 or higher DMFS enabled e AO static mode disabled 3 4 2 2 Enabling VXLAN Hardware Stateless Offloads To enable the VXLAN offloads support load the m1x4_core driver with Device Managed Flow steering DMFS enabled DMFS is the default steering mode gt To verify it is enabled by the adapter card Step 1 Open the etc modprobe d mlnx conf file Step 2 Set the parameter debug level to 1 options mlx4 core debug level 1 Step3 Restart the driver Step 4 Verify in the dmesg that the tunneling mode is vx1an The net device will advertise the tx udp tn1 segmentation flag shown when running etht hool k SDEV grep udp only when VXLAN is configured in the OpenvSwitch OVS with the configured UDP port For example ethtool k eth0 grep udp tnl tx udp tnl segmentation on As of firmware version 2 31 5050 VXLAN tunnel can be set on any desired UDP port If using previous firmware versions set the
55. l 1 1 MLNX EN Package Contents 1 1 4 Tarball Package MLNX EN for Linux is provided as a tarball that includes source code and firmware The tarball contains an installation script called install sh that performs the necessary steps to accomplish the following Discover the currently installed kernel Uninstall any previously installed MLNX OFED MLNX EN packages nstall the MLNX EN binary if they are available for the current kernel Identify the currently installed HCAs and perform the required firmware updates Mellanox Technologies 13 J Rev 2 4 Overview 1 1 2 Software Components MLNX_EN contains the following software components Table 5 MLNX_EN Software Components Components Description mlx4 driver mlx4 is the low level driver implementation for the ConnectX adapters designed by Mellanox Technologies The ConnectX can operate as an InfiniBand adapter and as an Ethernet NIC To accommodate the two flavors the driver is split into modules mlx4 core mlx4 en and mlx4 ib Note mlx4 ib is not part of this package mlx4 core Handles low level functions like device initialization and firmware commands processing Also controls resource allocation so that the InfiniBand Ethernet and FC functions can share a device without interfering with each other mlx4 en Handles Ethernet specific functions and plugs into the netdev mid layer mstflint An application to burn a firmware binary image
56. mber in the range of 0 63 The driver will enable the num v s VFs on the HCA and this will be applied to all ConnectX amp HCAs on the host Ifits a triplet x y z applies only if all ports are config ured as Ethernet the driver creates xsingle port VFs on physical port 1 ysingle port VFs on physical port 2 applies only if such a port exist zn port VFs where n is the number of physical ports on device This applies to all ConnectX HCAs on the host fits format is a string The string specifies the num vfs parameter separately per installed HCA The string format is bb dd f v bb dd f v bb dd f bus device function of the PF of the HCA v number of VFs to enable for that HCA which is either a single value or a triplet as described above For example num _vfs 5 The driver will enable 5 VFs on the HCA and this will be applied to all ConnectX HCAs on the host num vfs 00 04 0 5 00 07 0 8 The driver will enable 5 VFs on the HCA positioned in BDF 00 04 0 and 8 on the one in 00 07 0 num vfs 1 2 3 The driver will enable 1 VF on physical port 1 2 VFs on physical port 2 and 3 dual port VFs applies only to dual port HCA when all ports are Ethernet ports num vfs 00 04 0 5 6 7 00 07 0 8 9 10 The driver will enable HCA positioned in BDF 00 04 0 Ssingle VFs on port 1 e 6single VFs on port 2 7 dual port VFs HCA positioned in BDF 00 07 0 Ssingle VFs on port 1 Osingle VFs on p
57. o uninstall the Mellanox OFED package 2 7 Recompiling MLNX EN gt To recompile the driver Step 1 Enter the source directory gt cd usr src mellanox mlnx en 2 0 Step2 Apply kernel backport patch gt scripts mlnx en patch sh Step 3 Compile the driver sources gt make Step 4 Install the driver kernel modules gt make install 2 8 A Firmware Programming The adapter card was shipped with the most current firmware available This section is intended for future firmware upgrades and provides instructions for 1 installing Mellanox firmware update tools MFT 2 downloading FW and 3 updating adapter card firmware 2 8 1 Installing Firmware Tools The driver package compiles and installs the Mellanox mstflint utility under usr local bin You may also use this tool to burn a card specific firmware binary image See the file tmp mlnx en src utils mstflint README file for details Alternatively you can download the current Mellanox Firmware Tools package MFT from www mellanox com gt Products gt Adapter IB VPI SW gt Firmware Tools The tools package to download is MFT SW for Linux tarball name is mft X X X tgz For help in identifying your adapter card please visit http www mellanox com content pages php pg firmware HCA FW identification Mellanox Technologies 19 Rev 2 4 Installation 2 8 2 Updating the Device Online To update the device online on the machine from Mellano
58. on on the system The minx qos tool enables the administrator of the system to Inspect the current QoS mappings and configuration The tool will also display maps configured by TC and vconfig set_egress_map tools in order to give a centralized view of all QoS mappings Set UP to TC mapping Assign a transmission algorithm to each TC strict or ETS Set minimal BW guarantee to ETS TCs Setrate limit to TCs For unlimited ratelimit set the ratelimit to 0 P Usage mlnx qos i interface options Mellanox Technologies 25 Rev 2 4 Feature Overview and Configuration Options 3 1 5 1 1 Get Current Configuration 26 Mellanox Technologies Rev 2 4 3 1 5 1 2 Set ratelimit 3Gbps for tc0 4Gbps for tc1 and 2Gbps for tc2 3 1 5 1 3 Configure QoS map UP 0 7 to tc0 1 2 3 to tc1 and 4 5 6 to tc 2 set tc0 tc1 as ets and tc2 as strict divide ets 30 for tc0 and 70 for tc1 Mellanox Technologies 27 Rev 2 4 Feature Overview and Configuration vos 7 tc 1 ratelimit 4 Gbps tsa ets bw 70 tes wide 2 bias E tc 2 ratelimit 2 Gbps tsa strict biog A mas 5 up 6 3 1 5 2 tcand tc_wrap py The tc tool is used to setup sk_prio to UP mapping using the maprio queue discipline In kernels that do not support maprio such as 2 6 34 an alternate mapping is created in sysfs The tc_wrap py tool will use either the sysfs or the tc tool to configure the sk_prio to UP
59. op enable 64b cqe ege log num mac log num vlan log mtts per seg Obsolete attempt to set 4K MTU to all ConnectX ports int Enable debug tracing if 0 int 0 don t use MSI X D VIS NSE gt 1 limit number of MSI X irqs to msi x non SRIOV only int Tune the cpu s for better performance default 0 int Block multicast loopback packets if gt 0 default 1 int Either a single value e g 5 to define uniform num vfs value for all devices functions or a string to map device func tion numbers to their num vfs values e g 0000 04 00 0 5 002b 1c 0b a 15 Hexadecimal digits for the device function e g 002b 1c 0b a and decimal for num vfs value e g 15 string Either a single value e g 3 to indicate that the Hypervi Sor driver itself should activate this number of VFs for each HCA on the host or a string to map device function numbers to their probe vf values e g 0000 04 00 0 3 002b 1c 0b a 13 Hexadecimal digits for the device function e g 002b 1c 0b a and decimal for probe vf value e g 13 string log mgm size that defines the num of qp per mcg for example 10 gives 248 range 7 log num mgm entry size 12 To activate device managed flow steering when available set to 1 int Enable steering mode for higher packet rate default off int Enable fast packet drop when no recieve WQEs are posted int Enable 64 byte CQEs EQEs when the FW supports this if non zero defaul
60. ore a particular time Incoming packets are time stamped before they are distributed on the PCI depending on the congestion in the PCI buffers Outgoing packets are time stamped very close to placing them on the wire 3 2 1 Enabling Time Stamping Time stamping is off by default and should be enabled before use gt To enable time stamping for a socket Call setsockopt with SO TIMESTAMPING and with the following flags SOF TIMESTAMPING TX HARDWARE try to obtain send time stamp in hardware SOF TIMESTAMPING TX SOFTWARE if SOF TIMESTAMPING TX HARDWARE is off or fails then do it in software SOF TIMESTAMPING RX HARDWARE return the original unmodified time stamp as generated by the hardware SOF TIMESTAMPING RX SOFTWARE if SOF TIMESTAMPING RX HARDWARE is off or fails then do it in software SOF TIMESTAMPING RAW HARDWARE return original raw hardware time stamp SOF TIMESTAMPING SYS HARDWARE return hardware time stamp transformed to the system time base SOF TIMESTAMPING SOFTWARE return system time stamp generated in software SOF TIMESTAMPING TX RX determine how time stamps are generated SOF TIMESTAMPING RAW SYS determine how they are reported To enable time stamping for a net device Admin privileged user can enable disable time stamping through calling ioctl sock SIOCSHWT STAMP amp ifreq with following values Send side time sampling Mellanox Technologies 29 J Rev 2 4 Feature Overvi
61. ort 2 10 dual port VFs Applies when all ports are configure as Ethernet in dual port HCAs Mellanox Technologies 39 Rev 2 4 Feature Overview and Configuration Parameter Recommended Value num vfs Notes e PFs not included in the above list will not have SR IOV enabled Triplets and single port VFs are only valid when all ports are configured as Ethernet When an InfiniBand port exists only num v s a syntax is valid where a is a single value that represents the number of VFs The second parameter in a triplet is valid only when there are more than 1 physical port In a triplet x z lt 63 and y z lt 63 the maximum number of VFs on each physical port must be 63 port type array Specifies the protocol type of the ports It is either one array of 2 port types t1 t2 for all devices or list of BDF to port type array bb dd f t1 t2 string Valid port types 1 ib 2 eth 3 auto 4 N A If only a single port is available use the N A port type for port2 e g 1 4 Note that this parameter is valid only when num_v s is not zero 1 e SRIOV is enabled Otherwise it is ignored probe vf If absent or zero no VF interfaces will be loaded in the Hypervisor host Ifnum_vfs is a number in the range of 1 63 the driver running on the Hypervisor will itself activate that number of VFs All these VFs will run on the Hyper visor This number will apply to all ConnectX HCAs on that
62. over UDP Change the default behavior only if non tcp udp is very common CHECKSUM NONE By setting this mode the driver indicates to the Linux Network ing Stack that the hardware failed to validate the IP or L4 checksum so the Linux Net working Stack must calculate and validate the IP L4 Checksum Checksum None is passed to OS for all other cases 3 8 Quantized Congestion Control Congestion control is used to reduce packet drops in lossy environments and mitigate congestion spreading and resulting victim flows in lossless environments The Quantized Congestion Notification QCN IEEE standard 802 1Qau provides congestion control for long lived flows in limited bandwidth delay product Ethernet networks It is part of the IEEE Data Center Bridging DCB protocol suite which also includes ETS PFC and DCBX QCN in conducted at L2 and is targeted for hardware implementations QCN applies to all Ethernet packets and all transports and both the host and switch behavior is detailed in the standard QCN user interface allows the user to configure QCN activity QCN configuration and retrieval of information is done by the m1nx qcn tool The command interface provides the user with a set of changeable attributes and with information regarding QCN s counters and statistics All parameters and statistics are defined per port and priority QCN command interface is available 1f and only the hardware supports it Mellanox Technologies
63. policy The policy determines which VLAN IDs are allowed to be transmitted or received The policy does not determine the user priority which is left unchanged Packets can be send in one of the following modes when the VF is allowed to send receive untagged and priority tagged traffic and when it is not No default VLAN is defined for VGT port The send packets are passed to the eSwitch only if they match the set and the received packets are forwarded to the VF only if they match the set The following are current VGT limitations e The size of the VLAN set is defined to be up to 10 VLANs including the VLAN 0 that is added for untagged priority tagged traffic This behavior applies to all VF traffic plain Ethernet and all RoCE transports e VGT allowed VLAN sets may be only extended when the VF is online e An operational VLAN set becomes identical as the administration VLAN set only after a VF reset e VGT is available in DMFS mode only 46 Mellanox Technologies Rev 2 4 3 4 1 8 1 Configuring VGT The default operating mode is VGT cat sys class net eth5 vf0 vlan set oper admin Both states operational and administrative are empty p If you set the vlan set parameter with more the 10 VLAN IDs the driver chooses the first 10 VLAN IDs provided and ignores all the rest gt To enable VGT mode Step 1 Set the corresponding port VF in the example below port ethS VFO list of allowed VLANs echo 012345678
64. ration Example cat sys class net eth2 fdb det device eth2 max 112 used 2 free macs 110 gt To add anew MAC to the interface echo lt MAC gt gt sys class net eth lt X gt fdb Once running the command above the interface VF PF verifies if a free MAC exists If there is a free MAC the VF PF takes it from the global pool and allocates it If there is no free MAC an error is returned notifying the user of lack of MACs in the pool gt To delete a MAC from the interface echo lt MAC gt gt sys class net eth lt X gt fdb If sys class net eth lt X gt fdb does not exist use the Bridge tool from the ip route2 package which includes the tool to manage FDB tables as the kernel supports FDB callbacks bridge fdb add 00 01 02 03 04 05 permanent self dev p3p1 bridge fdb del 00 01 02 03 04 05 permanent self dev p3pl bridge fdb show dev p3pl If adding a new MAC from the kernel s NDO function fails due to insufficient MACS in the pool the following error flow will occur d f the interface is a PF it will automatically enter the promiscuous mode If the interface is a VF it will try to enter the promiscuous mode and since it does not support it the action will fail and an error will be printed in the kernel s log 3 4 1 8 Virtual Guest Tagging VGT VGT is an advanced mode of Virtual Guest Tagging VGT in which a VF is allowed to tag its own packets as in VGT but is still subject to an administrative VLAN trunk
65. rerererrererr eee nee 23 3 1 2 Plain Ethernet Quality of Service Mapping 00 00 e cee ee eee 23 3 1 3 Map Priorities with tc wrap py mlnx qos 0 ce eee cece teens 24 3 1 4 Quality of Service Properties 0 0 rr 24 3 T5 T Strict Priority is ex tee auum Sears nes sk 24 3 1 4 2 Minimal Bandwidth Guarantee ETS 00 cece eens 25 3 143 AA Wes ale tre reos re ee ST a 25 3 1 9 Qualityof Service Tools mid s Sete sara SRI R Vale eas Vale es 25 321 51 mil qos 42 4 a i a slaves oho pe yeh ke Pes ee os Mar 25 3 1 5 2 tesand tCwrap PY Cs aa ts Pane ta daa gwd das ae Ru Raw eB Ra 28 3 1 5 3 Additional Tools W cacareado ina dae vea uo 29 Mellanox Technologies 3 J Rev 2 4 3 2 Tame Stamping Service Nic A AS ene gs ae 29 3 2 1 Enabling Time Stamping 0 0 0 eens 29 3 2 2 Getting Time Stamping 0 0 eee eens 31 3 3 Flow Steering A A E AERE 32 3 3 1 Enable Disable Flow Steering llli eee 32 3 3 2 Flow Steering SUpport 3 si ao b bossen a n 33 3 3 3 AO Static Device Managed Flow Steering 00 0000 ce skaka 33 3 3 4 Flow Domains and Priorities 0 0 000 cette eens 34 3 4 Vurt alization toes ce eect Weare eke de Me e a Aa eee ue ed 35 3 4 1 Single Root IO Virtualization SR IOV 00 c ccc rese rr 35 3 4 1 1 System Requirements 5 4 cse ko e an sass dec aaa al 36 3 4 1 2 Setting Up SR IOV us grej ac a d
66. ro onjoff gro onloff gso onjoff rxvlan onjoff txvlan onjoff ntu ple on off rxhash on off Sets the stateless offload status TCP Segmentation Offload TSO Generic Segmentation Offload GSO increase outbound throughput by reducing CPU overhead It works by queuing up large buffers and letting the network interface card split them into separate packets Large Receive Offload LRO increases inbound through put of high bandwidth network connections by reducing CPU overhead It works by aggregating multiple incoming packets from a single stream into a larger buffer before they are passed higher up the networking stack thus reducing the number of packets that have to be processed LRO is available in kernel versions 3 1 for untagged traffic Hardware VLAN insertion Offload txvlan When enabled the sent VIAN tag will be inserted into the packet by the hardware Note LRO will be done whenever possible Otherwise GRO will be done Generic Receive Offload GRO is available throughout all kernels Hardware Vlan Striping Offload rxvlan When enabled received VIAN traffic will be stripped from the VLAN tag by the hardware ethtool c eth lt x gt Queries interrupt coalescing settings ethtool C eth lt x gt adaptive rx onloff Enables disables adaptive interrupt moderation By default the driver uses adaptive interrupt moderation for the receive path which adjusts the moderation time to the tr
67. s In order to maintain flexibil ity domains and priorities are used Flow steering uses a methodology of flow attribute which is a combination of L2 L4 flow specifications a destination QP and a priority Flow steering rules could be inserted either by using ethtool or by using InfiniBand verbs The verbs abstraction uses an opposed terminology of a flow attribute ibv flow attr defined by a combination of specifi cations struct ibv_flow_spec_ 3 3 1 Enable Disable Flow Steering Flow steering is generally enabled when the 1og num mgm entry size module parameter is non positive e g 1og num mgm entry size meaning the absolute value of the parameter is a bit field Every bit indicates a condition or an option regarding the flow steering mechanism reserved b2 b1 bo bit Operation Description b0 Force device managed Flow When set to 1 it forces HCA to be enabled regardless of Steering whether NC SI Flow Steering is supported or not bl Disable IPoIB Flow Steering When set to 1 it disables the support of IPoIB Flow Steer ing This bit should be set to 1 when b2 Enable AO static DMES steering is used see Section 3 3 3 AO Static Device Managed Flow Steering on page 33 b2 Enable AO static DMFS When set to 1 AO static DMFS steering is enabled This steering see Section 3 3 3 bit should be set to 0 when b1 Disable IPoIB Flow Steer AO Static Device Managed ing is 0 Flo
68. ses via ip link as above Spoof checking Spoof checking is currently available only on upstream kernels newer than 3 1 ip link set dev lt PF device gt vf lt NUM gt spoofchk on off 3 4 1 6 3 Mapping VFs to Ports using the mInx get vfs pl Tool To map the PCI representation in BDF to the respective ports mlnx get vfs pl The output is as following BDF 0000 04 00 0 iow dg 2 vf0 0000 04 00 1 v l 0000 04 00 2 orice 2232 vf2 0000 04 00 3 vf3 0000 04 00 4 Both 1 vf4 0000 04 00 5 3 4 1 7 MAC Forwarding DataBase FDB Management 3 4 1 7 1 FDB Status Reporting FDB also know as Forwarding Information Base FIB or the forwarding table is most com monly used in network bridging routing and similar functions to find the proper interface to which the input interface should forward a packet In the SR IOV environment the Ethernet driver can share the existing 128 MACs for each port among the Virtual interfaces VF and Physical interfaces PF that share the same table as fol low Each VF gets 2 granted MACs which are taken from the general pool of the 128 MACs Each VF PF can ask for up to 128 MACs on the policy of first asks first served mean ing except for the 2 granted MACs the other MACs in the pool are free to be asked To check if there are free MACs for its interface PF or VF run sys class net lt ethX gt fdb det Mellanox Technologies 45 Rev 2 4 Feature Overview and Configu
69. t rx lt N gt tx lt N gt gt To obtain additional device statistics gt ethtool S eth lt x gt gt To perform a self diagnostics test gt ethtool t eth x The driver defaults to the following parameters Mellanox Technologies 21 Rev 2 4 Installation Both ports are activated 1 e a net device is created for each port e The number of Rx rings for each port is the nearest power of 2 of number of cpu cores limited by 16 LRO is enabled with 32 concurrent sessions per Rx ring Some of these values can be changed using module parameters which can be displayed by run ning gt modinfo mlx4 en To set non default values to module parameters add to the etc modprobe conf file options mlx4 en lt param name value lt param_name gt lt value gt Values of all parameters can be observed in sys module mlx4 en parameters 2 10 Performance Tunining For further information on Linux performance please refer to the Performance Tuning Guide for Mellanox Network Adapters 22 Mellanox Technologies Rev 2 4 3 Feature Overview and Configuration 3 1 Quality of Service Quality of Service QoS is a mechanism of assigning a priority to a network flow socket rdma_cm connection and manage its guarantees limitations and its priority over other flows This is accomplished by mapping the user s priority to a hardware TC traffic class through a 2 3 stages process The T
70. t 1 int Log2 max number of MACs per ETH port 1 7 int Obsolete Log2 max number of VLANs per ETH port 0 7 int Log2 number of MTT entries per segment 0 7 default 0 int Rev 2 4 Overview port type array log num gp log num srq log rdmarc per gp log num cq log num mcg log num mpt log num mtt enable gos internal err reset 1 2 1 2 mlx4 en Parameters inline thold udp rss pictx pfcrx Either pair of values e g 1 2 to define uniform port1 port2 types configuration for all devices functions or a String to map device function numbers to their pair of port types values e g 0000 04 00 0 1 2 002b 1c 0b a 1 1 Valid port types 1 ib 2 eth 3 auto 4 N A If only a single port is available use the N A port type for pora e b a s log maximum number of QPs per HCA default 19 int log maximum number of SRQs per HCA default 16 int log number of RDMARC buffers per QP default 4 int log maximum number of CQs per HCA default 16 int log maximum number of multicast groups per HCA default 13 int log maximum number of memory protection table entries per HCA default 19 int log maximum number of memory translation table segments per HCA default max 20 2 MTTs for register all of the host mem ory limited to 30 int Enable Quality of Service support in the HCA default off bool Reset device on internal errors if non zero default is 1
71. t packet bytes received successfully vport lt i gt rx broadcast pac kets Broadcast packets received successfully vport lt i gt rx broadcast byte S Broadcast packet bytes received successfully vport lt i gt rx dropped Received packets discarded due to out of buffer condition vport lt i gt rx errors Received packets discarded due to receive error condition vport lt i gt tx unicast packet S Unicast packets sent successfully vport lt i gt tx unicast bytes Unicast packet bytes sent successfully vport lt i gt tx multicast pack ets Multicast packets sent successfully vport lt i gt tx multicast byte S Multicast packet bytes sent successfully vport lt i gt tx broadcast pac kets Broadcast packets sent successfully vport lt i gt tx broadcast byte S Broadcast packet bytes sent successfully vport lt i gt tx errors Packets dropped due to transmit errors Table 13 SW Statistics Counter Description rx lro aggregated Number of packets aggregated rx lro flushed Number of LRO flush to the stack rx lro no desc Number of times LRO description was not found 62 Mellanox Technologies Rev 2 4 Table 13 SW Statistics Counter Description rx_alloc failed Number of times failed preparing receive descriptor IX csum good Number of packets received with good checksum
72. tX 3 Virtual Function rev b0 03 00 4 InfiniBand Mellanox Technologies MT27500 Family ConnectX 3 Virtual Function rev b0 03 00 5 InfiniBand Mellanox Technologies MT27500 Family ConnectX 3 Virtual Function rev b0 Where e 03 00 represents the Physical Function Mellanox Technologies 41 Rev 2 4 Feature Overview and Configuration e 03 00 X represents the Virtual Function connected to the Physical Function 3 4 1 3 Enabling SR IOV and Para Virtualization on the Same Setup gt To enable SR IOV and Para Virtualization on the same setup Step 1 Create a bridge vim etc sysconfig network scripts ifcfg bridgeO DEVICE bridge0 TYPE Bridge IPADDRS12 195 15 1 NETMASK 255 255 0 0 BOOTPROTO static ONBOOT yes NM CONTROLLED no DELAY 0 Step 2 Change the related interface in the example below bridge0 is created over eth5 DEVICE eth5 BOOTPROTO none STARTMODE on HWADDRz00 02 c9 2e 66 52 TYPE Ethernet NM CONTROLLED no ONBOOT yes BRIDGE bridge0 Step 3 Restart the service network Step 4 Attach a virtual NIC to VM ifconfig a eth6 Link encap Ethernet HWaddr 52 54 00 E7 77 99 inet addr 13 195 15 5 Bcast 13 195 255 255 Mask 255 255 0 0 inet6 addr fe80 5054 ff fee7 7799 64 Scope Link UP BROADCAST RUNNING MULTICAST MTU 1500 Metric 1 RX packets 481 errors 0 dropped 0 overruns 0 frame 0 TX packets 450 errors 0 dropped 0 overruns 0 carrier 0 collisions 0 txqueuelen 1000 RX bytes 22440 21 9 KiB T
73. tep 3 Restart the driver 3 3 2 Flow Steering Support gt To determine which Flow Steering features are supported ethtool show priv flags eth4 The following output is shown mlx4 flow steering ethernet 12 on Creating Ethernet L2 MAC rules is supported mlx4 flow steering ipv4 on Creating IPv4 rules is supported mlx4 flow steering tcp on Creating TCP UDP rules is supported Flow Steering support in InfiniBand is determined according to the EXP MANAGED FLOW STEERING flag af 3 3 3 A0 Static Device Managed Flow Steering This mode enables fast steering however it might impact flexibility Using it increases the packet rate performance by 30 with the following limitations for Ethernet link layer unicast QPs Limits the number of opened RSS Kernel QPs to 96 MACs should be unique 1 MAC per 1 QP The number of VFs is limited Mellanox Technologies 33 Rev 2 4 Feature Overview and Configuration 3 3 4 When creating Flow Steering rules for user QPs only MAC gt QP rules are allowed Both MACs and QPs should be unique between rules Only 62 such rules could be cre ated When creating rules with Ethtool MAC gt QP rules could be used where the QP must be the indirection RSS QP Creating rules that indirect traffic to other rings is not allowed Ethtool MAC rules to drop packets action 1 are supported RFS is not supported in this mode VLAN is not supported in this mode Flow Domains
74. tes mellanox mlnx en On RHEL kmod mellanox mlnx en RPM lib modules lt kernel ver gt extra mellanox mlnx en For non KMP RPMs mlnx en RPM On SLES 1ib modules lt kernel ver gt updates mlnx_en On RHEL 1ib modules kernel ver extra mlnx en The kernel module sources are placed under usr src mellanox mlnx en lt ver gt 2 3 2 Installation Procedure Step 1 Login to the installation machine as root Step 2 Extract the tarball image on your machine gt tar xzvf mlnx en 2 3 1 0 0 tgz Step3 Change the working directory gt cd ming en 2 3 1 0 0 Step 4 Run the installation script gt install sh 2 3 2 1 Installing MLNX_EN on XenServer6 1 gt To install mInx en 2 3 1 0 0 on XenServer6 1 rpm ihv RPMS xenserver6ul i386 uname r mlnx en rpm 2 4 Loading MLNX EN Step 1 Make sure no previous driver version is currently loaded gt modprobe r mlx4 en Step 2 Load the new driver version gt modprobe mlx4 en The result is a new net device appearing in the ifconfig a output For details on driver usage and configuration please refer to Section 2 8 Firmware Programming on page 19 On Ubuntu OS the mlnx en service is responsible for loading the mlx4 en driver upon boot 18 Mellanox Technologies Rev 2 4 2 5 Unloading MLNX_EN gt To unload the Ethernet driver gt modprobe r mlx4_en 2 6 Uninstalling MLNX_EN Use the script sbin mlnx en uninstall sh t
75. thtool Aha Allof the rest The lowest priority domain serves the following users The mlx4 Ethernet driver attaches its unicast and multicast MACs addresses to its QP using L2 flow specifications Fragmented UDP traffic cannot be steered It is treated as other protocol by hardware from the first packet and not considered as UDP traffic 3 4 Virtualization 3 4 1 Single Root IO Virtualization SR IOV Single Root IO Virtualization SR IOV is a technology that allows a physical PCIe device to present itself multiple times through the PCIe bus This technology enables multiple virtual instances of the device with separate resources Mellanox adapters are capable of exposing in ConnectX 3 adapter cards up to 126 virtual instances called Virtual Functions VFs These vir tual functions can then be provisioned separately Each VF can be seen as an addition device con nected to the Physical Function It shares the same resources with the Physical Function and its number of ports equals those of the Physical Function SR IOV is commonly used in conjunction with an SR IOV enabled hypervisor to provide virtual machines direct hardware access to network resources hence increasing its performance In this chapter we will demonstrate setup and configuration of SR IOV in a Red Hat Linux envi ronment using Mellanox ConnectX VPI adapter cards family Mellanox Technologies 35 Rev 2 4 Feature Overview and Configuration
76. tionality 2 Reseat the adapter in its PCI slot or device insert the adapter to a different PCI slot If the PCI slot confirmed to be func tional the adapter should be replaced Mellanox adapters are Misidentification of the Run the command below and check not installed in the sys Mellanox adapter installed Mellanox s MAC to identify the Mella tem nox adapter installed lspci grep Mellanox or lspci d 15b3 Mellanox MACs start with 00 02 C9 xx xx xx 00 25 8B xx xx xx or F4 52 14 xx xx xx 4 2 Ethernet Related Issues Table 16 Ethernet Related Issues Issue Cause Solution No link Misconfiguration of the Ensure the switch port is not down switch port or using a cable Ensure the switch port rate is config not supporting link rate ured to the same rate as the adapter s port 66 Mellanox Technologies Table 16 Ethernet Related Issues Rev 2 4 1 0 0 1 Issue Cause Solution Degraded performance is measured when hav ing a mixed rate envi ronment 10GbE 40GbE and 56GbE Sending traffic from a node with a higher rate to a node with lower rate Enable Flow Control on both switch s ports and nodes On the server side run ethtool A interface rx on tx on On the switch side run the following command on the relevant interface send on force and receive on force No link with break out cable Misuse of the break out cable or m
77. ues and 1 for unknown values rpg max rate RPG MAX RATE LIST Set value of rpg max rate according to prior ity use spaces between values and 1 for unknown values rpg ai rate RPG AI RATE LIST Set value of rpg ai rate according to prior ity use spaces between values and 1 for unknown values rpg hai rate RPG HAI RATE LIST Set value of rpg hai rate according to prior ity use spaces between values and 1 for unknown values rpg gd RPG GD LIST Set value of rpg gd according to priority use spaces between values and 1 for unknown values 54 Mellanox Technologies Rev 2 4 rpg min dec fac RPG MIN DEC FAC LIST Set value of rpg min dec fac according to priority use spaces between values and 1 for unknown values rpg min rate RPG MIN RATE LIST Set value of rpg min rate according to prior ity use spaces between values and 1 for unknown values cndd state machine CNDD STATE MACHINE LIST Set value of cndd state machine according to priority use spaces between values and 1 for unknown values To get QCN current configuration sorted by priority mlnx qcn i eth2 g parameters gt To show OCN s statistics sorted by priority mlnx gcn i eth2 g statistics Example output when running mlnx qcn i eth2 g parameters priority 0 rpg enable 0 rppp max rps 1000 rpg time reset 1464 rpg byte reset 150000 rpg threshold 5 rpg max rate 40000
78. w Steering on page 33 32 Mellanox Technologies Rev 2 4 bit Operation Description b3 Enable DMFS only if the When set to 1 DMFS is enabled only if the HCA supports HCA supports more than more than 64 QPs attached to the same rule For example 64QPs per MCG entry attaching 64VFs to the same multicast address causes 64QPs to be attached to the same MCG If the HCA sup ports less than 64 QPs per MCG BO is used For example a value of 7 means forcing flow steering regardless of NC SI flow steering sup port disabling IPoIB flow steering support and enabling AO static DMFS steering The default value of log num mgm entry size is 10 Meaning Ethernet Flow Steering i e IPoIB DMFS is disabled by default is enabled by default if NC SI DMFS is supported and the HCA supports at least 64 QPs per MCG entry Otherwise L2 steering BO is used When using SR IOV flow steering is enabled if there is an adequate amount of space to store the flow steering table for the guest master gt To enable Flow Steering Step 1 Open the etc modprobe d mlnx conf file Step 2 Set the parameter log num mgm entry size to a non positive value by writing the option mlx4 core log num mgm entry size lt value gt Step 3 Restart the driver gt To disable Flow Steering Step 1 Open the etc modprobe d mlnx conf file Step 2 Remove the options mlx4 core log num mgm entry size value S
79. w Steering rules in the kernel requires support from both the ethtool in the user space and in kernel v2 6 28 MLXA Driver Support The mlx4 driver supports only a subset of the flow specification the ethtool API defines Asking for an unsupported flow specification will result with an invalid value failure The following are the flow specific parameters Table 6 Flow Specific Parameters ether tcp4 udp4 ip4 Mandatory dst src ip dst ip 34 Mellanox Technologies Rev 2 4 Table 6 Flow Specific Parameters ether tcp4 udp4 ip4 Optional vlan src ip dst ip src src ip dst ip vlan port dst port vlan e RFS RFS is an in kernel logic responsible for load balancing between CPUs by attaching flows to CPUs that are used by flow s owner applications This domain allows the RFS mechanism to use the flow steering infrastructure to support the RFS logic by implementing the ndo_rx_flow_steer which in turn calls the underlying flow steering mechanism with the RFS domain Enabling the RFS requires enabling the ntuple flag via the ethtool For example to enable ntuple for eth0 run ethtool K eth0 ntuple on RFS requires the kernel to be compiled with the coNFIG_RFS_ACCEL option This options is available in kernels 2 6 39 and above Furthermore RFS requires Device Managed Flow Steering support RFS cannot function if LRO is enabled LRO can be disabled via e
80. x site use the following command line mlxfwmanager online u d lt device gt Example mlxfwmanager online u d 0000 09 00 0 Querying Mellanox devices firmware Device 1 Device Type ConnectX3 Part Number MCX354A FCA A2 A4 Description ConnectX 3 VPI adapter card dual port QSFP FDR IB 56Gb s and 40GigE PCIe3 0 x8 8GT s RoHS R6 PSID MT 1020120019 PCI Device Name 0000 09 00 0 Portl GUID 0002c9000100d051 Port2 MAC 0002c9000002 Versions Current Available FW 2250 00 2 33 5000 Status Update required Found 1 device s requiring firmware update Please use u flag to perform the update 2 8 3 Updating Adapter Card Firmware Using a card specific binary firmware image file enter the following command gt mstflint d lt pci device gt i lt image name bin gt b For burning firmware using the MFT package please check the MFT User Manual under www mellanox com gt Products gt Software gt InfiniBand VPI Drivers gt Firmware Tools After burning a new firmware reboot the machine for changes to take effect ae 2 9 Ethernet Driver Usage and Configuration To assign an IP address to the interface gt ifconfig eth lt x gt ip a x is the OS assigned interface number To check driver and device information gt ethtool i eth x 20 Mellanox Technologies Rev 2 4 Example gt ethtool i eth2 driver mlx4_en version 2 1 8 Oct 06 2013 firmware version 2 30 31

Download Pdf Manuals

image

Related Search

Related Contents

ASUS F2A55-M/CSM T7489 User's Manual  3 Grundfunktionen  Motorola T5509KEM-PK10668 Two    LP840-LP850-860 User`s Guide.fm  

Copyright © All rights reserved.
Failed to retrieve file