]> git.baikalelectronics.ru Git - kernel.git/commit
nvme-tcp: fix a NULL deref when an admin connect times out
authorSagi Grimberg <sagi@grimberg.me>
Wed, 24 Apr 2019 18:53:17 +0000 (11:53 -0700)
committerChristoph Hellwig <hch@lst.de>
Thu, 25 Apr 2019 14:51:37 +0000 (16:51 +0200)
commit7cc2f59a04d1d8c1ecd644dabe4c8afc4bb66e7e
treec556c34ee4aa676beacbff402f7e11ecf54f7cfb
parenta1a4f67cc21945bfbaa9efda588598d42db3c020
nvme-tcp: fix a NULL deref when an admin connect times out

If we timeout the admin startup sequence we might not yet have
an I/O tagset allocated which causes the teardown sequence to crash.
Make nvme_tcp_teardown_io_queues safe by not iterating inflight tags
if the tagset wasn't allocated.

Fixes: fabb87d8c4e1 ("nvme-tcp: fix timeout handler")
Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
drivers/nvme/host/tcp.c