i40e/i40evf updates
Subsystems (2)
cover i40e/i40evf updates
Anjali adds WB_ON_ITR offload support to i40evf and fixes the PCI bus info for X722.
Catherine removes 100M settings from get_settings that are no longer supported.
Jesse adds a missing parameter comment to ndo_bridge_setlink and uses priv flags to control flow director.
Kevin stores off PHY capabilities.
Kiran adds a spin lock for VSI's MAC filter list.
Mitch removes an obsolete version check and speeds up i40evf's init.
Neerav change some messages from info to debug only.
Shannon allows FD SB if MFP mode only has 1 partition, removes FD atr control from debugfs, removes redundant declarations of a variable and a function and removes unnecessary string copy operations.
drivers/net/ethernet/intel/i40e/i40e.h | 4 + drivers/net/ethernet/intel/i40e/i40e_common.c | 3 + drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c | 7 +- drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 24 -- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 59 ++- drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 4 +- drivers/net/ethernet/intel/i40e/i40e_main.c | 451 ++++++++++++++++----- drivers/net/ethernet/intel/i40e/i40e_virtchnl.h | 1 + drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 30 +- drivers/net/ethernet/intel/i40evf/i40e_virtchnl.h | 1 + drivers/net/ethernet/intel/i40evf/i40evf_main.c | 13 +- .../net/ethernet/intel/i40evf/i40evf_virtchnl.c | 3 +- 12 files changed, 443 insertions(+), 157 deletions(-)
Signature · 1 line
1.9.3
PATCH 1/15 i40e: Add missing parameter comment to ndo_bridge_setlink
From: Jesse Brandeburg <[email protected]>
Add nlflags to the function comment for ndo_bridge_setlink.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + 1 file changed, 1 insertion(+)
drivers/net/ethernet/intel/i40e/i40e_main.c +1 -0
@@ -8331,6 +8331,7 @@ static int i40e_ndo_bridge_setlink(struct net_device *dev,* @seq: RTNL message seq # * @dev: the netdev being configured * @filter_mask: unused +* @nlflags: netlink flags passed in * * Return the mode in which the hardware bridge is operating in * i.e VEB or VEPA.
Signature · 1 line
1.9.3
Bowers
PATCH 1/15 i40e: Add missing parameter comment to ndo_bridge_setlink
Quoted 10 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 01/15] i40e: Add missing parameter comment tondo_bridge_setlinkFrom: Jesse Brandeburg <[email protected]>
Quoted 7 lines
Add nlflags to the function comment for
ndo_bridge_setlink.Signed-off-by Jesse Brandeburg <[email protected]>Change-ID I34c704f307f2a3f7bac3ca4b44e2a094d3d082d6--- drivers/net/ethernet/intel/i40e/i40e_main.c | 1 + 1 file changed, 1 insertion(+)
Code changes present in tree
PATCH 2/15 i40e: use priv flags to control flow director
In reply to Catherine SullivanFrom: Jesse Brandeburg <[email protected]>
Some customers wish to be able to control our hardware specific feature called flow director, at runtime. This patch enables ethtool priv flags to control this driver/hardware specific feature.
ethtool --set-priv-flags ethX flow-director-atr off
NOTE: the ethtool ntuple interface controls the flow-director
sideband rules.
--- drivers/net/ethernet/intel/i40e/i40e.h | 1 + drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 14 ++++++++++++++ 2 files changed, 15 insertions(+)
drivers/net/ethernet/intel/i40e/i40e.h +1 -0
@@ -102,6 +102,7 @@/* Ethtool Private Flags */ #define I40E_PRIV_FLAGS_NPAR_FLAG BIT(0)#define I40E_PRIV_FLAGS_LINKPOLL_FLAG BIT(1) +#define I40E_PRIV_FLAGS_FD_ATR BIT(2)#define I40E_NVM_VERSION_LO_SHIFT 0#define I40E_NVM_VERSION_LO_MASK (0xff << I40E_NVM_VERSION_LO_SHIFT)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +14 -0
@@ -231,6 +231,7 @@ static const char i40e_gstrings_test[][ETH_GSTRING_LEN] = {static const char i40e_priv_flags_strings[][ETH_GSTRING_LEN ] = {"NPAR" ,"LinkPolling" , +"flow-director-atr" , };#define I40E_PRIV_FLAGS_STR_LEN ARRAY_SIZE(i40e_priv_flags_strings)
@@ -2666,6 +2667,8 @@ static u32 i40e_get_priv_flags(struct net_device *dev) I40E_PRIV_FLAGS_NPAR_FLAG :0 ; ret_flags |= pf->flags &I40E_FLAG_LINK_POLLING_ENABLED ?I40E_PRIV_FLAGS_LINKPOLL_FLAG :0 ; + ret_flags |= pf->flags &I40E_FLAG_FD_ATR_ENABLED ? +I40E_PRIV_FLAGS_FD_ATR :0 ;return ret_flags; }
@@ -2686,6 +2689,17 @@ static int i40e_set_priv_flags(struct net_device *dev, u32 flags)else pf->flags &= ~I40E_FLAG_LINK_POLLING_ENABLED ; +/* allow the user to control the state of the Flow +* Director ATR (Application Targeted Routing) feature +* of the driver +*/ +if (flags &I40E_PRIV_FLAGS_FD_ATR ) { + pf->flags |=I40E_FLAG_FD_ATR_ENABLED ; + }else { + pf->flags &= ~I40E_FLAG_FD_ATR_ENABLED ; + pf->auto_disable_flags |=I40E_FLAG_FD_ATR_ENABLED ; + } +return 0 ; }
Signature · 1 line
1.9.3
Bowers
PATCH 2/15 i40e: use priv flags to control flow director
Quoted 19 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 02/15] i40e: use priv flags to control flow directorFrom: Jesse Brandeburg <[email protected]>
Some customers wish to be able to control our hardware specific feature called flow director, at runtime. This patch enables ethtool priv flags to control this driver/hardware specific feature.
ethtool --set-priv-flags ethX flow-director-atr off
NOTE: the ethtool ntuple interface controls the flow-director
sideband rules.
Quoted 6 lines
Signed-off-by Jesse Brandeburg <[email protected]>Change-ID Iba156350b07fa2ce66f53ded51739f9a3781fe0e--- drivers/net/ethernet/intel/i40e/i40e.h | 1 + drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 14 ++++++++++++++ 2 files changed, 15 insertions(+)
Code changes present in tree, ethtool sets and shows flags properly
PATCH 3/15 i40e: Change some messages from info to debug only
In reply to Catherine SullivanFrom: Neerav Parikh <[email protected]>
There are several error messages that have been printing when there is no functional issue. These messages should be available at debug message level only.
--- drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c | 7 +++---- drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 +- drivers/net/ethernet/intel/i40e/i40e_main.c | 21 +++++++++++++-------- 3 files changed, 17 insertions(+), 13 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c +3 -4
@@ -240,10 +240,9 @@ static void i40e_dcbnl_del_app(struct i40e_pf *pf,for (v =0 ; v < pf->num_alloc_vsi; v++) {if (pf->vsi[v] && pf->vsi[v]->netdev) { err =i40e_dcbnl_vsi_del_app (pf->vsi[v], app); -if (err) -dev_info (&pf->pdev->dev,"Failed deleting app for VSI seid=%d err=%d sel=%d proto=0x%x prio=%d\n" , - pf->vsi[v]->seid, err, app->selector, - app->protocolid, app->priority); +dev_dbg (&pf->pdev->dev,"Deleting app for VSI seid=%d err=%d sel=%d proto=0x%x prio=%d\n" , + pf->vsi[v]->seid, err, app->selector, + app->protocolid, app->priority); } } }
drivers/net/ethernet/intel/i40e/i40e_fcoe.c +1 -1
@@ -284,7 +284,7 @@ void i40e_init_pf_fcoe(struct i40e_pf *pf) pf->fcoe_hmc_filt_num =0 ;if (!pf->hw.func_caps.fcoe) { -dev_info (&pf->pdev->dev,"FCoE capability is disabled\n" ); +dev_dbg (&pf->pdev->dev,"FCoE capability is disabled\n" );return ; }
drivers/net/ethernet/intel/i40e/i40e_main.c +13 -8
@@ -6518,9 +6518,9 @@ static void i40e_reset_and_rebuild(struct i40e_pf *pf, bool reinit)/* make sure our flow control settings are restored */ ret =i40e_set_fc (&pf->hw, &set_fc_aq_fail, true);if (ret) -dev_info (&pf->pdev->dev,"set fc fail, err %s aq_err %s\n" , -i40e_stat_str (&pf->hw, ret), -i40e_aq_str (&pf->hw, pf->hw.aq.asq_last_status)); +dev_dbg (&pf->pdev->dev,"setting flow control: ret = %s last_status = %s\n" , +i40e_stat_str (&pf->hw, ret), +i40e_aq_str (&pf->hw, pf->hw.aq.asq_last_status));/* Rebuild the VSIs and VEBs that existed before reset. * They are still in our local switch element arrays, so only
@@ -9877,8 +9877,14 @@ static void i40e_determine_queue_usage(struct i40e_pf *pf) } pf->queues_left = queues_left; +dev_dbg (&pf->pdev->dev, +"qs_avail=%d FD SB=%d lan_qs=%d lan_tc0=%d vf=%d*%d vmdq=%d*%d, remaining=%d\n" , + pf->hw.func_caps.num_tx_qp, + !!(pf->flags &I40E_FLAG_FD_SB_ENABLED ), + pf->num_lan_qps, pf->rss_size, pf->num_req_vfs, pf->num_vf_qps, + pf->num_vmdq_vsis, pf->num_vmdq_qps, queues_left);#ifdef I40E_FCOE -dev_info (&pf->pdev->dev,"fcoe queues = %d\n" , pf->num_fcoe_qps); +dev_dbg (&pf->pdev->dev,"fcoe queues = %d\n" , pf->num_fcoe_qps);#endif }
@@ -10364,10 +10370,9 @@ static int i40e_probe(struct pci_dev *pdev, const struct pci_device_id *ent)/* get the requested speeds from the fw */ err =i40e_aq_get_phy_capabilities (hw, false, false, &abilities,NULL );if (err) -dev_info (&pf->pdev->dev, -"get phy capabilities failed, err %s aq_err %s, advertised speed settings may not be correct\n" , -i40e_stat_str (&pf->hw, err), -i40e_aq_str (&pf->hw, pf->hw.aq.asq_last_status)); +dev_dbg (&pf->pdev->dev,"get requested speeds ret = %s last_status = %s\n" , +i40e_stat_str (&pf->hw, err), +i40e_aq_str (&pf->hw, pf->hw.aq.asq_last_status)); pf->hw.phy.link_info.requested_speeds = abilities.link_speed;/* get the supported phy types from the fw */
Signature · 1 line
1.9.3
Bowers
PATCH 3/15 i40e: Change some messages from info to debug only
Quoted 18 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 03/15] i40e: Change some messages from info to debug onlyFrom: Neerav Parikh <[email protected]>
There are several error messages that have been printing when there is no functional issue. These messages should be available at debug message level only.
Signed-off-by Neerav Parikh <[email protected]>Signed-off-by Catherine Sullivan <[email protected]>Signed-off-by Shannon Nelson <[email protected]>Change-ID Id91e47bf942c483563995f30d8705fa53acd5aa3
Quoted 5 lines
--- drivers/net/ethernet/intel/i40e/i40e_dcb_nl.c | 7 +++---- drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 +- drivers/net/ethernet/intel/i40e/i40e_main.c | 21 +++++++++++++-------- 3 files changed, 17 insertions(+), 13 deletions(-)
Code changes present in tree
PATCH 4/15 i40e: Lock for VSI's MAC filter list
In reply to Catherine SullivanFrom: Kiran Patil <[email protected]>
This patch introduces a spinlock which is to be used for synchronizing access to VSI's MAC filter list.
This patch also synchronizes execution of other codepaths which are accessing VSI's MAC filter list with execution of service_task:sync_vsi_filters.
In function i40e_add_vsi, copied out LAA MAC address instead of cloning MAC filter entry because only MAC address is needed to remove MAC VLAN filter from FW/HW.
--- drivers/net/ethernet/intel/i40e/i40e.h | 2 + drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 + drivers/net/ethernet/intel/i40e/i40e_main.c | 326 +++++++++++++++++---- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 26 +- 4 files changed, 300 insertions(+), 56 deletions(-)
drivers/net/ethernet/intel/i40e/i40e.h +2 -0
@@ -469,6 +469,8 @@ struct i40e_vsi {#define I40E_VSI_FLAG_VEB_OWNER BIT(1)unsigned long flags; +/* Per VSI lock to protect elements/list (MAC filter) */ +spinlock_t mac_filter_list_lock;struct list_head mac_filter_list;/* VSI stats */
drivers/net/ethernet/intel/i40e/i40e_fcoe.c +2 -0
@@ -1516,10 +1516,12 @@ void i40e_fcoe_config_netdev(struct net_device *netdev, struct i40e_vsi *vsi)* same PCI function. */ netdev->dev_port =1 ; +spin_lock (&vsi->mac_filter_list_lock);i40e_add_filter (vsi, hw->mac.san_addr,0 , false, false);i40e_add_filter (vsi, (u8 [6 ])FC_FCOE_FLOGI_MAC ,0 , false, false);i40e_add_filter (vsi,FIP_ALL_FCOE_MACS ,0 , false, false);i40e_add_filter (vsi,FIP_ALL_ENODE_MACS ,0 , false, false); +spin_unlock (&vsi->mac_filter_list_lock);/* use san mac */ ether_addr_copy (netdev->dev_addr, hw->mac.san_addr);
drivers/net/ethernet/intel/i40e/i40e_main.c +271 -55
580 lines not on this page · raw message
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c +25 -1
@@ -547,6 +547,8 @@ static int i40e_alloc_vsi_res(struct i40e_vf *vf, enum i40e_vsi_type type)*/ if (vf->port_vlan_id)i40e_vsi_add_pvid (vsi, vf->port_vlan_id); + +spin_lock (&vsi->mac_filter_list_lock); f =i40e_add_filter (vsi, vf->default_lan_addr.addr, vf->port_vlan_id ? vf->port_vlan_id :-1 , true, false);
@@ -559,6 +561,7 @@ static int i40e_alloc_vsi_res(struct i40e_vf *vf, enum i40e_vsi_type type)if (!f)dev_info (&pf->pdev->dev,"Could not allocate VF broadcast filter\n" ); +spin_unlock (&vsi->mac_filter_list_lock); }/* program mac filter */
@@ -1592,6 +1595,11 @@ static int i40e_vc_add_mac_addr_msg(struct i40e_vf *vf, u8 *msg, u16 msglen) } vsi = pf->vsi[vf->lan_vsi_idx]; +/* Lock once, because all function inside for loop accesses VSI's +* MAC filter list which needs to be protected using same lock. +*/ +spin_lock (&vsi->mac_filter_list_lock); +/* add new addresses to the list */ for (i =0 ; i < al->num_elements; i++) {struct i40e_mac_filter *f;
@@ -1610,9 +1618,11 @@ static int i40e_vc_add_mac_addr_msg(struct i40e_vf *vf, u8 *msg, u16 msglen)dev_err (&pf->pdev->dev,"Unable to add VF MAC filter\n" ); ret =I40E_ERR_PARAM ; +spin_unlock (&vsi->mac_filter_list_lock); goto error_param; } } +spin_unlock (&vsi->mac_filter_list_lock);/* program the updated filter list */ if (i40e_sync_vsi_filters (vsi))
@@ -1660,10 +1670,12 @@ static int i40e_vc_del_mac_addr_msg(struct i40e_vf *vf, u8 *msg, u16 msglen) } vsi = pf->vsi[vf->lan_vsi_idx]; +spin_lock (&vsi->mac_filter_list_lock);/* delete addresses from the list */ for (i =0 ; i < al->num_elements; i++)i40e_del_filter (vsi, al->list[i].addr,I40E_VLAN_ANY , true, false); +spin_unlock (&vsi->mac_filter_list_lock);/* program the updated filter list */ if (i40e_sync_vsi_filters (vsi))
@@ -2060,6 +2072,11 @@ int i40e_ndo_set_vf_mac(struct net_device *netdev, int vf_id, u8 *mac) goto error_param; } +/* Lock once because below invoked function add/del_filter requires +* mac_filter_list_lock to be held +*/ +spin_lock (&vsi->mac_filter_list_lock); +/* delete the temporary mac address */ i40e_del_filter(vsi, vf->default_lan_addr.addr, vf->port_vlan_id ? vf->port_vlan_id : -1,
@@ -2071,6 +2088,8 @@ int i40e_ndo_set_vf_mac(struct net_device *netdev, int vf_id, u8 *mac)list_for_each_entry (f, &vsi->mac_filter_list, list)i40e_del_filter (vsi, f->macaddr, f->vlan, true, false); +spin_unlock (&vsi->mac_filter_list_lock); +dev_info (&pf->pdev->dev,"Setting MAC %pM on VF %d\n" , mac, vf_id);/* program mac filter */ if (i40e_sync_vsi_filters (vsi)) {
@@ -2103,6 +2122,7 @@ int i40e_ndo_set_vf_port_vlan(struct net_device *netdev,u16 vlanprio = vlan_id | (qos <<I40E_VLAN_PRIORITY_SHIFT );struct i40e_netdev_priv *np =netdev_priv (netdev);struct i40e_pf *pf = np->vsi->back; +bool is_vsi_in_vlan = false;struct i40e_vsi *vsi;struct i40e_vf *vf;int ret =0 ;
@@ -2132,7 +2152,11 @@ int i40e_ndo_set_vf_port_vlan(struct net_device *netdev,/* duplicate request, so just return success */ goto error_pvid; -if (le16_to_cpu (vsi->info.pvid) ==0 &&i40e_is_vsi_in_vlan (vsi)) { +spin_lock (&vsi->mac_filter_list_lock); + is_vsi_in_vlan =i40e_is_vsi_in_vlan (vsi); +spin_unlock (&vsi->mac_filter_list_lock); + +if (le16_to_cpu (vsi->info.pvid) ==0 && is_vsi_in_vlan) {dev_err (&pf->pdev->dev,"VF %d has already configured VLAN filters and the administrator is requesting a port VLAN override.\nPlease unload and reload the VF driver for this change to take effect.\n" , vf_id);
Signature · 1 line
1.9.3
Bowers
PATCH 4/15 i40e: Lock for VSI's MAC filter list
Quoted 23 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 04/15] i40e: Lock for VSI's MAC filter listFrom: Kiran Patil <[email protected]>
This patch introduces a spinlock which is to be used for synchronizing access to VSI's MAC filter list.
This patch also synchronizes execution of other codepaths which are accessing VSI's MAC filter list with execution of service_task:sync_vsi_filters.
In function
i40e_add_vsi, copied out LAA MAC address instead of cloning MAC filter entry because only MAC address is needed to remove MAC VLAN filter from FW/HW.Signed-off-by Kiran Patil <[email protected]>Signed-off-by Jesse Brandeburg <[email protected]>Change-ID I0e10ac7c715d44aa994239642aa4d57c998573a2
Quoted 7 lines
--- drivers/net/ethernet/intel/i40e/i40e.h | 2 + drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 + drivers/net/ethernet/intel/i40e/i40e_main.c | 326 +++++++++++++++++---- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 26 +- 4 files changed, 300 insertions(+), 56 deletions(-)
Code changes present in tree
PATCH 4/15 i40e: Lock for VSI's MAC filter list
In reply to Catherine SullivanQuoted 16 lines · On Thu, 3 Sep 2015 17:18:51 -0400 Catherine Sullivan…
From: Kiran Patil <[email protected]>
This patch introduces a spinlock which is to be used for synchronizing access to VSI's MAC filter list.
This patch also synchronizes execution of other codepaths which are accessing VSI's MAC filter list with execution of service_task:sync_vsi_filters.
In function
i40e_add_vsi, copied out LAA MAC address instead of cloning MAC filter entry because only MAC address is needed to remove MAC VLAN filter from FW/HW.Signed-off-by Kiran Patil <[email protected]>Signed-off-by Jesse Brandeburg <[email protected]>Change-ID I0e10ac7c715d44aa994239642aa4d57c998573a2
Quoted 7 lines
--- drivers/net/ethernet/intel/i40e/i40e.h | 2 + drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 + drivers/net/ethernet/intel/i40e/i40e_main.c | 326 +++++++++++++++++---- drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 26 +- 4 files changed, 300 insertions(+), 56 deletions(-)
This patch introduces a locking dependency issue, already solved by another patch we have prepared, which should either be applied on top of this one or squashed onto it.
Sullivan
PATCH 4/15 i40e: Lock for VSI's MAC filter list
Quoted 26 lines
From: Brandeburg, Jesse
Sent: Tuesday, September 29, 2015 12:08 PMQuoted 13 lines · On Thu, 3 Sep 2015 17:18:51 -0400 Catherine Sullivan…
From: Kiran Patil <[email protected]>
This patch introduces a spinlock which is to be used for synchronizing access to VSI's MAC filter list.
This patch also synchronizes execution of other codepaths which are accessing VSI's MAC filter list with execution of service_task:sync_vsi_filters.
In function
i40e_add_vsi, copied out LAA MAC address instead of cloning MAC filter entry because only MAC address is needed to remove MAC VLAN filter from FW/HW.Quoted 7 lines
Signed-off-by Kiran Patil <[email protected]>Signed-off-by Jesse Brandeburg <[email protected]>Change-ID I0e10ac7c715d44aa994239642aa4d57c998573a2--- drivers/net/ethernet/intel/i40e/i40e.h | 2 + drivers/net/ethernet/intel/i40e/i40e_fcoe.c | 2 + drivers/net/ethernet/intel/i40e/i40e_main.c | 326 +++++++++++++++++-
Quoted 8 lines
---
Quoted 3 lines
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 26 +- 4 files changed, 300 insertions(+), 56 deletions(-)This patch introduces a locking dependency issue, already solved by another patch we have prepared, which should either be applied on top of this one or squashed onto it.
Jeff, please drop this patch from S15, I will pull it in with the changes mentioned in S16.
PATCH 5/15 i40e: Remove 100M SGMII unless hw is X722
In reply to Catherine SullivanOnly the X722 device now supports 100M SGMII, and nothing supports 100M on 1000Base_T.
--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 42 ++++++++++++++++---------- 1 file changed, 26 insertions(+), 16 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +26 -16
@@ -255,7 +255,8 @@ static void i40e_partition_setting_complaint(struct i40e_pf *pf)**/ static void i40e_get_settings_link_up (struct i40e_hw *hw,struct ethtool_cmd *ecmd, -struct net_device *netdev) +struct net_device *netdev, +struct i40e_pf *pf) {struct i40e_link_status *hw_link_info = &hw->phy.link_info;u32 link_speed = hw_link_info->link_speed;
@@ -299,16 +300,18 @@ static void i40e_get_settings_link_up(struct i40e_hw *hw,break ;case I40E_PHY_TYPE_10GBASE_T :case I40E_PHY_TYPE_1000BASE_T : -case I40E_PHY_TYPE_100BASE_TX : ecmd->supported = SUPPORTED_Autoneg | SUPPORTED_10000baseT_Full | - SUPPORTED_1000baseT_Full | - SUPPORTED_100baseT_Full; + SUPPORTED_1000baseT_Full; ecmd->advertising = ADVERTISED_Autoneg;if (hw_link_info->requested_speeds &I40E_LINK_SPEED_10GB ) ecmd->advertising |= ADVERTISED_10000baseT_Full;if (hw_link_info->requested_speeds &I40E_LINK_SPEED_1GB ) ecmd->advertising |= ADVERTISED_1000baseT_Full; +break ; +case I40E_PHY_TYPE_100BASE_TX : + ecmd->supported = SUPPORTED_Autoneg | + SUPPORTED_100baseT_Full;if (hw_link_info->requested_speeds &I40E_LINK_SPEED_100MB ) ecmd->advertising |= ADVERTISED_100baseT_Full;break ;
@@ -328,12 +331,15 @@ static void i40e_get_settings_link_up(struct i40e_hw *hw,break ;case I40E_PHY_TYPE_SGMII : ecmd->supported = SUPPORTED_Autoneg | - SUPPORTED_1000baseT_Full | - SUPPORTED_100baseT_Full; + SUPPORTED_1000baseT_Full;if (hw_link_info->requested_speeds &I40E_LINK_SPEED_1GB ) ecmd->advertising |= ADVERTISED_1000baseT_Full; -if (hw_link_info->requested_speeds &I40E_LINK_SPEED_100MB ) - ecmd->advertising |= ADVERTISED_100baseT_Full; +if (pf->hw.mac.type ==I40E_MAC_X722 ) { + ecmd->supported |= SUPPORTED_100baseT_Full; +if (hw_link_info->requested_speeds & +I40E_LINK_SPEED_100MB ) + ecmd->advertising |= ADVERTISED_100baseT_Full; + }break ;/* Backplane is set based on supported phy types in get_settings * so don't set anything here but don't warn either
@@ -381,7 +387,8 @@ static void i40e_get_settings_link_up(struct i40e_hw *hw,* Reports link settings that can be determined when link is down **/ static void i40e_get_settings_link_down (struct i40e_hw *hw, -struct ethtool_cmd *ecmd) +struct ethtool_cmd *ecmd, +struct i40e_pf *pf) {enum i40e_aq_capabilities_phy_type phy_types = hw->phy.phy_types;
@@ -392,11 +399,13 @@ static void i40e_get_settings_link_down(struct i40e_hw *hw, ecmd->advertising =0x0 ;if (phy_types &I40E_CAP_PHY_TYPE_SGMII ) { ecmd->supported |= SUPPORTED_Autoneg | - SUPPORTED_1000baseT_Full | - SUPPORTED_100baseT_Full; + SUPPORTED_1000baseT_Full; ecmd->advertising |= ADVERTISED_Autoneg | - ADVERTISED_1000baseT_Full | - ADVERTISED_100baseT_Full; + ADVERTISED_1000baseT_Full; +if (pf->hw.mac.type ==I40E_MAC_X722 ) { + ecmd->supported |= SUPPORTED_100baseT_Full; + ecmd->advertising |= ADVERTISED_100baseT_Full; + } } if (phy_types & I40E_CAP_PHY_TYPE_XAUI || phy_types & I40E_CAP_PHY_TYPE_XFI ||
@@ -425,7 +434,8 @@ static void i40e_get_settings_link_down(struct i40e_hw *hw, ecmd->advertising |= ADVERTISED_Autoneg | ADVERTISED_40000baseCR4_Full; } -if (phy_types &I40E_CAP_PHY_TYPE_100BASE_TX ) { +if ((phy_types &I40E_CAP_PHY_TYPE_100BASE_TX ) && + !(phy_types &I40E_CAP_PHY_TYPE_1000BASE_T )) { ecmd->supported |= SUPPORTED_Autoneg | SUPPORTED_100baseT_Full; ecmd->advertising |= ADVERTISED_Autoneg |
@@ -467,9 +477,9 @@ static int i40e_get_settings(struct net_device *netdev,bool link_up = hw_link_info->link_info &I40E_AQ_LINK_UP ;if (link_up) -i40e_get_settings_link_up (hw, ecmd, netdev); +i40e_get_settings_link_up (hw, ecmd, netdev, pf);else -i40e_get_settings_link_down (hw, ecmd); +i40e_get_settings_link_down (hw, ecmd, pf);/* Now set the settings that don't rely on link being up/down */
Signature · 1 line
1.9.3
Bowers
PATCH 5/15 i40e: Remove 100M SGMII unless hw is X722
Quoted 11 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 05/15] i40e: Remove 100M SGMII unless hw is X722Only the X722 device now supports 100M SGMII, and nothing supports 100M on 1000Base_T.
Quoted 7 lines
Signed-off-by Catherine Sullivan <[email protected]>Signed-off-by Shannon Nelson <[email protected]>Change-ID I6f44dcd818944edd40041410e6de380f4a359a0c--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 42 ++++++++++++++++---- ------ 1 file changed, 26 insertions(+), 16 deletions(-)
Code changes present in tree
PATCH 6/15 i40e/i40evf: Add WB_ON_ITR offload support
In reply to Catherine SullivanFrom: Anjali Singhai Jain <[email protected]>
X722 has a way to work around the descriptor WB issue, this offload helps turn that feature on.
--- drivers/net/ethernet/intel/i40e/i40e_virtchnl.h | 1 + drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 4 ++++ drivers/net/ethernet/intel/i40evf/i40e_virtchnl.h | 1 + drivers/net/ethernet/intel/i40evf/i40evf_main.c | 5 +++++ drivers/net/ethernet/intel/i40evf/i40evf_virtchnl.c | 3 ++- 5 files changed, 13 insertions(+), 1 deletion(-)
drivers/net/ethernet/intel/i40e/i40e_virtchnl.h +1 -0
@@ -150,6 +150,7 @@ struct i40e_virtchnl_vsi_resource {#define I40E_VIRTCHNL_VF_OFFLOAD_FCOE 0x00000004#define I40E_VIRTCHNL_VF_OFFLOAD_RSS_AQ 0x00000008#define I40E_VIRTCHNL_VF_OFFLOAD_RSS_REG 0x00000010 +#define I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR 0x00000020#define I40E_VIRTCHNL_VF_OFFLOAD_VLAN 0x00010000#define I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING 0x00020000
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c +4 -0
@@ -1206,6 +1206,10 @@ static int i40e_vc_get_vf_resources_msg(struct i40e_vf *vf, u8 *msg) }else { vfres->vf_offload_flags |=I40E_VIRTCHNL_VF_OFFLOAD_RSS_REG ; } + +if (vf->driver_caps &I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING ) + vfres->vf_offload_flags |=I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING ; + 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_virtchnl.h +1 -0
@@ -150,6 +150,7 @@ struct i40e_virtchnl_vsi_resource {#define I40E_VIRTCHNL_VF_OFFLOAD_FCOE 0x00000004#define I40E_VIRTCHNL_VF_OFFLOAD_RSS_AQ 0x00000008#define I40E_VIRTCHNL_VF_OFFLOAD_RSS_REG 0x00000010 +#define I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR 0x00000020#define I40E_VIRTCHNL_VF_OFFLOAD_VLAN 0x00010000#define I40E_VIRTCHNL_VF_OFFLOAD_RX_POLLING 0x00020000
drivers/net/ethernet/intel/i40evf/i40evf_main.c +5 -0
@@ -1123,6 +1123,8 @@ static int i40evf_alloc_queues(struct i40evf_adapter *adapter) tx_ring->netdev = adapter->netdev; tx_ring->dev = &adapter->pdev->dev; tx_ring->count = adapter->tx_desc_count; +if (adapter->flags &I40E_FLAG_WB_ON_ITR_CAPABLE ) + tx_ring->flags |=I40E_TXR_FLAGS_WB_ON_ITR ; adapter->tx_rings[i] = tx_ring; rx_ring = &tx_ring[1 ];
@@ -2275,6 +2277,9 @@ static void i40evf_init_task(struct work_struct *work)if (err) goto err_sw_init;i40evf_map_rings_to_vectors (adapter); +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_configure_rss (adapter); err =i40evf_request_misc_irq (adapter);
drivers/net/ethernet/intel/i40evf/i40evf_virtchnl.c +2 -1
@@ -156,7 +156,8 @@ int i40evf_send_vf_config_msg(struct i40evf_adapter *adapter) caps =I40E_VIRTCHNL_VF_OFFLOAD_L2 |I40E_VIRTCHNL_VF_OFFLOAD_RSS_AQ |I40E_VIRTCHNL_VF_OFFLOAD_RSS_REG | -I40E_VIRTCHNL_VF_OFFLOAD_VLAN ; +I40E_VIRTCHNL_VF_OFFLOAD_VLAN | +I40E_VIRTCHNL_VF_OFFLOAD_WB_ON_ITR ; adapter->current_op =I40E_VIRTCHNL_OP_GET_VF_RESOURCES ; adapter->aq_required &= ~I40EVF_FLAG_AQ_GET_CONFIG ;if (PF_IS_V11 (adapter))
Signature · 1 line
1.9.3
Bowers
PATCH 6/15 i40e/i40evf: Add WB_ON_ITR offload support
Quoted 15 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 06/15] i40e/i40evf: AddWB_ON_ITRoffload supportFrom: Anjali Singhai Jain <[email protected]>
X722 has a way to work around the descriptor WB issue, this offload helps turn that feature on.
Signed-off-by Anjali Singhai Jain <[email protected]>Change-ID I7ffa67622426bfca5a651417b63e3afcfeb60412
Quoted 7 lines
--- drivers/net/ethernet/intel/i40e/i40e_virtchnl.h | 1 + drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 4 ++++ drivers/net/ethernet/intel/i40evf/i40e_virtchnl.h | 1 + drivers/net/ethernet/intel/i40evf/i40evf_main.c | 5 +++++ drivers/net/ethernet/intel/i40evf/i40evf_virtchnl.c | 3 ++- 5 files changed, 13 insertions(+), 1 deletion(-)
Code changes present in tree
PATCH 7/15 i40e: remove obsolete version check
In reply to Catherine SullivanFrom: Mitch Williams <[email protected]>
This version check only applies to very, very old firmware, that only ran on A0 hardware, which we never shipped and don't support in this driver anyway. Remove it, before somebody gets hurt.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 6 ------ 1 file changed, 6 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +0 -6
@@ -6468,12 +6468,6 @@ static int i40e_get_capabilities(struct i40e_pf *pf) } }while (err); -if (((pf->hw.aq.fw_maj_ver ==2 ) && (pf->hw.aq.fw_min_ver <22 )) || - (pf->hw.aq.fw_maj_ver <2 )) { - pf->hw.func_caps.num_msix_vectors++; - pf->hw.func_caps.num_msix_vectors_vf++; - } -if (pf->hw.debug_mask &I40E_DEBUG_USER ) dev_info(&pf->pdev->dev, "pf=%d, num_vfs=%d, msix_pf=%d, msix_vf=%d, fd_g=%d, fd_b=%d, pf_max_q=%d num_vsi=%d\n",
Signature · 1 line
1.9.3
Bowers
PATCH 7/15 i40e: remove obsolete version check
Quoted 14 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 07/15] i40e: remove obsolete version checkFrom: Mitch Williams <[email protected]>
This version check only applies to very, very old firmware, that only ran on A0 hardware, which we never shipped and don't support in this driver anyway. Remove it, before somebody gets hurt.
Quoted 5 lines
Signed-off-by Mitch Williams <[email protected]>Change-ID I3752d090ff488acf98ee76b075af961e9c968ee4--- drivers/net/ethernet/intel/i40e/i40e_main.c | 6 ------ 1 file changed, 6 deletions(-)
Code changes present in tree
PATCH 8/15 i40e: allow FD SB if MFP mode only has 1 partition
In reply to Catherine SullivanFrom: Shannon Nelson <[email protected]>
Even though the device might be in MFP mode, if there's only one partition enabled, then we still have plenty of interrupts for managing the Flow Directory Sideband activity. This patch enables FD SB in this case. This patch also reverses the sense of the conditional in order to remove the negative logic.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +4 -4
@@ -8061,12 +8061,12 @@ static int i40e_sw_init(struct i40e_pf *pf) (pf->hw.func_caps.fd_filters_best_effort > 0)) { pf->flags |=I40E_FLAG_FD_ATR_ENABLED ; pf->atr_sample_rate =I40E_DEFAULT_ATR_SAMPLE_RATE ; -if (!(pf->flags &I40E_FLAG_MFP_ENABLED )) { - pf->flags |=I40E_FLAG_FD_SB_ENABLED ; - }else { +if (pf->flags &I40E_FLAG_MFP_ENABLED && + pf->hw.num_partitions >1 )dev_info (&pf->pdev->dev,"Flow Director Sideband mode Disabled in MFP mode\n" ); - } +else + pf->flags |=I40E_FLAG_FD_SB_ENABLED ; pf->fdir_pf_filter_count = pf->hw.func_caps.fd_filters_guaranteed; pf->hw.fdir_shared_filter_count =
Signature · 1 line
1.9.3
Bowers
PATCH 8/15 i40e: allow FD SB if MFP mode only has 1 partition
Quoted 16 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 08/15] i40e: allow FD SB if MFP mode only has 1 partitionFrom: Shannon Nelson <[email protected]>
Even though the device might be in MFP mode, if there's only one partition enabled, then we still have plenty of interrupts for managing the Flow Directory Sideband activity. This patch enables FD SB in this case. This patch also reverses the sense of the conditional in order to remove the negative logic.
Quoted 5 lines
Signed-off-by Shannon Nelson <[email protected]>Change-ID I9edf211a6219fc8d159b4be9964f9fd7f4e00bc0--- drivers/net/ethernet/intel/i40e/i40e_main.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-)
Code changes present in tree
PATCH 9/15 i40e: remove FD atr control from debugfs
In reply to Catherine SullivanFrom: Shannon Nelson <[email protected]>
Since the flow-director-atr priv flag was added to our ethtool interface, we don't need the on/off control in debugfs.
--- drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 24 ------------------------ 1 file changed, 24 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_debugfs.c +0 -24
@@ -953,24 +953,6 @@ static void i40e_dbg_dump_veb_all(struct i40e_pf *pf) } } -/** -* i40e_dbg_cmd_fd_ctrl - Enable/disable FD sideband/ATR -* @pf: the PF that would be altered -* @flag: flag that needs enabling or disabling -* @enable: Enable/disable FD SD/ATR -**/ -static void i40e_dbg_cmd_fd_ctrl (struct i40e_pf *pf,u64 flag,bool enable) -{ -if (enable) { - pf->flags |= flag; - }else { - pf->flags &= ~flag; - pf->auto_disable_flags |= flag; - } -dev_info (&pf->pdev->dev,"requesting a PF reset\n" ); -i40e_do_reset_safe (pf,BIT (__I40E_PF_RESET_REQUESTED)); -} -#define I40E_MAX_DEBUG_OUT_BUFFER (4096*4)/** * i40e_dbg_command_write - write into command datum
@@ -1759,10 +1741,6 @@ static ssize_t i40e_dbg_command_write(struct file *filp, raw_packet =NULL ;kfree (asc_packet); asc_packet =NULL ; - }else if (strncmp (cmd_buf,"fd-atr off" ,10 ) ==0 ) { -i40e_dbg_cmd_fd_ctrl (pf,I40E_FLAG_FD_ATR_ENABLED , false); - }else if (strncmp (cmd_buf,"fd-atr on" ,9 ) ==0 ) { -i40e_dbg_cmd_fd_ctrl (pf,I40E_FLAG_FD_ATR_ENABLED , true); }else if (strncmp (cmd_buf,"fd current cnt" ,14 ) ==0 ) {dev_info (&pf->pdev->dev,"FD current total filter count for this interface: %d\n" ,i40e_get_current_fd_count (pf));
@@ -1989,8 +1967,6 @@ static ssize_t i40e_dbg_command_write(struct file *filp,dev_info (&pf->pdev->dev," send indirect aq_cmd <flags> <opcode> <datalen> <retval> <cookie_h> <cookie_l> <param0> <param1> <param2> <param3> <buffer_len>\n" );dev_info (&pf->pdev->dev," add fd_filter <dest q_index> <flex_off> <pctype> <dest_vsi> <dest_ctl> <fd_status> <cnt_index> <fd_id> <packet_len> <packet>\n" );dev_info (&pf->pdev->dev," rem fd_filter <dest q_index> <flex_off> <pctype> <dest_vsi> <dest_ctl> <fd_status> <cnt_index> <fd_id> <packet_len> <packet>\n" ); -dev_info (&pf->pdev->dev," fd-atr off\n" ); -dev_info (&pf->pdev->dev," fd-atr on\n" );dev_info (&pf->pdev->dev," fd current cnt" );dev_info (&pf->pdev->dev," lldp start\n" );dev_info (&pf->pdev->dev," lldp stop\n" );
Signature · 1 line
1.9.3
Bowers
PATCH 9/15 i40e: remove FD atr control from debugfs
Quoted 10 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 09/15] i40e: remove FD atr control from debugfsFrom: Shannon Nelson <[email protected]>
Quoted 8 lines
Since the flow-director-atr priv flag was added to our ethtool interface, we don't need the on/off control in debugfs.
Signed-off-by Shannon Nelson <[email protected]>Change-ID Ib3b599916434ab30ccd40074e71d7a81609b5bb5--- drivers/net/ethernet/intel/i40e/i40e_debugfs.c | 24 ------------------------ 1 file changed, 24 deletions(-)
Code changes present in tree
PATCH 10/15 i40e/i40evf: remove redundant declarations of a variable and a function
In reply to Catherine SullivanFrom: Shannon Nelson <[email protected]>
Remove a variable declaration inside an if block hiding an existing declaration at the start of the function.
Also remove a forward function declaration that is no longer needed due to code re-organization.
--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 3 --- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_ethtool.c +0 -3
@@ -90,9 +90,6 @@ static const struct i40e_stats i40e_gstrings_misc_stats[] = { I40E_VSI_STAT("tx_linearize", tx_linearize), }; -static int i40e_add_fdir_ethtool (struct i40e_vsi *vsi, -struct ethtool_rxnfc *cmd); -/* These PF_STATs might look like duplicates of some NETDEV_STATs, * but they are separate. This device supports Virtualization, and * as such might have several netdevs supporting VMDq and FCoE going
drivers/net/ethernet/intel/i40evf/i40evf_main.c +1 -1
@@ -1628,7 +1628,7 @@ static void i40evf_reset_task(struct work_struct *work)/* extra wait to make sure minimum wait is met */ msleep (I40EVF_RESET_WAIT_MS );if (i ==I40EVF_RESET_WAIT_COUNT ) { -struct i40evf_mac_filter *f, *ftmp; +struct i40evf_mac_filter *ftmp;struct i40evf_vlan_filter *fv, *fvtmp;/* reset never finished */
Signature · 1 line
1.9.3
Bowers
PATCH 10/15 i40e/i40evf: remove redundant declarations of a variable and a function
Quoted 16 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 10/15] i40e/i40evf: remove redundant declarations of a variable and a functionFrom: Shannon Nelson <[email protected]>
Remove a variable declaration inside an if block hiding an existing declaration at the start of the function.
Also remove a forward function declaration that is no longer needed due to code re-organization.
Quoted 6 lines
Signed-off-by Shannon Nelson <[email protected]>Change-ID I12954668b722718074949c93d74cd20eaacd93e4--- drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 3 --- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 1 insertion(+), 4 deletions(-)
Code changes present in tree
PATCH 11/15 i40e: Store off PHY capabilities
In reply to Catherine SullivanFrom: Kevin Scott <[email protected]>
Store off reported PHY capabilities in link_info structure.
--- drivers/net/ethernet/intel/i40e/i40e_common.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/ethernet/intel/i40e/i40e_common.c +3 -0
@@ -1617,6 +1617,9 @@ i40e_status i40e_aq_get_phy_capabilities(struct i40e_hw *hw,if (hw->aq.asq_last_status ==I40E_AQ_RC_EIO ) status =I40E_ERR_UNKNOWN_PHY ; +if (report_init) + hw->phy.phy_types =le32_to_cpu (abilities->phy_type); +return status; }
Signature · 1 line
1.9.3
Bowers
PATCH 11/15 i40e: Store off PHY capabilities
Quoted 11 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Cc: Scott, Kevin C
Subject: [Intel-wired-lan] [next PATCH S15 11/15] i40e: Store off PHY capabilitiesFrom: Kevin Scott <[email protected]>
Quoted 7 lines
Store off reported PHY capabilities in
link_infostructure.Signed-off-by Kevin Scott <[email protected]>Change-ID Ife0f037c26983ca985dbf79abf33f8f8791369e8--- drivers/net/ethernet/intel/i40e/i40e_common.c | 3 +++ 1 file changed, 3 insertions(+)
Code changes present in tree
PATCH 12/15 i40e: X722 is on the IOSF bus and does not report the PCI bus info
In reply to Catherine SullivanFrom: Anjali Singhai Jain <[email protected]>
X722 will report Gen 1x1 in the PCI config space as it is on IOSF bus, so skip the PCI bus link/speed check.
--- drivers/net/ethernet/intel/i40e/i40e.h | 1 + drivers/net/ethernet/intel/i40e/i40e_main.c | 69 ++++++++++++++++++++--------- 2 files changed, 50 insertions(+), 20 deletions(-)
drivers/net/ethernet/intel/i40e/i40e.h +1 -0
@@ -336,6 +336,7 @@ struct i40e_pf {#define I40E_FLAG_LINK_POLLING_ENABLED BIT_ULL(39)#define I40E_FLAG_VEB_MODE_ENABLED BIT_ULL(40)#define I40E_FLAG_GENEVE_OFFLOAD_CAPABLE BIT_ULL(41) +#define I40E_FLAG_NO_PCI_LINK_CHECK BIT_ULL(42)/* tracks features that get auto disabled by errors */ u64 auto_disable_flags;
drivers/net/ethernet/intel/i40e/i40e_main.c +49 -20
75 lines not on this page · raw message
Signature · 1 line
1.9.3
Bowers
PATCH 12/15 i40e: X722 is on the IOSF bus and does not report the PCI bus info
Quoted 13 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 12/15] i40e: X722 is on the IOSF bus and does not report the PCI bus infoFrom: Anjali Singhai Jain <[email protected]>
X722 will report Gen 1x1 in the PCI config space as it is on IOSF bus, so skip the PCI bus link/speed check.
Quoted 7 lines
Signed-off-by Anjali Singhai Jain <[email protected]>Change-ID Icd5f5751dc7fb00dccf0d5dc5a0a644948e7062e--- drivers/net/ethernet/intel/i40e/i40e.h | 1 + drivers/net/ethernet/intel/i40e/i40e_main.c | 69 ++++++++++++++++++++--------- 2 files changed, 50 insertions(+), 20 deletions(-)
Code changes present in tree
PATCH 13/15 i40e: remove unnecessary string copy operations
In reply to Catherine SullivanFrom: Shannon Nelson <[email protected]>
Save a little stack space and remove unnecessary strncpy() with a little string pointer.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +12 -12
@@ -4896,8 +4896,8 @@ out:*/ void i40e_print_link_message (struct i40e_vsi *vsi,bool isup) { -char speed[SPEED_SIZE ] ="Unknown" ; -char fc[FC_SIZE ] ="RX/TX" ; +char *speed ="Unknown" ; +char *fc ="Unknown" ;if (vsi->current_isup == isup)return ;
@@ -4918,19 +4918,19 @@ void i40e_print_link_message(struct i40e_vsi *vsi, bool isup)switch (vsi->back->hw.phy.link_info.link_speed) {case I40E_LINK_SPEED_40GB : -strlcpy (speed,"40 Gbps" ,SPEED_SIZE ); + speed ="40 G" ;break ;case I40E_LINK_SPEED_20GB : -strncpy (speed,"20 Gbps" ,SPEED_SIZE ); + speed ="20 G" ;break ;case I40E_LINK_SPEED_10GB : -strlcpy (speed,"10 Gbps" ,SPEED_SIZE ); + speed ="10 G" ;break ;case I40E_LINK_SPEED_1GB : -strlcpy (speed,"1000 Mbps" ,SPEED_SIZE ); + speed ="1000 M" ;break ;case I40E_LINK_SPEED_100MB : -strncpy (speed,"100 Mbps" ,SPEED_SIZE ); + speed ="100 M" ;break ;default :break ;
@@ -4938,20 +4938,20 @@ void i40e_print_link_message(struct i40e_vsi *vsi, bool isup)switch (vsi->back->hw.fc.current_mode) {case I40E_FC_FULL : -strlcpy (fc,"RX/TX" ,FC_SIZE ); + fc ="RX/TX" ;break ;case I40E_FC_TX_PAUSE : -strlcpy (fc,"TX" ,FC_SIZE ); + fc ="TX" ;break ;case I40E_FC_RX_PAUSE : -strlcpy (fc,"RX" ,FC_SIZE ); + fc ="RX" ;break ;default : -strlcpy (fc,"None" ,FC_SIZE ); + fc ="None" ;break ; } -netdev_info (vsi->netdev,"NIC Link is Up %s Full Duplex, Flow Control: %s\n" , +netdev_info (vsi->netdev,"NIC Link is Up %sbps Full Duplex, Flow Control: %s\n" , speed, fc); }
Signature · 1 line
1.9.3
Bowers
PATCH 13/15 i40e: remove unnecessary string copy operations
Quoted 10 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 13/15] i40e: remove unnecessary string copy operationsFrom: Shannon Nelson <[email protected]>
Quoted 8 lines
Save a little stack space and remove unnecessary
strncpy()with a little string pointer.Signed-off-by Shannon Nelson <[email protected]>Change-ID Id2719d34710bfc273d3bb445fec085cd04276e88--- drivers/net/ethernet/intel/i40e/i40e_main.c | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-)
Code changes present in tree
PATCH 14/15 i40evf: speed up init
In reply to Catherine SullivanFrom: Mitch Williams <[email protected]>
Shorten up the delays in the init task, allowing the VF driver to initialize faster. This aids performance in load/unload tests and mitigates DMAR errors in VF enable/disable tests with absurdly short delays. In the real world, the VF driver will come up more quickly.
The original values were set conservatively based on what we expected from the firmware in terms of performance. Now that the driver is in use and we know how well firmware responds to our requests, we can shorten these delays.
--- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/ethernet/intel/i40evf/i40evf_main.c +2 -2
@@ -2315,7 +2315,7 @@ static void i40evf_init_task(struct work_struct *work) }return ; restart: -schedule_delayed_work (&adapter->init_task,msecs_to_jiffies (30 )); +schedule_delayed_work (&adapter->init_task,msecs_to_jiffies (20 ));return ; err_register:
@@ -2332,7 +2332,7 @@ err: adapter->flags |=I40EVF_FLAG_PF_COMMS_FAILED ;return ;/* do not reschedule */ } -schedule_delayed_work (&adapter->init_task,HZ *3 ); +schedule_delayed_work (&adapter->init_task,HZ /2 ); }/**
Signature · 1 line
1.9.3
Bowers
PATCH 14/15 i40evf: speed up init
Quoted 19 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 14/15] i40evf: speed up initFrom: Mitch Williams <[email protected]>
Shorten up the delays in the init task, allowing the VF driver to initialize faster. This aids performance in load/unload tests and mitigates DMAR errors in VF enable/disable tests with absurdly short delays. In the real world, the VF driver will come up more quickly.
The original values were set conservatively based on what we expected from the firmware in terms of performance. Now that the driver is in use and we know how well firmware responds to our requests, we can shorten these delays.
Quoted 5 lines
Signed-off-by Mitch Williams <[email protected]>Change-ID Ibead77d34b19e8170e667c3f58bc14748bbc5bc9--- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
Code changes present in tree
PATCH 15/15 i40e/i40evf: Bump i40e version to 1.3.28 and i40evf to 1.3.19
In reply to Catherine SullivanBump.
--- drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
drivers/net/ethernet/intel/i40e/i40e_main.c +1 -1
@@ -40,7 +40,7 @@ static const char i40e_driver_string[] =#define DRV_VERSION_MAJOR 1#define DRV_VERSION_MINOR 3 -#define DRV_VERSION_BUILD 25 +#define DRV_VERSION_BUILD 28#define DRV_VERSION __stringify(DRV_VERSION_MAJOR) "." \ __stringify(DRV_VERSION_MINOR) "." \ __stringify(DRV_VERSION_BUILD) DRV_KERN
drivers/net/ethernet/intel/i40evf/i40evf_main.c +1 -1
@@ -34,7 +34,7 @@ char i40evf_driver_name[] = "i40evf";static const char i40evf_driver_string[] ="Intel(R) XL710/X710 Virtual Function Network Driver" ; -#define DRV_VERSION "1.3.17" +#define DRV_VERSION "1.3.19"const char i40evf_driver_version[] =DRV_VERSION ;static const char i40evf_copyright[] ="Copyright (c) 2013 - 2015 Intel Corporation." ;
Signature · 1 line
1.9.3
Bowers
PATCH 15/15 i40e/i40evf: Bump i40e version to 1.3.28 and i40evf to 1.3.19
Quoted 8 lines
-----Original Message-----
From: Intel-wired-lan [mailto:intel-wired-lan-bounces at lists.osuosl.org] On Behalf Of Catherine Sullivan
Sent: Thursday, September 03, 2015 2:19 PM
To: intel-wired-lan at lists.osuosl.org
Subject: [Intel-wired-lan] [next PATCH S15 15/15] i40e/i40evf: Bump i40e version to 1.3.28 and i40evf to 1.3.19
Quoted 8 lines
Bump.
Signed-off-by Catherine Sullivan <[email protected]>Change-ID I8d9a99f320af43960deba8718eee2d6de50eaf46--- drivers/net/ethernet/intel/i40e/i40e_main.c | 2 +- drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-)
Code changes present in tree, modinfo reports 1.3.28 for i40e and 1.3.19 for i40evf