Patch "[PATCH 074/135] i40e/i40evf: Fix RSS rx-flow-hash configuration" has been added to the 4.4-stable tree
Subsystems (3)
This is a note to let you know that I've just added the patch titled
[PATCH 074/135] i40e/i40evf: Fix RSS rx-flow-hash configuration
to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary
The filename of the patch is:
0074-i40e-i40evf-Fix-RSS-rx-flow-hash-configuration-throu.patch
and it can be found in the queue-4.4 subdirectory.
If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.
Quoted 1 line
From
7cad8862ae0c0cba7a848567ea229282a9c67b15Mon Sep 17 00:00:00 2001
From: Anjali Singhai Jain <[email protected]>
Date: Wed, 9 Dec 2015 15:50:24 -0800
Subject: [PATCH 074/135] i40e/i40evf: Fix RSS rx-flow-hash configuration
through ethtool
[ Upstream commit 6e35c04cf633e55648acb9ccabff42aa37bd4044 ]
This patch fixes the Hash PCTYPE enable for X722 since it supports a broader selection of PCTYPES for TCP and UDP.
This patch also fixes a bug in XL710, X710, X722 support for RSS, as of now we cannot reduce the (4)tuple for RSS for TCP/IPv4/IPV6 or UDP/IPv4/IPv6 packets since this requires a product feature change that comes in a later release.
A VF should never be allowed to change the tuples for RSS for any PCTYPE since that's a global setting for the device in case of i40e devices.
--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 14 ++----- drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 40 ++++----------------- 2 files changed, 12 insertions(+), 42 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +4 -10
@@ -2164,8 +2164,7 @@ static int i40e_set_rss_hash_opt(structcase TCP_V4_FLOW :switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) {case 0 : - hena &= ~BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP ); -break ; +return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP );break ;
@@ -2176,8 +2175,7 @@ static int i40e_set_rss_hash_opt(structcase TCP_V6_FLOW :switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) {case 0 : - hena &= ~BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP ); -break ; +return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP );break ;
@@ -2188,9 +2186,7 @@ static int i40e_set_rss_hash_opt(structcase UDP_V4_FLOW :switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) {case 0 : - hena &= ~(BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_UDP ) | -BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV4 )); -break ; +return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV4 ));
@@ -2202,9 +2198,7 @@ static int i40e_set_rss_hash_opt(structcase UDP_V6_FLOW :switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) {case 0 : - hena &= ~(BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_UDP ) | -BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV6 )); -break ; +return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV6 ));
drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c +8 -32
@@ -477,54 +477,30 @@ static int i40evf_set_rss_hash_opt(strucswitch (nfc->flow_type) {case TCP_V4_FLOW : -switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { -case 0 : - hena &= ~BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP ); -break ; -case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP ); -break ; -default : +else return -EINVAL ; - }break ;case TCP_V6_FLOW : -switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { -case 0 : - hena &= ~BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP ); -break ; -case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP ); -break ; -default : +else return -EINVAL ; - }break ;case UDP_V4_FLOW : -switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { -case 0 : - hena &= ~(BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_UDP ) | -BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV4 )); -break ; -case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV4 )); -break ; -default : + }else {return -EINVAL ; }break ;case UDP_V6_FLOW : -switch (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { -case 0 : - hena &= ~(BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_UDP ) | -BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV6 )); -break ; -case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV6 )); -break ; -default : + }else {return -EINVAL ; }break ;
Patches currently in stable-queue which might be from [email protected] are
queue-4.4/0010-i40e-Fix-Rx-hash-reported-to-the-stack-by-our-driver.patch queue-4.4/0074-i40e-i40evf-Fix-RSS-rx-flow-hash-configuration-throu.patch queue-4.4/0001-i40e-Workaround-fix-for-mss-256-issue.patch queue-4.4/0003-i40e-i40evf-Fix-RS-bit-update-in-Tx-path-and-disable.patch