diff --git a/drivers/md/md.c b/drivers/md/md.c index 7c0f6107865383bd64ee1be771f4ffa2d1ff376d..21da0c48f6c21e88eda425ef281a7af617a1b4f2 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -6143,7 +6143,7 @@ static int restart_array(struct mddev *mddev) if (test_bit(Journal, &rdev->flags) && !test_bit(Faulty, &rdev->flags)) has_journal = true; - if (bdev_read_only(rdev->bdev)) + if (rdev_read_only(rdev)) has_readonly = true; } rcu_read_unlock();