Commit ee7255ad authored by Anish Bhatt's avatar Anish Bhatt Committed by David S. Miller

cxgb4i : Don't block unload/cxgb4 unload when remote closes TCP connection

cxgb4i was returning wrong error and not releasing module reference if remote
end abruptly closed TCP connection. This prevents the cxgb4 network module from
being unloaded, further affecting other network drivers dependent on cxgb4

Sending to net as this affects all cxgb4 based network drivers.
Signed-off-by: default avatarAnish Bhatt <anish@chelsio.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent ffb1388a
...@@ -828,6 +828,8 @@ static void do_act_open_rpl(struct cxgbi_device *cdev, struct sk_buff *skb) ...@@ -828,6 +828,8 @@ static void do_act_open_rpl(struct cxgbi_device *cdev, struct sk_buff *skb)
if (status == CPL_ERR_RTX_NEG_ADVICE) if (status == CPL_ERR_RTX_NEG_ADVICE)
goto rel_skb; goto rel_skb;
module_put(THIS_MODULE);
if (status && status != CPL_ERR_TCAM_FULL && if (status && status != CPL_ERR_TCAM_FULL &&
status != CPL_ERR_CONN_EXIST && status != CPL_ERR_CONN_EXIST &&
status != CPL_ERR_ARP_MISS) status != CPL_ERR_ARP_MISS)
......
...@@ -816,7 +816,7 @@ static void cxgbi_inform_iscsi_conn_closing(struct cxgbi_sock *csk) ...@@ -816,7 +816,7 @@ static void cxgbi_inform_iscsi_conn_closing(struct cxgbi_sock *csk)
read_lock_bh(&csk->callback_lock); read_lock_bh(&csk->callback_lock);
if (csk->user_data) if (csk->user_data)
iscsi_conn_failure(csk->user_data, iscsi_conn_failure(csk->user_data,
ISCSI_ERR_CONN_FAILED); ISCSI_ERR_TCP_CONN_CLOSE);
read_unlock_bh(&csk->callback_lock); read_unlock_bh(&csk->callback_lock);
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment