Commit 346ac785 authored by Chaitanya Kulkarni's avatar Chaitanya Kulkarni Committed by Christoph Hellwig
Browse files

nvmet: remove a superfluous variable



Remove the superfluous variable "bdev" that is only used once in the
nvmet_bdev_alloc_bip() and use req->ns->bdev that is used everywhere in
the code to access the nvmet request's bdev.

Signed-off-by: default avatarChaitanya Kulkarni <chaitanya.kulkarni@wdc.com>
Signed-off-by: default avatarChristoph Hellwig <hch@lst.de>
parent f6e8bd59
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -174,11 +174,10 @@ static int nvmet_bdev_alloc_bip(struct nvmet_req *req, struct bio *bio,
{
	struct blk_integrity *bi;
	struct bio_integrity_payload *bip;
	struct block_device *bdev = req->ns->bdev;
	int rc;
	size_t resid, len;

	bi = bdev_get_integrity(bdev);
	bi = bdev_get_integrity(req->ns->bdev);
	if (unlikely(!bi)) {
		pr_err("Unable to locate bio_integrity\n");
		return -ENODEV;