]> git.baikalelectronics.ru Git - kernel.git/commit
nvmet-tcp: fix lockdep complaint on nvmet_tcp_wq flush during queue teardown
authorSagi Grimberg <sagi@grimberg.me>
Sun, 24 Jul 2022 08:58:43 +0000 (11:58 +0300)
committerJens Axboe <axboe@kernel.dk>
Tue, 2 Aug 2022 23:22:53 +0000 (17:22 -0600)
commit0c73a3167590dcb6dc5c4d377acb0dd8eeb5b267
treed8c1ad51b8243fad91e6cd73bfc558c036ecf2a0
parenta6c9d1f906a442d0509e9fd4865750344cd4b882
nvmet-tcp: fix lockdep complaint on nvmet_tcp_wq flush during queue teardown

We probably need nvmet_tcp_wq to have MEM_RECLAIM as we are
sending/receiving for the socket from works on this workqueue.
Also this eliminates lockdep complaints:
--
[ 6174.010200] workqueue: WQ_MEM_RECLAIM
nvmet-wq:nvmet_tcp_release_queue_work [nvmet_tcp] is flushing
!WQ_MEM_RECLAIM nvmet_tcp_wq:nvmet_tcp_io_work [nvmet_tcp]
[ 6174.010216] WARNING: CPU: 20 PID: 14456 at kernel/workqueue.c:2628
check_flush_dependency+0x110/0x14c

Reported-by: Yi Zhang <yi.zhang@redhat.com>
Signed-off-by: Sagi Grimberg <sagi@grimberg.me>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
drivers/nvme/target/tcp.c