[PATCH] loop: remove the unused bdev variable in loop_set_status

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Some compilers (rightly) complain that bdev is assigned to, but not used
now.

Fixes: 0384264ea8a3 ("block: pass a gendisk to bdev_disk_changed")
Reported-by: kernel test robot <lkp@xxxxxxxxx>
Signed-off-by: Christoph Hellwig <hch@xxxxxx>
---
 drivers/block/loop.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/block/loop.c b/drivers/block/loop.c
index c6e73c051790..f96f047deeba 100644
--- a/drivers/block/loop.c
+++ b/drivers/block/loop.c
@@ -1341,7 +1341,6 @@ static int
 loop_set_status(struct loop_device *lo, const struct loop_info64 *info)
 {
 	int err;
-	struct block_device *bdev;
 	kuid_t uid = current_uid();
 	int prev_lo_flags;
 	bool partscan = false;
@@ -1410,7 +1409,6 @@ loop_set_status(struct loop_device *lo, const struct loop_info64 *info)
 	if (!err && (lo->lo_flags & LO_FLAGS_PARTSCAN) &&
 	     !(prev_lo_flags & LO_FLAGS_PARTSCAN)) {
 		lo->lo_disk->flags &= ~GENHD_FL_NO_PART_SCAN;
-		bdev = lo->lo_device;
 		partscan = true;
 	}
 out_unlock:
-- 
2.30.2




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux