diff options
author | Jonathan Brassow <jbrassow@redhat.com> | 2012-05-22 13:55:31 +1000 |
---|---|---|
committer | NeilBrown <neilb@suse.de> | 2012-05-22 13:55:31 +1000 |
commit | c32fb9e7ecee25a5b6a45bf968dfef76f323e185 (patch) | |
tree | 5de381a4d0c926c480d0e7244975a81450f8ecce | |
parent | 81f382f9e0b25ef56b1c0283c900b86b91a5e4c7 (diff) | |
download | linux-c32fb9e7ecee25a5b6a45bf968dfef76f323e185.tar.bz2 |
DM RAID: Use md_error() in place of simply setting Faulty bit
When encountering an error while reading the superblock, call md_error.
We are currently setting the 'Faulty' bit on one of the array devices when an
error is encountered while reading the superblock of a dm-raid array. We should
be calling md_error(), as it handles the error more completely.
Signed-off-by: Jonathan Brassow <jbrassow@redhat.com>
Signed-off-by: NeilBrown <neilb@suse.de>
-rw-r--r-- | drivers/md/dm-raid.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/dm-raid.c b/drivers/md/dm-raid.c index f1797c4f09c4..017c34d78d61 100644 --- a/drivers/md/dm-raid.c +++ b/drivers/md/dm-raid.c @@ -603,7 +603,7 @@ static int read_disk_sb(struct md_rdev *rdev, int size) if (!sync_page_io(rdev, 0, size, rdev->sb_page, READ, 1)) { DMERR("Failed to read superblock of device at position %d", rdev->raid_disk); - set_bit(Faulty, &rdev->flags); + md_error(rdev->mddev, rdev); return -EINVAL; } |