From: Jeff Kirsher <hidden> Date: 2016-08-19 01:01:21
This series contains updates to i40e and i40evf only.
Wei Yongjun updates i40e to use list_move() instead of list_del() &
list_add() operations.
Anjali fixes an issue where the client->open call was not protected with
the client instance mutex, which allowed client->close to be called before
the open all completed.
Catherine makes sure that the VLAN count (and stats) gets reset to 0
after reset.
Jake provides two patches, first adds the needed rtnl lock around
i40evf_set_interrupt_capability() since i40evf_init_task() does not
hold the rtnl_lock. Second fixes an issue where users could reduce
the number of channels (queues) below the current flow director
filter rules targets.
Dave fixes a problem where a static analysis tool generates a warning
so eliminating the irrelevant check and redundant assignment for the
value of enabled_tc.
Avinash fixes an sync issue where the iWARP device open is called
before the PCI register writes are completed, so ensure the register
writes complete before exiting the setup function.
Alan fixes a bug which causes RSS to continue to work after being
disabled.
Carolyn implements a feature change which allows using ethtool to set
RDD hash options using less than four parameters if desired.
Dan Carpenter cleans up a stray unlock.
Sridhar exposes the "trust" flag to userspace via ndo_get_vf_config().
The following are changes since commit 60747ef4d173c2747bf7f0377fb22846cb422195:
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
and are available in the git repository at:
git://git.kernel.org/pub/scm/linux/kernel/git/jkirsher/next-queue 40GbE
Alan Brady (1):
i40e: fix lookup table when RSS disabled/enabled
Anjali Singhai Jain (1):
i40e: Fix a bug where a client close can be called before an open is
complete
Avinash Dayanand (2):
i40e: Force register writes to mitigate sync issues with iwarp VF
driver
i40e: Don't notify client of VF reset during VF creation
Bimmy Pujari (1):
i40e/i40evf-Bump version from 1.6.11 to 1.6.12
Carolyn Wyborny (1):
i40e: Allow RSS Hash set with less than four parameters
Catherine Sullivan (2):
i40e/i40evf: Reset VLAN filter count when resetting
i40e: reset RX csum error stat with other pf stats
Dan Carpenter (1):
i40e: remove a stray unlock
Dave Ertman (1):
i40e: Fix static analysis tool warning
Jacob Keller (2):
i40evf: add missing rtnl_lock() around i40evf_set_interrupt_capability
i40e: don't allow reduction of channels below active FD rules
Mitch Williams (1):
i40e: fix memory leak
Sridhar Samudrala (1):
i40e: Expose 'trust' flag to userspace via ndo_get_vf_config.
Wei Yongjun (1):
i40e: Use list_move instead of list_del/list_add
drivers/net/ethernet/intel/i40e/i40e.h | 3 -
drivers/net/ethernet/intel/i40e/i40e_client.c | 9 +-
drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 232 ++++++++++++++-------
drivers/net/ethernet/intel/i40e/i40e_main.c | 35 +++-
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 10 +-
drivers/net/ethernet/intel/i40evf/i40evf_main.c | 4 +-
6 files changed, 201 insertions(+), 92 deletions(-)
--
2.7.4
From: Jeff Kirsher <hidden> Date: 2016-08-19 00:48:33
From: Dave Ertman <david.m.ertman@intel.com>
This patch fixes a problem where a static analysis tool generates
a warning for "INVARIANT_CONDITION: Expression 'enabled_tc' used
in the condition always yields the same result."
Without this patch, the driver will not pass the static analysis
tool checks without generating warnings.
This patch fixes the problem by eliminating the irrelevant check
and redundant assignment for the value of enabled_tc.
Change-ID: Ia7d44cb050f507df7de333e96369d322e08bf408
Signed-off-by: Dave Ertman <david.m.ertman@intel.com>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_main.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
@@ -4635,8 +4635,6 @@ static u8 i40e_pf_get_num_tc(struct i40e_pf *pf)elsereturn1;/* Only TC0 */-/* At least have TC0 */-enabled_tc=(enabled_tc?enabled_tc:0x1);for(i=0;i<I40E_MAX_TRAFFIC_CLASS;i++){if(enabled_tc&BIT(i))num_tc++;
From: Jeff Kirsher <hidden> Date: 2016-08-19 00:48:35
From: Dan Carpenter <redacted>
We shifted the locking around a bit but forgot to delete this unlock so
now it can unlock twice.
Fixes: cd3be169a5ff ('i40e: Move the mutex lock in i40e_client_unregister')
Signed-off-by: Dan Carpenter <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_client.c | 1 -
1 file changed, 1 deletion(-)
@@ -992,7 +992,6 @@ int i40e_unregister_client(struct i40e_client *client)if(!i40e_client_is_registered(client)){pr_info("i40e: Client %s has not been registered\n",client->name);-mutex_unlock(&i40e_client_mutex);ret=-ENODEV;gotoout;}
From: Jeff Kirsher <hidden> Date: 2016-08-19 00:49:58
From: Jacob Keller <jacob.e.keller@intel.com>
If a driver is unable to maintain all current user supplied settings
from ethtool (or other sources), it is not ok for a user request to
succeed and silently trample over previous configuration.
To that end, if you change the number of channels, it must not be
allowed to reduce the number of channels (queues) below the current
flow director filter rules targets. In this case, return -EINVAL when
a request to reduce the number of channels would do so. In addition
log a warning to the kernel buffer explaining why we failed, and report
the rules which prevent us from lowering the number of channels.
Change-ID: If41464d63d7aab11cedf09e4f3aa1a69e21ffd88
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 24 ++++++++++++++++++++++++
1 file changed, 24 insertions(+)
@@ -2744,11 +2744,15 @@ static void i40e_get_channels(struct net_device *dev,staticinti40e_set_channels(structnet_device*dev,structethtool_channels*ch){+constu8drop=I40E_FILTER_PROGRAM_DESC_DEST_DROP_PACKET;structi40e_netdev_priv*np=netdev_priv(dev);unsignedintcount=ch->combined_count;structi40e_vsi*vsi=np->vsi;structi40e_pf*pf=vsi->back;+structi40e_fdir_filter*rule;+structhlist_node*node2;intnew_count;+interr=0;/* We do not support setting channels for any other VSI at present */if(vsi->type!=I40E_VSI_MAIN)
@@ -2766,6 +2770,26 @@ static int i40e_set_channels(struct net_device *dev,if(count>i40e_max_channels(vsi))return-EINVAL;+/* verify that the number of channels does not invalidate any current+*flowdirectorrules+*/+hlist_for_each_entry_safe(rule,node2,+&pf->fdir_filter_list,fdir_node){+if(rule->dest_ctl!=drop&&count<=rule->q_index){+dev_warn(&pf->pdev->dev,+"Existing user defined filter %d assigns flow to queue %d\n",+rule->fd_id,rule->q_index);+err=-EINVAL;+}+}++if(err){+dev_err(&pf->pdev->dev,+"Existing filter rules must be deleted to reduce combined channel count to %d\n",+count);+returnerr;+}+/* update feature limits from largest to smallest supported values *//* TODO: Flow director limit, DCB etc */
@@ -662,8 +662,7 @@ static int i40e_client_release(struct i40e_client *client)client->name,pf->hw.pf_id);}/* delete the client instance from the list */-list_del(&cdev->list);-list_add(&cdev->list,&cdevs_tmp);+list_move(&cdev->list,&cdevs_tmp);atomic_dec(&client->ref_cnt);dev_info(&pf->pdev->dev,"Deleted client instance of Client %s\n",client->name);
From: Jeff Kirsher <hidden> Date: 2016-08-19 00:50:26
From: Carolyn Wyborny <redacted>
This patch implements a feature change which allows using ethtool to set
RSS hash opts using less than four parameters if desired.
Change-ID: I0fbb91255d81e997c456697c21ac39cc9754821b
Signed-off-by: Carolyn Wyborny <redacted>
Signed-off-by: Kiran Patil <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e.h | 3 -
drivers/net/ethernet/intel/i40e/i40e_ethtool.c | 208 +++++++++++++++----------
2 files changed, 130 insertions(+), 81 deletions(-)
@@ -586,9 +586,6 @@ struct i40e_vsi {/* VSI specific handlers */irqreturn_t(*irq_handler)(intirq,void*data);--/* current rxnfc data */-structethtool_rxnfcrxnfc;/* current rss hash opts */}____cacheline_internodealigned_in_smp;structi40e_netdev_priv{
@@ -2141,41 +2141,72 @@ static int i40e_set_per_queue_coalesce(struct net_device *netdev, u32 queue,**/staticinti40e_get_rss_hash_opts(structi40e_pf*pf,structethtool_rxnfc*cmd){+structi40e_hw*hw=&pf->hw;+u8flow_pctype=0;+u64i_set=0;+cmd->data=0;-if(pf->vsi[pf->lan_vsi]->rxnfc.data!=0){-cmd->data=pf->vsi[pf->lan_vsi]->rxnfc.data;-cmd->flow_type=pf->vsi[pf->lan_vsi]->rxnfc.flow_type;-return0;-}-/* Report default options for RSS on i40e */switch(cmd->flow_type){caseTCP_V4_FLOW:+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV4_TCP;+break;caseUDP_V4_FLOW:-cmd->data|=RXH_L4_B_0_1|RXH_L4_B_2_3;-/* fall through to add IP fields */+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV4_UDP;+break;+caseTCP_V6_FLOW:+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV6_TCP;+break;+caseUDP_V6_FLOW:+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV6_UDP;+break;caseSCTP_V4_FLOW:caseAH_ESP_V4_FLOW:caseAH_V4_FLOW:caseESP_V4_FLOW:caseIPV4_FLOW:-cmd->data|=RXH_IP_SRC|RXH_IP_DST;-break;-caseTCP_V6_FLOW:-caseUDP_V6_FLOW:-cmd->data|=RXH_L4_B_0_1|RXH_L4_B_2_3;-/* fall through to add IP fields */caseSCTP_V6_FLOW:caseAH_ESP_V6_FLOW:caseAH_V6_FLOW:caseESP_V6_FLOW:caseIPV6_FLOW:+/* Default is src/dest for IP, no matter the L4 hashing */cmd->data|=RXH_IP_SRC|RXH_IP_DST;break;default:return-EINVAL;}+/* Read flow based hash input set register */+if(flow_pctype){+i_set=(u64)i40e_read_rx_ctl(hw,I40E_GLQF_HASH_INSET(0,+flow_pctype))|+((u64)i40e_read_rx_ctl(hw,I40E_GLQF_HASH_INSET(1,+flow_pctype))<<32);+}++/* Process bits of hash input set */+if(i_set){+if(i_set&I40E_L4_SRC_MASK)+cmd->data|=RXH_L4_B_0_1;+if(i_set&I40E_L4_DST_MASK)+cmd->data|=RXH_L4_B_2_3;++if(cmd->flow_type==TCP_V4_FLOW||+cmd->flow_type==UDP_V4_FLOW){+if(i_set&I40E_L3_SRC_MASK)+cmd->data|=RXH_IP_SRC;+if(i_set&I40E_L3_DST_MASK)+cmd->data|=RXH_IP_DST;+}elseif(cmd->flow_type==TCP_V6_FLOW||+cmd->flow_type==UDP_V6_FLOW){+if(i_set&I40E_L3_V6_SRC_MASK)+cmd->data|=RXH_IP_SRC;+if(i_set&I40E_L3_V6_DST_MASK)+cmd->data|=RXH_IP_DST;+}+}+return0;}
@@ -2318,6 +2349,51 @@ static int i40e_get_rxnfc(struct net_device *netdev, struct ethtool_rxnfc *cmd,}/**+*i40e_get_rss_hash_bits-ReadRSSHashbitsfromregister+*@nfc:pointertouserrequest+*@i_setcbitscurrentlyset+*+*Returnsvalueofbitstobesetperuserrequest+**/+staticu64i40e_get_rss_hash_bits(structethtool_rxnfc*nfc,u64i_setc)+{+u64i_set=i_setc;+u64src_l3=0,dst_l3=0;++if(nfc->data&RXH_L4_B_0_1)+i_set|=I40E_L4_SRC_MASK;+else+i_set&=~I40E_L4_SRC_MASK;+if(nfc->data&RXH_L4_B_2_3)+i_set|=I40E_L4_DST_MASK;+else+i_set&=~I40E_L4_DST_MASK;++if(nfc->flow_type==TCP_V6_FLOW||nfc->flow_type==UDP_V6_FLOW){+src_l3=I40E_L3_V6_SRC_MASK;+dst_l3=I40E_L3_V6_DST_MASK;+}elseif(nfc->flow_type==TCP_V4_FLOW||+nfc->flow_type==UDP_V4_FLOW){+src_l3=I40E_L3_SRC_MASK;+dst_l3=I40E_L3_DST_MASK;+}else{+/* Any other flow type are not supported here */+returni_set;+}++if(nfc->data&RXH_IP_SRC)+i_set|=src_l3;+else+i_set&=~src_l3;+if(nfc->data&RXH_IP_DST)+i_set|=dst_l3;+else+i_set&=~dst_l3;++returni_set;+}++/***i40e_set_rss_hash_opt-Enable/DisableflowtypesforRSShash*@pf:pointertothephysicalfunctionstruct*@cmd:ethtoolrxnfccommand
@@ -2329,6 +2405,8 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)structi40e_hw*hw=&pf->hw;u64hena=(u64)i40e_read_rx_ctl(hw,I40E_PFQF_HENA(0))|((u64)i40e_read_rx_ctl(hw,I40E_PFQF_HENA(1))<<32);+u8flow_pctype=0;+u64i_set,i_setc;/* RSS does not support anything other than hashing*toqueuesonsrcanddstIPsandports
@@ -2337,75 +2415,39 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)RXH_L4_B_0_1|RXH_L4_B_2_3))return-EINVAL;-/* We need at least the IP SRC and DEST fields for hashing */-if(!(nfc->data&RXH_IP_SRC)||-!(nfc->data&RXH_IP_DST))-return-EINVAL;-switch(nfc->flow_type){caseTCP_V4_FLOW:-switch(nfc->data&(RXH_L4_B_0_1|RXH_L4_B_2_3)){-case0:-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:-return-EINVAL;-}+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV4_TCP;+if(pf->flags&I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE)+hena|=+BIT_ULL(I40E_FILTER_PCTYPE_NONF_IPV4_TCP_SYN_NO_ACK);break;caseTCP_V6_FLOW:-switch(nfc->data&(RXH_L4_B_0_1|RXH_L4_B_2_3)){-case0:-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:-return-EINVAL;-}+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV6_TCP;+if(pf->flags&I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE)+hena|=+BIT_ULL(I40E_FILTER_PCTYPE_NONF_IPV4_TCP_SYN_NO_ACK);+if(pf->flags&I40E_FLAG_MULTIPLE_TCP_UDP_RSS_PCTYPE)+hena|=+BIT_ULL(I40E_FILTER_PCTYPE_NONF_IPV6_TCP_SYN_NO_ACK);break;caseUDP_V4_FLOW:-switch(nfc->data&(RXH_L4_B_0_1|RXH_L4_B_2_3)){-case0:-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;-default:-return-EINVAL;-}+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV4_UDP;+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_FRAG_IPV4);break;caseUDP_V6_FLOW:-switch(nfc->data&(RXH_L4_B_0_1|RXH_L4_B_2_3)){-case0:-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;-default:-return-EINVAL;-}+flow_pctype=I40E_FILTER_PCTYPE_NONF_IPV6_UDP;+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_FRAG_IPV6);break;caseAH_ESP_V4_FLOW:caseAH_V4_FLOW:
@@ -2437,13 +2479,23 @@ static int i40e_set_rss_hash_opt(struct i40e_pf *pf, struct ethtool_rxnfc *nfc)return-EINVAL;}+if(flow_pctype){+i_setc=(u64)i40e_read_rx_ctl(hw,I40E_GLQF_HASH_INSET(0,+flow_pctype))|+((u64)i40e_read_rx_ctl(hw,I40E_GLQF_HASH_INSET(1,+flow_pctype))<<32);+i_set=i40e_get_rss_hash_bits(nfc,i_setc);+i40e_write_rx_ctl(hw,I40E_GLQF_HASH_INSET(0,flow_pctype),+(u32)i_set);+i40e_write_rx_ctl(hw,I40E_GLQF_HASH_INSET(1,flow_pctype),+(u32)(i_set>>32));+hena|=BIT_ULL(flow_pctype);+}+i40e_write_rx_ctl(hw,I40E_PFQF_HENA(0),(u32)hena);i40e_write_rx_ctl(hw,I40E_PFQF_HENA(1),(u32)(hena>>32));i40e_flush(hw);-/* Save setting for future output/update */-pf->vsi[pf->lan_vsi]->rxnfc=*nfc;-return0;}
From: Jeff Kirsher <hidden> Date: 2016-08-19 00:58:19
From: Jacob Keller <jacob.e.keller@intel.com>
The function calls netif_set_real_num_(tx|rx)_queues, both of which
should be done only under rntl lock. Unfortunately the
i40evf_init_task did not hold the rtnl_lock as necessary. This patch
adds the locking needed.
Change-ID: Ib72a21c3ce22b71a226b16f9bbe0f5f8cc3e849b
Signed-off-by: Jacob Keller <jacob.e.keller@intel.com>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40evf/i40evf_main.c | 2 ++
1 file changed, 2 insertions(+)
From: Jeff Kirsher <hidden> Date: 2016-08-19 01:29:50
From: Anjali Singhai Jain <redacted>
The client->open call in this path was not protected with the
client instance mutex, and hence the client->close can get initiated
before the open completes.
Change-Id: I0ed60c38868dd3f44966b6ed49a063d0e5b7edf5
Signed-off-by: Anjali Singhai Jain <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_client.c | 2 ++
1 file changed, 2 insertions(+)
@@ -541,6 +541,7 @@ void i40e_client_subtask(struct i40e_pf *pf)client->name,pf->hw.pf_id,pf->hw.bus.device,pf->hw.bus.func);+mutex_lock(&i40e_client_instance_mutex);/* Send an Open request to the client */atomic_inc(&cdev->ref_cnt);if(client->ops&&client->ops->open)
From: Jeff Kirsher <hidden> Date: 2016-08-19 01:40:38
From: Catherine Sullivan <redacted>
When we are resetting the pf stats we should also reset the RX csum
error stat.
Change-ID: I7af5ee0ec81a10f6deee1a7b8c2082ea068ef620
Signed-off-by: Catherine Sullivan <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_main.c | 1 +
1 file changed, 1 insertion(+)
From: Jeff Kirsher <hidden> Date: 2016-08-19 01:52:03
From: Avinash Dayanand <redacted>
VF goes through reset path during VF creation which happens to also
have notification of VF reset to client. Adding conditional check to
avoid wrongly notifying VF reset during VF creation.
Also changing the call order of VF enable, calling it after VF creation
rather than before.
Change-ID: I96eabd99deae746a2f0fc465194c886f196178ce
Signed-off-by: Avinash Dayanand <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
@@ -991,7 +991,9 @@ complete_reset:i40e_enable_vf_mappings(vf);set_bit(I40E_VF_STAT_ACTIVE,&vf->vf_states);clear_bit(I40E_VF_STAT_DISABLED,&vf->vf_states);-i40e_notify_client_of_vf_reset(pf,abs_vf_id);+/* Do not notify the client during VF init */+if(vf->pf->num_alloc_vfs)+i40e_notify_client_of_vf_reset(pf,abs_vf_id);vf->num_vlan=0;}/* tell the VF the reset is done */
From: Jeff Kirsher <hidden> Date: 2016-08-19 02:39:47
From: Avinash Dayanand <redacted>
This patch is a fix for the bug i.e. unable to create iwarp device
in VF. This is a sync issue and the iwarp device open is called even
before the PCI register writes are done.
Forcing the PCI register writes to happen just before it exits the
function.
Change-ID: I60c6a2c709da89e845f2764cc50ce8b7373c8c44
Signed-off-by: Avinash Dayanand <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_client.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
From: Jeff Kirsher <hidden> Date: 2016-08-19 02:46:00
From: Alan Brady <redacted>
This patch fixes the bug which causes RSS to continue to work
after being disabled. After disabling RSS, traffic would continue
to be assigned to different queues instead of falling back to a
single queue. Without this patch, attempting to disable RSS would
not work as expected. This patch fixes the bug by clearing the
lookup table used by RSS such that all traffic is assigned to a
single queue. This patch also addresses the issue of reinstating
the lookup table should RSS then be re-enabled.
Change-ID: Ib20c7c6a7e9f1f772bb787370f8a8c664796b141
Signed-off-by: Alan Brady <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_main.c | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
From: Jeff Kirsher <hidden> Date: 2016-08-19 02:46:26
From: Mitch Williams <redacted>
When we allocate memory, we must free it. It's simple courtesy.
Change-ID: Id007294096fb53344f1a8b9a0f78eddf9853c5d6
Signed-off-by: Mitch Williams <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 1 +
1 file changed, 1 insertion(+)
@@ -2318,6 +2318,7 @@ err:/* send the response back to the VF */aq_ret=i40e_vc_send_msg_to_vf(vf,I40E_VIRTCHNL_OP_GET_RSS_HENA_CAPS,aq_ret,(u8*)vrh,len);+kfree(vrh);returnaq_ret;}
From: Jeff Kirsher <hidden> Date: 2016-08-19 02:47:31
From: Sridhar Samudrala <sridhar.samudrala@intel.com>
This enables
ip -d l
to indicate if trust is on or off for VFs.
Signed-off-by: Sridhar Samudrala <sridhar.samudrala@intel.com>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 1 +
1 file changed, 1 insertion(+)
From: Jeff Kirsher <hidden> Date: 2016-08-19 03:29:32
From: Catherine Sullivan <redacted>
When we do a reset, all the VLAN filters get added again. Therefore we also
want to reset the VLAN count to 0 or we quickly run out of filters.
Change-ID: I459f26851e22204dc8b8999928ad87cde8170119
Signed-off-by: Catherine Sullivan <redacted>
Tested-by: Andrew Bowers <redacted>
Signed-off-by: Jeff Kirsher <redacted>
---
drivers/net/ethernet/intel/i40e/i40e_virtchnl_pf.c | 1 +
1 file changed, 1 insertion(+)
@@ -992,6 +992,7 @@ complete_reset:set_bit(I40E_VF_STAT_ACTIVE,&vf->vf_states);clear_bit(I40E_VF_STAT_DISABLED,&vf->vf_states);i40e_notify_client_of_vf_reset(pf,abs_vf_id);+vf->num_vlan=0;}/* tell the VF the reset is done */wr32(hw,I40E_VFGEN_RSTAT1(vf->vf_id),I40E_VFR_VFACTIVE);