summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--block/bdev.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/block/bdev.c b/block/bdev.c
index dd84961bed7e..e9ada04e71be 100644
--- a/block/bdev.c
+++ b/block/bdev.c
@@ -750,14 +750,6 @@ struct block_device *blkdev_get_no_open(dev_t dev)
if (!kobject_get_unless_zero(&bdev->bd_device.kobj))
bdev = NULL;
iput(inode);
-
- if (!bdev)
- return NULL;
- if ((bdev->bd_disk->flags & GENHD_FL_HIDDEN)) {
- put_device(&bdev->bd_device);
- return NULL;
- }
-
return bdev;
}