summaryrefslogtreecommitdiffstats
path: root/drivers/md/raid10.c
diff options
context:
space:
mode:
authorJonathan Brassow <jbrassow@redhat.com>2012-10-11 13:38:58 +1100
committerNeilBrown <neilb@suse.de>2012-10-11 13:38:58 +1100
commit2863b9eb44787adecba4f977d71d7fd876805b1c (patch)
treee8d5417df70e9ade3b8e021426db6f22b4067b95 /drivers/md/raid10.c
parent1ca69c4bc4b1ef889861db39f325901eadbf9497 (diff)
downloadop-kernel-dev-2863b9eb44787adecba4f977d71d7fd876805b1c.zip
op-kernel-dev-2863b9eb44787adecba4f977d71d7fd876805b1c.tar.gz
MD RAID10: Prep for DM RAID10 device replacement capability
MD RAID10: Fix a couple potential kernel panics if RAID10 is used by dm-raid When device-mapper uses the RAID10 personality through dm-raid.c, there is no 'gendisk' structure in mddev and some sysfs information is also not populated. This patch avoids touching those non-existent structures. Signed-off-by: Jonathan Brassow <jbrassow@rehdat.com> Signed-off-by: NeilBrown <neilb@suse.de>
Diffstat (limited to 'drivers/md/raid10.c')
-rw-r--r--drivers/md/raid10.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/md/raid10.c b/drivers/md/raid10.c
index 5486060..fb5bd60 100644
--- a/drivers/md/raid10.c
+++ b/drivers/md/raid10.c
@@ -1694,7 +1694,7 @@ static int raid10_spare_active(struct mddev *mddev)
&& !test_bit(Faulty, &tmp->rdev->flags)
&& !test_and_set_bit(In_sync, &tmp->rdev->flags)) {
count++;
- sysfs_notify_dirent(tmp->rdev->sysfs_state);
+ sysfs_notify_dirent_safe(tmp->rdev->sysfs_state);
}
}
spin_lock_irqsave(&conf->device_lock, flags);
OpenPOWER on IntegriCloud