i40e/i40evf updates
Subsystems (2)
cover i40e/i40evf updates
Anjali Singhai Jain adds new device IDs for X722, extends ethtool RSS hooks for X722, adds a fix for UDP/TCP RSS for X722, X722 changes to access nvm, and new write-back mode.
Catherine Sullivan adds 100Mb ethtool reporting.
Greg Bowers limits DCB FW version checks to X710/XL710 devices.
Jesse Brandeburg adds use of private workqueue.
Shannon Nelson adds new proxy-wol bits for X722_SUPPORT, implements 'AQ add Run PHY Activity struct', 'AQ Geneve cloud tunnel type', and 'AQ add external power class to get link status'.
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 25 +++++++- drivers/net/ethernet/intel/i40e/i40e_common.c | 2 + drivers/net/ethernet/intel/i40e/i40e_dcb.c | 12 ++-- drivers/net/ethernet/intel/i40e/i40e_devids.h | 2 + drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 22 +++++++ drivers/net/ethernet/intel/i40e/i40e_main.c | 73 +++++++++++++++++++++- drivers/net/ethernet/intel/i40e/i40e_nvm.c | 49 +++++++++------ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 12 ++++ .../net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 25 +++++++- drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 16 +++++ drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 29 +++++++-- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 23 +++++-- 12 files changed, 249 insertions(+), 41 deletions(-)
Signature · 1 line
2.1.0
PATCH 1/12 i40e: add new device IDs for X722
From: Anjali Singhai Jain <[email protected]>
Add the KX and QSFP device IDs for X722.
--- drivers/net/ethernet/intel/i40e/i40e_common.c | 2 ++ drivers/net/ethernet/intel/i40e/i40e_devids.h | 2 ++ drivers/net/ethernet/intel/i40e/i40e_main.c | 2 ++ 3 files changed, 6 insertions(+)
drivers/net/ethernet/intel/i40e/i40e_common.c +2 -0
@@ -55,6 +55,8 @@ static i40e_status i40e_set_mac_type(struct i40e_hw *hw)case I40E_DEV_ID_20G_KR2_A : hw->mac.type =I40E_MAC_XL710 ;break ; +case I40E_DEV_ID_KX_X722 : +case I40E_DEV_ID_QSFP_X722 :case I40E_DEV_ID_SFP_X722 :case I40E_DEV_ID_1G_BASE_T_X722 :case I40E_DEV_ID_10G_BASE_T_X722 :
drivers/net/ethernet/intel/i40e/i40e_devids.h +2 -0
@@ -41,6 +41,8 @@#define I40E_DEV_ID_10G_BASE_T4 0x1589#define I40E_DEV_ID_VF 0x154C#define I40E_DEV_ID_VF_HV 0x1571 +#define I40E_DEV_ID_KX_X722 0x37CE +#define I40E_DEV_ID_QSFP_X722 0x37CF#define I40E_DEV_ID_SFP_X722 0x37D0#define I40E_DEV_ID_1G_BASE_T_X722 0x37D1#define I40E_DEV_ID_10G_BASE_T_X722 0x37D2
drivers/net/ethernet/intel/i40e/i40e_main.c +2 -0
@@ -87,6 +87,8 @@ static const struct pci_device_id i40e_pci_tbl[] = { {PCI_VDEVICE(INTEL, I40E_DEV_ID_10G_BASE_T), 0}, {PCI_VDEVICE(INTEL, I40E_DEV_ID_10G_BASE_T4), 0}, {PCI_VDEVICE(INTEL, I40E_DEV_ID_20G_KR2), 0}, + {PCI_VDEVICE(INTEL, I40E_DEV_ID_KX_X722), 0}, + {PCI_VDEVICE(INTEL, I40E_DEV_ID_QSFP_X722), 0}, {PCI_VDEVICE(INTEL, I40E_DEV_ID_SFP_X722), 0}, {PCI_VDEVICE(INTEL, I40E_DEV_ID_1G_BASE_T_X722), 0}, {PCI_VDEVICE(INTEL, I40E_DEV_ID_10G_BASE_T_X722), 0},
Signature · 1 line
2.1.0
Bowers
PATCH 1/12 i40e: add new device IDs for X722
Quoted 10 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 01/12] i40e: add new device IDs for X722From: Anjali Singhai Jain <[email protected]>
Quoted 8 lines
Add the KX and QSFP device IDs for X722.
Signed-off-by Anjali Singhai Jain <[email protected]>--- drivers/net/ethernet/intel/i40e/i40e_common.c | 2 ++ drivers/net/ethernet/intel/i40e/i40e_devids.h | 2 ++ drivers/net/ethernet/intel/i40e/i40e_main.c | 2 ++ 3 files changed, 6 insertions(+)
Patch code changes correctly applied
PATCH 2/12 i40e: Extend ethtool RSS hooks for X722
In reply to Deepthi KavalurFrom: Anjali Singhai Jain <[email protected]>
This patch adds another way to access the RSS keys and lut using the AQ for X722 devices.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 53 ++++++++++++++++++++++++++++- 1 file changed, 52 insertions(+), 1 deletion(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +52 -1
@@ -7933,6 +7933,52 @@ static int i40e_vsi_config_rss(struct i40e_vsi *vsi) }/** +* i40e_get_rss_aq - Get RSS keys and lut by using AQ commands +* @vsi: Pointer to vsi structure +* @seed: Buffter to store the hash keys +* @lut: Buffer to store the lookup table entries +* @lut_size: Size of buffer to store the lookup table entries +* +* Return 0 on success, negative on failure +*/ +static int i40e_get_rss_aq (struct i40e_vsi *vsi,const u8 *seed, +u8 *lut,u16 lut_size) +{ +struct i40e_pf *pf = vsi->back; +struct i40e_hw *hw = &pf->hw; +int ret =0 ; + +if (seed) { + ret =i40e_aq_get_rss_key (hw, vsi->id, + (struct i40e_aqc_get_set_rss_key_data *)seed); +if (ret) { +dev_info (&pf->pdev->dev, +"Cannot get RSS key, err %s aq_err %s\n" , +i40e_stat_str (&pf->hw, ret), +i40e_aq_str (&pf->hw, + pf->hw.aq.asq_last_status)); +return ret; + } + } + +if (lut) { +bool pf_lut = vsi->type ==I40E_VSI_MAIN ? true : false; + + ret =i40e_aq_get_rss_lut (hw, vsi->id, pf_lut, lut, lut_size); +if (ret) { +dev_info (&pf->pdev->dev, +"Cannot get RSS lut, err %s aq_err %s\n" , +i40e_stat_str (&pf->hw, ret), +i40e_aq_str (&pf->hw, + pf->hw.aq.asq_last_status)); +return ret; + } + } + +return ret; +} + +/** * i40e_config_rss_reg - Configure RSS keys and lut by writing registers * @vsi: Pointer to vsi structure * @seed: RSS hash seed
@@ -8034,7 +8080,12 @@ int i40e_config_rss(struct i40e_vsi *vsi, u8 *seed, u8 *lut, u16 lut_size)*/ int i40e_get_rss (struct i40e_vsi *vsi,u8 *seed,u8 *lut,u16 lut_size) { -return i40e_get_rss_reg (vsi, seed, lut, lut_size); +struct i40e_pf *pf = vsi->back; + +if (pf->flags &I40E_FLAG_RSS_AQ_CAPABLE ) +return i40e_get_rss_aq (vsi, seed, lut, lut_size); +else +return i40e_get_rss_reg (vsi, seed, lut, lut_size); }/**
Signature · 1 line
2.1.0
Bowers
PATCH 2/12 i40e: Extend ethtool RSS hooks for X722
Quoted 10 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 02/12] i40e: Extend ethtool RSS hooks for X722From: Anjali Singhai Jain <[email protected]>
Quoted 8 lines
This patch adds another way to access the RSS keys and lut using the AQ for X722 devices.
Signed-off-by Anjali Singhai Jain <[email protected]>--- drivers/net/ethernet/intel/i40e/i40e_main.c | 53 ++++++++++++++++++++++++++++- 1 file changed, 52 insertions(+), 1 deletion(-)
Patch code changes correctly applied
PATCH 3/12 i40e/i40evf: Fix for UDP/TCP RSS for X722
In reply to Deepthi KavalurFrom: Anjali Singhai Jain <[email protected]>
The PCTYPES for the X710 and X722 families are different. This patch makes adjustments for that.
--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 18 ++++++++++++++ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 6 +++++ drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 29 +++++++++++++++++++--- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 8 +++--- 4 files changed, 54 insertions(+), 7 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +18 -0
@@ -2169,6 +2169,10 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)case 0 :return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (pf->flags &I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP_SYN_NO_ACK ); + hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP );break ;default :
@@ -2180,6 +2184,10 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)case 0 :return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (pf->flags &I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP_SYN_NO_ACK ); + hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP );break ;default :
@@ -2191,6 +2199,11 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)case 0 :return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (pf->flags &I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_UNICAST_IPV4_UDP ) | +BIT_ULL (I40E_FILTER_PCTYPE_NONF_MULTICAST_IPV4_UDP ); + hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV4 ));break ;
@@ -2203,6 +2216,11 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)case 0 :return -EINVAL ;case (RXH_L4_B_0_1 |RXH_L4_B_2_3 ): +if (pf->flags &I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_UNICAST_IPV6_UDP ) | +BIT_ULL (I40E_FILTER_PCTYPE_NONF_MULTICAST_IPV6_UDP ); + hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV6 ));break ;
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c +6 -0
@@ -1213,6 +1213,12 @@ static int i40e_vc_get_vf_resources_msg(struct i40e_vf *vf, u8 *msg) vfres->vf_offload_flags |=I40E_VIRTCHNL_VF_OFFLOAD_RSS_REG ; } +if (pf->flags &I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE ) { +if (vf->driver_caps &I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ) + vfres->vf_offload_flags |= +I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ; + } +if (vf->driver_caps &I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING ) vfres->vf_offload_flags |=I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING ;
drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c +25 -4
@@ -459,6 +459,7 @@ static int i40evf_set_rss_hash_opt(struct i40evf_adapter *adapter, struct ethtool_rxnfc *nfc) {struct i40e_hw *hw = &adapter->hw; +u32 flags = adapter->vf_res->vf_offload_flags;u64 hena = (u64 )rd32 (hw,I40E_VFQF_HENA (0 )) | ((u64 )rd32 (hw,I40E_VFQF_HENA (1 )) <<32 );
@@ -477,19 +478,34 @@ static int i40evf_set_rss_hash_opt(struct i40evf_adapter *adapter,switch (nfc->flow_type) {case TCP_V4_FLOW : -if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) +if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { +if (flags &I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP_SYN_NO_ACK ); + hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_TCP ); -else + }else {return -EINVAL ; + }break ;case TCP_V6_FLOW : -if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) +if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { +if (flags &I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP_SYN_NO_ACK ); + hena |=BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_TCP ); -else + }else {return -EINVAL ; + }break ;case UDP_V4_FLOW :if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { +if (flags &I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_UNICAST_IPV4_UDP ) | +BIT_ULL (I40E_FILTER_PCTYPE_NONF_MULTICAST_IPV4_UDP ); + hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV4_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV4 )); }else {
@@ -498,6 +514,11 @@ static int i40evf_set_rss_hash_opt(struct i40evf_adapter *adapter,break ;case UDP_V6_FLOW :if (nfc->data & (RXH_L4_B_0_1 |RXH_L4_B_2_3 )) { +if (flags &I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ) + hena |= +BIT_ULL (I40E_FILTER_PCTYPE_NONF_UNICAST_IPV6_UDP ) | +BIT_ULL (I40E_FILTER_PCTYPE_NONF_MULTICAST_IPV6_UDP ); + hena |= (BIT_ULL (I40E_FILTER_PCTYPE_NONF_IPV6_UDP ) |BIT_ULL (I40E_FILTER_PCTYPE_FRAG_IPV6 )); }else {
drivers/net/ethernet/intel/i40evf/i40evf_main.c +5 -3
@@ -1456,7 +1456,11 @@ static int i40evf_init_rss(struct i40evf_adapter *adapter)int ret;/* Enable PCTYPES for RSS, TCP/UDP with IPv4/IPv6 */ - hena =I40E_DEFAULT_RSS_HENA ; +if (adapter->vf_res->vf_offload_flags & +I40E_VIRTCHNL_VF_OFFLOAD_RSS_PCTYPE_V2 ) + hena =I40E_DEFAULT_RSS_HENA_EXPANDED ; +else + hena =I40E_DEFAULT_RSS_HENA ;wr32 (hw,I40E_VFQF_HENA (0 ), (u32 )hena);wr32 (hw,I40E_VFQF_HENA (1 ), (u32)(hena >>32 ));
@@ -2507,8 +2511,6 @@ static void i40evf_init_task(struct work_struct *work)if (adapter->vf_res->vf_offload_flags &I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR ) adapter->flags |=I40EVF_FLAG_WB_ON_ITR_CAPABLE ; -if (!RSS_AQ (adapter)) -i40evf_init_rss (adapter); err =i40evf_request_misc_irq (adapter);if (err) goto err_sw_init;
Signature · 1 line
2.1.0
Bowers
PATCH 3/12 i40e/i40evf: Fix for UDP/TCP RSS for X722
Quoted 13 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 03/12] i40e/i40evf: Fix for UDP/TCP RSS for X722From: Anjali Singhai Jain <[email protected]>
The PCTYPES for the X710 and X722 families are different. This patch makes adjustments for that.
Quoted 8 lines
Signed-off-by Anjali Singhai Jain <[email protected]>--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 18 ++++++++++++++ drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 6 +++++ drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c | 29 +++++++++++++++++++--- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 8 +++--- 4 files changed, 54 insertions(+), 7 deletions(-)
Patch code changes correctly applied, RSS works on X722 with TCP and UDP traffic
PATCH 4/12 i40e: X722 changes to access nvm
In reply to Deepthi KavalurFrom: Anjali Singhai Jain <[email protected]>
X722 does not have access to SRCTL registers, it has to do this through the AQ.
--- drivers/net/ethernet/intel/i40e/i40e_nvm.c | 49 ++++++++++++++++++------------ 1 file changed, 30 insertions(+), 19 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_nvm.c +30 -19
@@ -212,24 +212,6 @@ read_nvm_exit: }/** -* __i40e_read_nvm_word - Reads nvm word, assumes caller does the locking -* @hw: pointer to the HW structure -* @offset: offset of the Shadow RAM word to read (0x000000 - 0x001FFF) -* @data: word read from the Shadow RAM -* -* Reads one 16 bit word from the Shadow RAM using the GLNVM_SRCTL register. -**/ -static i40e_status __i40e_read_nvm_word (struct i40e_hw *hw, -u16 offset, -u16 *data) -{ -i40e_status ret_code =0 ; - - ret_code =i40e_read_nvm_word_srctl (hw, offset, data); -return ret_code; -} - -/** * i40e_read_nvm_aq - Read Shadow RAM. * @hw: pointer to the HW structure. * @module_pointer: module pointer location in words from the NVM beginning
@@ -298,6 +280,32 @@ static i40e_status i40e_read_nvm_word_aq(struct i40e_hw *hw, u16 offset, }/** +* __i40e_read_nvm_word - Reads nvm word, assumes caller does the locking +* @hw: pointer to the HW structure +* @offset: offset of the Shadow RAM word to read (0x000000 - 0x001FFF) +* @data: word read from the Shadow RAM +* +* Reads one 16 bit word from the Shadow RAM using the GLNVM_SRCTL register. +**/ +static i40e_status __i40e_read_nvm_word (struct i40e_hw *hw, +u16 offset, +u16 *data) +{ +i40e_status ret_code =0 ; + +if (hw->flags &I40E_HW_FLAG_AQ_SRCTL_ACCESS_ENABLE ) { + ret_code =i40e_acquire_nvm (hw,I40E_RESOURCE_READ ); +if (!ret_code) { + ret_code =i40e_read_nvm_word_aq (hw, offset, data); +i40e_release_nvm (hw); + } + }else { + ret_code =i40e_read_nvm_word_srctl (hw, offset, data); + } +return ret_code; +} + +/** * i40e_read_nvm_word - Reads nvm word and acquire lock if necessary * @hw: pointer to the HW structure * @offset: offset of the Shadow RAM word to read (0x000000 - 0x001FFF)
@@ -427,7 +435,10 @@ static i40e_status __i40e_read_nvm_buffer(struct i40e_hw *hw, {i40e_status ret_code =0 ; - ret_code =i40e_read_nvm_buffer_srctl (hw, offset, words, data); +if (hw->flags &I40E_HW_FLAG_AQ_SRCTL_ACCESS_ENABLE ) + ret_code =i40e_read_nvm_buffer_aq (hw, offset, words, data); +else + ret_code =i40e_read_nvm_buffer_srctl (hw, offset, words, data);return ret_code; }
Signature · 1 line
2.1.0
Kavalur
PATCH 4/12 i40e: X722 changes to access nvm
This patch should be dropped as it may introduce a bug. Another patch containing the fix is already submitted with subject:
"[v2,next,S23,9/13] i40e: Make some changes in the nvm read code"
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: [email protected]
Subject: [Intel-wired-lan] [next PATCH S24 04/12] i40e: X722 changes to access nvm
From: Anjali Singhai Jain <[email protected]>
X722 does not have access to SRCTL registers, it has to do this through the AQ.
Sullivan
PATCH 4/12 i40e: X722 changes to access nvm
Quoted 7 lines
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 04/12] i40e: X722 changes to access nvm
Quoted 7 lines
From: Anjali Singhai Jain <[email protected]>
X722 does not have access to SRCTL registers, it has to do this through the AQ.
_______________________________________________
Intel-wired-lan mailing list
Intel-wired-lan at lists.osuosl.org
http://lists.osuosl.org/mailman/listinfo/intel-wired-lan
[Sullivan, Catherine]
Jeff, please drop this patch, it introduces a bug.
Bowers
PATCH 4/12 i40e: X722 changes to access nvm
In reply to Deepthi KavalurQuoted 10 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 04/12] i40e: X722 changes to access nvmFrom: Anjali Singhai Jain <[email protected]>
Quoted 8 lines
X722 does not have access to SRCTL registers, it has to do this through the AQ.
Signed-off-by Anjali Singhai Jain <[email protected]>--- drivers/net/ethernet/intel/i40e/i40e_nvm.c | 49 ++++++++++++++++++---- -------- 1 file changed, 30 insertions(+), 19 deletions(-)
Patch code changes correctly applied, nvm accessible
PATCH 5/12 i40evf: add new write-back mode
In reply to Deepthi KavalurFrom: Anjali Singhai Jain <[email protected]>
Add write-back on interrupt throttle rate timer expiration support for the i40evf driver, when running on X722 devices.
--- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 6 ++++++ drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 16 ++++++++++++++++ drivers/net/ethernet/intel/i40evf/i40evf_main.c | 5 +++++ 3 files changed, 27 insertions(+)
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c +6 -0
@@ -1222,6 +1222,12 @@ static int i40e_vc_get_vf_resources_msg(struct i40e_vf *vf, u8 *msg)if (vf->driver_caps &I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING ) vfres->vf_offload_flags |=I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING ; +if (pf->flags &I40E_FLAG_WB_ON_ITR_CAPABLE ) { +if (vf->driver_caps &I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR ) + vfres->vf_offload_flags |= +I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR ; + } + vfres->num_vsis = num_vsis; vfres->num_queue_pairs = vf->num_queue_pairs; vfres->max_vectors = pf->hw.func_caps.num_msix_vectors_vf;
drivers/net/ethernet/intel/i40evf/i40e_txrx.c +16 -0
@@ -252,6 +252,22 @@ static bool i40e_clean_tx_irq(struct i40e_ring *tx_ring, int budget) tx_ring->q_vector->tx.total_bytes += total_bytes; tx_ring->q_vector->tx.total_packets += total_packets; +if (tx_ring->flags &I40E_TXR_FLAGS_WB_ON_ITR ) { +unsigned int j =0 ; +/* check to see if there are < 4 descriptors +* waiting to be written back, then kick the hardware to force +* them to be written back in case we stay in NAPI. +* In this mode on X722 we do not enable Interrupt. +*/ + j =i40evf_get_tx_pending (tx_ring); + +if (budget && + ((j / (WB_STRIDE +1 )) ==0 ) && (j >0 ) && + !test_bit (__I40E_DOWN, &tx_ring->vsi->state) && + (I40E_DESC_UNUSED (tx_ring) != tx_ring->count)) + tx_ring->arm_wb = true; + } +netdev_tx_completed_queue (netdev_get_tx_queue (tx_ring->netdev, tx_ring->queue_index), total_packets, total_bytes);
drivers/net/ethernet/intel/i40evf/i40evf_main.c +5 -0
@@ -2511,6 +2511,11 @@ static void i40evf_init_task(struct work_struct *work)if (adapter->vf_res->vf_offload_flags &I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR ) adapter->flags |=I40EVF_FLAG_WB_ON_ITR_CAPABLE ; + +if (adapter->vf_res->vf_offload_flags & +I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR ) + adapter->flags |=I40EVF_FLAG_WB_ON_ITR_CAPABLE ; + err =i40evf_request_misc_irq (adapter);if (err) goto err_sw_init;
Signature · 1 line
2.1.0
Bowers
PATCH 5/12 i40evf: add new write-back mode
Quoted 13 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 05/12] i40evf: add new write-back modeFrom: Anjali Singhai Jain <[email protected]>
Add write-back on interrupt throttle rate timer expiration support for the i40evf driver, when running on X722 devices.
Quoted 6 lines
Signed-off-by Anjali Singhai Jain <[email protected]>--- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 6 ++++++ drivers/net/ethernet/intel/i40evf/i40e_txrx.c | 16 ++++++++++++++++ drivers/net/ethernet/intel/i40evf/i40evf_main.c | 5 +++++ 3 files changed, 27 insertions(+)
Patch code changes correctly applied, no tx_timeout/tx hangs noted with stress traffic
PATCH 6/12 i40e/i40evf: Use private workqueue
In reply to Deepthi KavalurFrom: Jesse Brandeburg <[email protected]>
As done per ixgbe, use a private workqueue to avoid blocking the system workqueue. This avoids some strange side effects when some other entity is depending on the system work queue.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 15 ++++++++++++++- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 10 +++++++++- 2 files changed, 23 insertions(+), 2 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +14 -1
@@ -109,6 +109,8 @@ MODULE_DESCRIPTION("Intel(R) Ethernet Connection XL710 Network Driver");MODULE_LICENSE ("GPL" );MODULE_VERSION (DRV_VERSION ); +static struct workqueue_struct *i40e_wq; +/** * i40e_allocate_dma_mem_d - OS specific memory alloc for shared code * @hw: pointer to the HW structure
@@ -294,7 +296,7 @@ static void i40e_service_event_schedule(struct i40e_pf *pf)if (!test_bit (__I40E_DOWN, &pf->state) && !test_bit (__I40E_RESET_RECOVERY_PENDING, &pf->state) && !test_and_set_bit (__I40E_SERVICE_SCHED, &pf->state)) -schedule_work (&pf->service_task); +queue_work (i40e_wq, &pf->service_task); }/**
@@ -11362,6 +11364,16 @@ static int __init i40e_init_module(void) i40e_driver_string, i40e_driver_version_str);pr_info ("%s: %s\n" , i40e_driver_name, i40e_copyright); +/* we will see if single thread per module is enough for now, +* it can't be any worse than using the system workqueue which +* was already single threaded +*/ + i40e_wq =create_singlethread_workqueue (i40e_driver_name); +if (!i40e_wq) { +pr_err ("%s: Failed to create workqueue\n" , i40e_driver_name); +return -ENOMEM ; + } +i40e_dbg_init ();return pci_register_driver (&i40e_driver); }
@@ -11376,6 +11388,7 @@ module_init(i40e_init_module); static void __exit i40e_exit_module(void) {pci_unregister_driver (&i40e_driver); +destroy_workqueue (i40e_wq);i40e_dbg_exit (); }module_exit (i40e_exit_module);
drivers/net/ethernet/intel/i40evf/i40evf_main.c +9 -1
@@ -69,6 +69,8 @@ MODULE_DESCRIPTION("Intel(R) XL710 X710 Virtual Function Network Driver");MODULE_LICENSE ("GPL" );MODULE_VERSION (DRV_VERSION ); +static struct workqueue_struct *i40evf_wq; +/** * i40evf_allocate_dma_mem_d - OS specific memory alloc for shared code * @hw: pointer to the HW structure
@@ -182,7 +184,7 @@ static void i40evf_tx_timeout(struct net_device *netdev)if (!(adapter->flags & (I40EVF_FLAG_RESET_PENDING |I40EVF_FLAG_RESET_NEEDED ))) { adapter->flags |=I40EVF_FLAG_RESET_NEEDED ; -schedule_work (&adapter->reset_task); +queue_work (i40evf_wq, &adapter->reset_task); } }
@@ -2885,6 +2887,11 @@ static int __init i40evf_init_module(void)pr_info ("%s\n" , i40evf_copyright); + i40evf_wq =create_singlethread_workqueue (i40evf_driver_name); +if (!i40evf_wq) { +pr_err ("%s: Failed to create workqueue\n" , i40evf_driver_name); +return -ENOMEM ; + } ret =pci_register_driver (&i40evf_driver);return ret; }
@@ -2900,6 +2907,7 @@ module_init(i40evf_init_module); static void __exit i40evf_exit_module(void) {pci_unregister_driver (&i40evf_driver); +destroy_workqueue (i40evf_wq); }module_exit (i40evf_exit_module);
Signature · 1 line
2.1.0
Bowers
PATCH 6/12 i40e/i40evf: Use private workqueue
Quoted 14 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 06/12] i40e/i40evf: Use private workqueueFrom: Jesse Brandeburg <[email protected]>
As done per ixgbe, use a private workqueue to avoid blocking the system workqueue. This avoids some strange side effects when some other entity is depending on the system work queue.
Quoted 6 lines
Signed-off-by Jesse Brandeburg <[email protected]>Change-ID Ic8ba08f5b03696cf638b21afd25fbae7738d55ee--- drivers/net/ethernet/intel/i40e/i40e_main.c | 15 ++++++++++++++- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 10 +++++++++- 2 files changed, 23 insertions(+), 2 deletions(-)
Patch code changes correctly applied
PATCH 7/12 i40e: add new proxy-wol bit for X722
In reply to Deepthi KavalurFrom: Shannon Nelson <[email protected]>
Add the new proxy-wake-on-lan capability bit available with the new X722 device.
---
Testing-Hints:
Apply and compile cleanly.
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 1 + drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 1 + 2 files changed, 2 insertions(+)
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h +1 -0
@@ -402,6 +402,7 @@ struct i40e_aqc_list_capabilities_element_resp {#define I40E_AQ_CAP_ID_OS2BMC_CAP 0x0004#define I40E_AQ_CAP_ID_FUNCTIONS_VALID 0x0005#define I40E_AQ_CAP_ID_ALTERNATE_RAM 0x0006 +#define I40E_AQ_CAP_ID_WOL_AND_PROXY 0x0008#define I40E_AQ_CAP_ID_SRIOV 0x0012#define I40E_AQ_CAP_ID_VF 0x0013#define I40E_AQ_CAP_ID_VMDQ 0x0014
drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h +1 -0
@@ -399,6 +399,7 @@ struct i40e_aqc_list_capabilities_element_resp {#define I40E_AQ_CAP_ID_OS2BMC_CAP 0x0004#define I40E_AQ_CAP_ID_FUNCTIONS_VALID 0x0005#define I40E_AQ_CAP_ID_ALTERNATE_RAM 0x0006 +#define I40E_AQ_CAP_ID_WOL_AND_PROXY 0x0008#define I40E_AQ_CAP_ID_SRIOV 0x0012#define I40E_AQ_CAP_ID_VF 0x0013#define I40E_AQ_CAP_ID_VMDQ 0x0014
Signature · 1 line
2.1.0
Bowers
PATCH 7/12 i40e: add new proxy-wol bit for X722
Quoted 16 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 07/12] i40e: add new proxy-wol bit for X722From: Shannon Nelson <[email protected]>
Add the new proxy-wake-on-lan capability bit available with the new X722 device.
Signed-off-by Shannon Nelson <[email protected]>Acked-by Jesse Brandeburg <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
Quoted 7 lines
---
Testing-Hints:
Apply and compile cleanly.drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 1 + drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 1 + 2 files changed, 2 insertions(+)
Patch code changes correctly applied
PATCH 8/12 i40e: Limit DCB FW version checks to X710/XL710 devices
In reply to Deepthi KavalurFrom: Greg Bowers <[email protected]>
X710/XL710 devices require FW version checks to properly handle DCB configurations from the FW. Newer devices do not, so limit these checks to X710/XL710.
---
Testing-Hints:
Test that X710/XL710 and X722 devices support CEE and IEEE DCBX.
drivers/net/ethernet/intel/i40e/i40e_dcb.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_dcb.c +7 -5
@@ -814,13 +814,15 @@ i40e_status i40e_get_dcb_config(struct i40e_hw *hw)struct i40e_aqc_get_cee_dcb_cfg_resp cee_cfg;struct i40e_aqc_get_cee_dcb_cfg_v1_resp cee_v1_cfg; -/* If Firmware version < v4.33 IEEE only */ -if (((hw->aq.fw_maj_ver ==4 ) && (hw->aq.fw_min_ver <33 )) || - (hw->aq.fw_maj_ver <4 )) +/* If Firmware version < v4.33 on X710/XL710, IEEE only */ +if ((hw->mac.type ==I40E_MAC_XL710 ) && + (((hw->aq.fw_maj_ver ==4 ) && (hw->aq.fw_min_ver <33 )) || + (hw->aq.fw_maj_ver <4 )))return i40e_get_ieee_dcb_config (hw); -/* If Firmware version == v4.33 use old CEE struct */ -if ((hw->aq.fw_maj_ver ==4 ) && (hw->aq.fw_min_ver ==33 )) { +/* If Firmware version == v4.33 on X710/XL710, use old CEE struct */ +if ((hw->mac.type ==I40E_MAC_XL710 ) && + ((hw->aq.fw_maj_ver ==4 ) && (hw->aq.fw_min_ver ==33 ))) { ret =i40e_aq_get_cee_dcb_config (hw, &cee_v1_cfg,sizeof (cee_v1_cfg),NULL );if (!ret) {
Signature · 1 line
2.1.0
Bowers
PATCH 8/12 i40e: Limit DCB FW version checks to X710/XL710 devices
Quoted 18 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Cc: Bowers, Gregory J <[email protected]>
Subject: [Intel-wired-lan] [next PATCH S24 08/12] i40e: Limit DCB FW version checks to X710/XL710 devicesFrom: Greg Bowers <[email protected]>
X710/XL710 devices require FW version checks to properly handle DCB configurations from the FW. Newer devices do not, so limit these checks to X710/XL710.
Signed-off-by Greg Bowers <[email protected]>Acked-by Shannon Nelson <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
Quoted 6 lines
---
Testing-Hints:
Test that X710/XL710 and X722 devices support CEE and IEEE DCBX.drivers/net/ethernet/intel/i40e/i40e_dcb.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-)
FCoE/DCB - Patch code changes correctly applied, does not break base driver
PATCH 9/12 i40e: AQ Add Run PHY Activity struct
In reply to Deepthi KavalurFrom: Shannon Nelson <[email protected]>
Add the AQ opcode and struct definitions for the Run PHY Activity command
---
Testing-Hints:
Apply and compile cleanly.
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 13 +++++++++++++ drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 13 +++++++++++++ 2 files changed, 26 insertions(+)
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h +13 -0
@@ -220,6 +220,7 @@ enum i40e_admin_queue_opc { i40e_aqc_opc_get_phy_wol_caps =0x0621 , i40e_aqc_opc_set_phy_debug =0x0622 , i40e_aqc_opc_upload_ext_phy_fm =0x0625 , + i40e_aqc_opc_run_phy_activity =0x0626 ,/* NVM commands */ i40e_aqc_opc_nvm_read = 0x0701,
@@ -1825,6 +1826,18 @@ enum i40e_aq_phy_reg_type { I40E_AQC_PHY_REG_EXERNAL_MODULE = 0x3 }; +/* Run PHY Activity (0x0626) */ +struct i40e_aqc_run_phy_activity { +__le16 activity_id; +u8 flags; +u8 reserved1; +__le32 control; +__le32 data; +u8 reserved2[4 ]; +}; + +I40E_CHECK_CMD_LENGTH (i40e_aqc_run_phy_activity); +/* NVM Read command (indirect 0x0701) * NVM Erase commands (direct 0x0702) * NVM Update commands (indirect 0x0703)
drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h +13 -0
@@ -220,6 +220,7 @@ enum i40e_admin_queue_opc { i40e_aqc_opc_get_phy_wol_caps =0x0621 , i40e_aqc_opc_set_phy_debug =0x0622 , i40e_aqc_opc_upload_ext_phy_fm =0x0625 , + i40e_aqc_opc_run_phy_activity =0x0626 ,/* NVM commands */ i40e_aqc_opc_nvm_read = 0x0701,
@@ -1822,6 +1823,18 @@ enum i40e_aq_phy_reg_type { I40E_AQC_PHY_REG_EXERNAL_MODULE = 0x3 }; +/* Run PHY Activity (0x0626) */ +struct i40e_aqc_run_phy_activity { +__le16 activity_id; +u8 flags; +u8 reserved1; +__le32 control; +__le32 data; +u8 reserved2[4 ]; +}; + +I40E_CHECK_CMD_LENGTH (i40e_aqc_run_phy_activity); +/* NVM Read command (indirect 0x0701) * NVM Erase commands (direct 0x0702) * NVM Update commands (indirect 0x0703)
Signature · 1 line
2.1.0
Bowers
PATCH 9/12 i40e: AQ Add Run PHY Activity struct
Quoted 15 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 09/12] i40e: AQ Add Run PHY Activity structFrom: Shannon Nelson <[email protected]>
Add the AQ opcode and struct definitions for the Run PHY Activity command
Signed-off-by Shannon Nelson <[email protected]>Acked-by Kevin Scott <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
Quoted 8 lines
---
Testing-Hints:
Apply and compile cleanly.drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 13 +++++++++++++ drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 13 +++++++++++++ 2 files changed, 26 insertions(+)
Patch code changes correctly applied
PATCH 10/12 i40e: AQ Geneve cloud tunnel type
In reply to Deepthi KavalurFrom: Shannon Nelson <[email protected]>
Fix the name of the new cloud tunnel type from the place-holder NGE name to the official Geneve. Also fix the spelling of the VXLAN type.
---
Testing-Hints:
Apply and compile cleanly.
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 4 ++-- drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h +2 -2
@@ -1260,9 +1260,9 @@ struct i40e_aqc_add_remove_cloud_filters_element_data {#define I40E_AQC_ADD_CLOUD_TNL_TYPE_SHIFT 9#define I40E_AQC_ADD_CLOUD_TNL_TYPE_MASK 0x1E00 -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_XVLAN 0 +#define I40E_AQC_ADD_CLOUD_TNL_TYPE_VXLAN 0#define I40E_AQC_ADD_CLOUD_TNL_TYPE_NVGRE_OMAC 1 -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_NGE 2 +#define I40E_AQC_ADD_CLOUD_TNL_TYPE_GENEVE 2#define I40E_AQC_ADD_CLOUD_TNL_TYPE_IP 3__le32 tenant_id;
drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h +2 -2
@@ -1257,9 +1257,9 @@ struct i40e_aqc_add_remove_cloud_filters_element_data {#define I40E_AQC_ADD_CLOUD_TNL_TYPE_SHIFT 9#define I40E_AQC_ADD_CLOUD_TNL_TYPE_MASK 0x1E00 -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_XVLAN 0 +#define I40E_AQC_ADD_CLOUD_TNL_TYPE_VXLAN 0#define I40E_AQC_ADD_CLOUD_TNL_TYPE_NVGRE_OMAC 1 -#define I40E_AQC_ADD_CLOUD_TNL_TYPE_NGE 2 +#define I40E_AQC_ADD_CLOUD_TNL_TYPE_GENEVE 2#define I40E_AQC_ADD_CLOUD_TNL_TYPE_IP 3__le32 tenant_id;
Signature · 1 line
2.1.0
Bowers
PATCH 10/12 i40e: AQ Geneve cloud tunnel type
Quoted 16 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 10/12] i40e: AQ Geneve cloud tunnel typeFrom: Shannon Nelson <[email protected]>
Fix the name of the new cloud tunnel type from the place-holder NGE name to the official Geneve. Also fix the spelling of the VXLAN type.
Signed-off-by Shannon Nelson <[email protected]>Acked-by Kevin Scott <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
Quoted 7 lines
---
Testing-Hints:
Apply and compile cleanly.drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 4 ++-- drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-)
Patch code changes correctly applied
PATCH 11/12 i40e: AQ Add external power class to get link status
In reply to Deepthi KavalurFrom: Shannon Nelson <[email protected]>
Add the new External Device Power Ability field to the get_link_status data structure, using space from the reserved field at the end of the struct.
---
Testing-Hints:
Apply and compile cleanly.
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 7 ++++++- drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h +6 -1
@@ -1758,7 +1758,12 @@ struct i40e_aqc_get_link_status {u8 config;#define I40E_AQ_CONFIG_CRC_ENA 0x04#define I40E_AQ_CONFIG_PACING_MASK 0x78 -u8 reserved[5 ]; +u8 external_power_ability; +#define I40E_AQ_LINK_POWER_CLASS_1 0x00 +#define I40E_AQ_LINK_POWER_CLASS_2 0x01 +#define I40E_AQ_LINK_POWER_CLASS_3 0x02 +#define I40E_AQ_LINK_POWER_CLASS_4 0x03 +u8 reserved[4 ]; };I40E_CHECK_CMD_LENGTH (i40e_aqc_get_link_status);
drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h +6 -1
@@ -1755,7 +1755,12 @@ struct i40e_aqc_get_link_status {u8 config;#define I40E_AQ_CONFIG_CRC_ENA 0x04#define I40E_AQ_CONFIG_PACING_MASK 0x78 -u8 reserved[5 ]; +u8 external_power_ability; +#define I40E_AQ_LINK_POWER_CLASS_1 0x00 +#define I40E_AQ_LINK_POWER_CLASS_2 0x01 +#define I40E_AQ_LINK_POWER_CLASS_3 0x02 +#define I40E_AQ_LINK_POWER_CLASS_4 0x03 +u8 reserved[4 ]; };I40E_CHECK_CMD_LENGTH (i40e_aqc_get_link_status);
Signature · 1 line
2.1.0
Bowers
PATCH 11/12 i40e: AQ Add external power class to get link status
Quoted 16 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 11/12] i40e: AQ Add external power class to get link statusFrom: Shannon Nelson <[email protected]>
Add the new External Device Power Ability field to the
get_link_statusdata structure, using space from the reserved field at the end of the struct.Signed-off-by Shannon Nelson <[email protected]>Acked-by Kevin Scott <[email protected]>Signed-off-by Jeff Kirsher <[email protected]>
Quoted 7 lines
---
Testing-Hints:
Apply and compile cleanly.drivers/net/ethernet/intel/i40e/i40e_adminq_cmd.h | 7 ++++++- drivers/net/ethernet/intel/i40evf/i40e_adminq_cmd.h | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-)
Patch code changes correctly applied
PATCH 12/12 i40e: add 100Mb ethtool reporting
In reply to Deepthi KavalurFrom: Catherine Sullivan <[email protected]>
Add some missing reporting/advertisement of 100Mb capability for adapters that support it.
---
Testing-Hints:
Check that 100M SGMII is not listed as supported on X710 devices and is listed as supported on X722 devices.
drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 4 ++++ drivers/net/ethernet/intel/i40e/i40e_main.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +4 -0
@@ -412,6 +412,10 @@ static void i40e_get_settings_link_down(struct i40e_hw *hw,if (pf->hw.mac.type ==I40E_MAC_X722 ) { ecmd->supported |= SUPPORTED_100baseT_Full; ecmd->advertising |= ADVERTISED_100baseT_Full; +if (pf->flags &I40E_FLAG_100M_SGMII_CAPABLE ) { + ecmd->supported |= SUPPORTED_100baseT_Full; + ecmd->advertising |= ADVERTISED_100baseT_Full; + } } } if (phy_types & I40E_CAP_PHY_TYPE_XAUI ||
drivers/net/ethernet/intel/i40e/i40e_main.c +2 -1
@@ -8448,7 +8448,8 @@ static int i40e_sw_init(struct i40e_pf *pf)I40E_FLAG_HW_ATR_EVICT_CAPABLE |I40E_FLAG_OUTER_UDP_CSUM_CAPABLE |I40E_FLAG_WB_ON_ITR_CAPABLE | -I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE ; +I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE | +I40E_FLAG_100M_SGMII_CAPABLE ; }else { pf->auto_disable_flags =I40E_FLAG_HW_ATR_EVICT_CAPABLE ; }
Signature · 1 line
2.1.0
Bowers
PATCH 12/12 i40e: add 100Mb ethtool reporting
Quoted 15 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Deepthi Kavalur
Sent: Tuesday, December 22, 2015 2:25 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S24 12/12] i40e: add 100Mb ethtool reportingFrom: Catherine Sullivan <[email protected]>
Add some missing reporting/advertisement of 100Mb capability for adapters that support it.
Signed-off-by Catherine Sullivan <[email protected]>Change-ID I8b8523fbdc99517bec29d90c71b3744db11542ac
Quoted 8 lines
---
Testing-Hints:
Check that 100M SGMII is not listed as supported on X710 devices and is listed as supported on X722 devices.drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 4 ++++ drivers/net/ethernet/intel/i40e/i40e_main.c | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-)
Patch code changes correctly applied, does not break base driver