VisionFive2 Linux kernel

StarFive Tech Linux Kernel for VisionFive (JH7110) boards (mirror)

More than 9999 Commits   32 Branches   54 Tags
author: Christoph Hellwig <hch@lst.de> 2021-01-09 11:42:50 +0100 committer: Jens Axboe <axboe@kernel.dk> 2021-01-24 18:15:57 -0700 commit: 6f0d9689b670bc9f9640ff87b3f9226b7806dea2 parent: 1e0dcca9e1aa3caa1a0dc4300db1a091078fe40b
Commit Summary:
block: remove the NULL bdev check in bdev_read_only
Diffstat:
1 file changed, 0 insertions, 3 deletions
diff --git a/block/genhd.c b/block/genhd.c
index 419548e92d82..484a474648d5 100644
--- a/block/genhd.c
+++ b/block/genhd.c
@@ -1657,11 +1657,8 @@ EXPORT_SYMBOL(set_disk_ro);
 
 int bdev_read_only(struct block_device *bdev)
 {
-	if (!bdev)
-		return 0;
 	return bdev->bd_read_only;
 }
-
 EXPORT_SYMBOL(bdev_read_only);
 
 /*