summaryrefslogtreecommitdiff
path: root/net/dsa
diff options
context:
space:
mode:
authorKarsten Graul <kgraul@linux.ibm.com>2021-09-20 21:18:15 +0200
committerDavid S. Miller <davem@davemloft.net>2021-09-21 10:54:16 +0100
commita18cee4791b1123d0a6579a7c89f4b87e48abe03 (patch)
tree1d808134345a6f16a1cff315b913a36b0d3e13ee /net/dsa
parent6c90731980655280ea07ce4b21eb97457bf86286 (diff)
net/smc: fix 'workqueue leaked lock' in smc_conn_abort_work
The abort_work is scheduled when a connection was detected to be out-of-sync after a link failure. The work calls smc_conn_kill(), which calls smc_close_active_abort() and that might end up calling smc_close_cancel_work(). smc_close_cancel_work() cancels any pending close_work and tx_work but needs to release the sock_lock before and acquires the sock_lock again afterwards. So when the sock_lock was NOT acquired before then it may be held after the abort_work completes. Thats why the sock_lock is acquired before the call to smc_conn_kill() in __smc_lgr_terminate(), but this is missing in smc_conn_abort_work(). Fix that by acquiring the sock_lock first and release it after the call to smc_conn_kill(). Fixes: b286a0651e44 ("net/smc: handle incoming CDC validation message") Signed-off-by: Karsten Graul <kgraul@linux.ibm.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/dsa')
0 files changed, 0 insertions, 0 deletions