]> git.baikalelectronics.ru Git - kernel.git/commit
net/smc: do not schedule tx_work in SMC_CLOSED state
authorUrsula Braun <ubraun@linux.ibm.com>
Fri, 2 Aug 2019 08:16:38 +0000 (10:16 +0200)
committerDavid S. Miller <davem@davemloft.net>
Mon, 5 Aug 2019 20:23:05 +0000 (13:23 -0700)
commitfc1a9b43d462d6ec129126fe1ced1f57db98e38b
treee706eb99a727072a7ee0dc19ddc0acba2018a429
parent498f3979cf0fc4265c035d46d5f0fc96c4a87f72
net/smc: do not schedule tx_work in SMC_CLOSED state

The setsockopts options TCP_NODELAY and TCP_CORK may schedule the
tx worker. Make sure the socket is not yet moved into SMC_CLOSED
state (for instance by a shutdown SHUT_RDWR call).

Reported-by: syzbot+92209502e7aab127c75f@syzkaller.appspotmail.com
Reported-by: syzbot+b972214bb803a343f4fe@syzkaller.appspotmail.com
Fixes: fe67f6d0cc871 ("net/smc: sockopts TCP_NODELAY and TCP_CORK")
Signed-off-by: Ursula Braun <ubraun@linux.ibm.com>
Signed-off-by: Karsten Graul <kgraul@linux.ibm.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/smc/af_smc.c