summaryrefslogtreecommitdiffstats
path: root/drivers/nvme/host/tcp.c
diff options
context:
space:
mode:
authorSagi Grimberg <sagi@grimberg.me>2020-04-30 13:59:32 -0700
committerJens Axboe <axboe@kernel.dk>2020-05-09 16:18:36 -0600
commit386e5e6e1aa90b479fcf0467935922df8524393d (patch)
treeac7e75c92bf5b570f3c0f413b28ce967676c2661 /drivers/nvme/host/tcp.c
parent2a5bcfdd41d68559567cec3c124a75e093506cc1 (diff)
downloadlinux-386e5e6e1aa90b479fcf0467935922df8524393d.tar.bz2
nvme-tcp: use bh_lock in data_ready
data_ready may be invoked from send context or from softirq, so need bh locking for that. Fixes: 3f2304f8c6d6 ("nvme-tcp: add NVMe over TCP host driver") Signed-off-by: Sagi Grimberg <sagi@grimberg.me> Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/nvme/host/tcp.c')
-rw-r--r--drivers/nvme/host/tcp.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/nvme/host/tcp.c b/drivers/nvme/host/tcp.c
index c15a92163c1f..4862fa962011 100644
--- a/drivers/nvme/host/tcp.c
+++ b/drivers/nvme/host/tcp.c
@@ -794,11 +794,11 @@ static void nvme_tcp_data_ready(struct sock *sk)
{
struct nvme_tcp_queue *queue;
- read_lock(&sk->sk_callback_lock);
+ read_lock_bh(&sk->sk_callback_lock);
queue = sk->sk_user_data;
if (likely(queue && queue->rd_enabled))
queue_work_on(queue->io_cpu, nvme_tcp_wq, &queue->io_work);
- read_unlock(&sk->sk_callback_lock);
+ read_unlock_bh(&sk->sk_callback_lock);
}
static void nvme_tcp_write_space(struct sock *sk)