NVMe: nvme_submit_async_admin_req() must use atomic rq allocation
authorJens Axboe <axboe@fb.com>
Tue, 18 Nov 2014 15:21:18 +0000 (08:21 -0700)
committerJens Axboe <axboe@fb.com>
Tue, 18 Nov 2014 15:21:18 +0000 (08:21 -0700)
We are called for async event notification issues, and the
nvmeq lock is already held. If we fail the request allocation,
we'll just retry next time.

Reported-by: Julia Lawall <julia.lawall@lip6.fr>
Signed-off-by: Jens Axboe <axboe@fb.com>
drivers/block/nvme-core.c

index bbac17f29fe74ef9b162da6fa2eac82503dd89e0..fb4b205317c68c369a8a8dd94f63e7314c6714b8 100644 (file)
@@ -825,7 +825,7 @@ static int nvme_submit_async_admin_req(struct nvme_dev *dev)
        struct nvme_cmd_info *cmd_info;
        struct request *req;
 
-       req = blk_mq_alloc_request(dev->admin_q, WRITE, GFP_KERNEL, false);
+       req = blk_mq_alloc_request(dev->admin_q, WRITE, GFP_ATOMIC, false);
        if (IS_ERR(req))
                return PTR_ERR(req);