aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/nvme/target
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2021-01-26 15:52:35 +0100
committerJens Axboe <axboe@kernel.dk>2021-01-27 09:51:48 -0700
commitc6bf3f0e25f4c0f0ecce6cf8d1c589bd9d74d3cf (patch)
tree75b4523f9dc5725dcef0150a487d27303058b259 /drivers/nvme/target
parentblock: split bio_kmalloc from bio_alloc_bioset (diff)
downloadlinux-dev-c6bf3f0e25f4c0f0ecce6cf8d1c589bd9d74d3cf.tar.xz
linux-dev-c6bf3f0e25f4c0f0ecce6cf8d1c589bd9d74d3cf.zip
block: use an on-stack bio in blkdev_issue_flush
There is no point in allocating memory for a synchronous flush. Signed-off-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Johannes Thumshirn <johannes.thumshirn@wdc.com> Reviewed-by: Chaitanya Kulkarni <chaitanya.kulkarni@wdc.com> Acked-by: Damien Le Moal <damien.lemoal@wdc.com> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'drivers/nvme/target')
-rw-r--r--drivers/nvme/target/io-cmd-bdev.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nvme/target/io-cmd-bdev.c b/drivers/nvme/target/io-cmd-bdev.c
index 125dde3f410e..bf6e0ac9ad28 100644
--- a/drivers/nvme/target/io-cmd-bdev.c
+++ b/drivers/nvme/target/io-cmd-bdev.c
@@ -333,7 +333,7 @@ static void nvmet_bdev_execute_flush(struct nvmet_req *req)
u16 nvmet_bdev_flush(struct nvmet_req *req)
{
- if (blkdev_issue_flush(req->ns->bdev, GFP_KERNEL))
+ if (blkdev_issue_flush(req->ns->bdev))
return NVME_SC_INTERNAL | NVME_SC_DNR;
return 0;
}