From: NeilBrown Date: Thu, 9 Nov 2006 01:44:47 +0000 (-0800) Subject: [PATCH] md: change ONLINE/OFFLINE events to a single CHANGE event X-Git-Tag: v2.6.19-rc6~56 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=2f4713036114dd13d1f4fe433b7f236250b65f5a;p=linux-2.6-omap-h63xx.git [PATCH] md: change ONLINE/OFFLINE events to a single CHANGE event It turns out that CHANGE is preferred to ONLINE/OFFLINE for various reasons (not least of which being that udev understands it already). So remove the recently added KOBJ_OFFLINE (no-one is likely to care anyway) and change the ONLINE to a CHANGE event Cc: Kay Sievers Signed-off-by: Neil Brown Cc: Greg KH Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/md/md.c b/drivers/md/md.c index d1113560440..ae50a2419cc 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -3200,7 +3200,7 @@ static int do_md_run(mddev_t * mddev) mddev->changed = 1; md_new_event(mddev); - kobject_uevent(&mddev->gendisk->kobj, KOBJ_ONLINE); + kobject_uevent(&mddev->gendisk->kobj, KOBJ_CHANGE); return 0; } @@ -3314,7 +3314,6 @@ static int do_md_stop(mddev_t * mddev, int mode) module_put(mddev->pers->owner); mddev->pers = NULL; - kobject_uevent(&mddev->gendisk->kobj, KOBJ_OFFLINE); if (mddev->ro) mddev->ro = 0; }