aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
diff options
context:
space:
mode:
authorArjun Vynipadath <arjun@chelsio.com>2018-03-15 17:34:14 +0530
committerDavid S. Miller <davem@davemloft.net>2018-03-17 17:20:03 -0400
commitd7cb44496a9bb458632cb3c18acb08949c210448 (patch)
tree5fed920cbb9414f3f2a939032735caef124c07a7 /drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
parentrds: tcp: must use spin_lock_irq* and not spin_lock_bh with rds_tcp_conn_lock (diff)
downloadlinux-dev-d7cb44496a9bb458632cb3c18acb08949c210448.tar.xz
linux-dev-d7cb44496a9bb458632cb3c18acb08949c210448.zip
cxgb4: Fix queue free path of ULD drivers
Setting sge_uld_rxq_info to NULL in free_queues_uld(). We are referencing sge_uld_rxq_info in cxgb_up(). This will fix a panic when interface is brought up after a ULDq creation failure. Fixes: 94cdb8bb993a (cxgb4: Add support for dynamic allocation of resources for ULD) Signed-off-by: Arjun Vynipadath <arjun@chelsio.com> Signed-off-by: Casey Leedom <leedom@chelsio.com> Signed-off-by: Ganesh Goudhar <ganeshgr@chelsio.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to '')
-rw-r--r--drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
index 6b5fea4532f3..2d827140a475 100644
--- a/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
+++ b/drivers/net/ethernet/chelsio/cxgb4/cxgb4_uld.c
@@ -342,6 +342,7 @@ static void free_queues_uld(struct adapter *adap, unsigned int uld_type)
{
struct sge_uld_rxq_info *rxq_info = adap->sge.uld_rxq_info[uld_type];
+ adap->sge.uld_rxq_info[uld_type] = NULL;
kfree(rxq_info->rspq_id);
kfree(rxq_info->uldrxq);
kfree(rxq_info);