From: Jonathan Brassow Date: Wed, 27 Jul 2011 01:00:37 +0000 (+1000) Subject: MD: generate an event when array sync is complete X-Git-Tag: Ubuntu-5.0.0-8.9~18049^2~39 X-Git-Url: https://git.proxmox.com/?a=commitdiff_plain;h=768e587e18c1c4ce0403b9532115752189422408;p=mirror_ubuntu-disco-kernel.git MD: generate an event when array sync is complete This patch causes MD to generate an event (for device-mapper) when the synchronization thread is reaped. This is expected behavior for device-mapper. Signed-off-by: Jonathan Brassow Signed-off-by: NeilBrown --- diff --git a/drivers/md/md.c b/drivers/md/md.c index 2a3205053b2a..7caa096d02f6 100644 --- a/drivers/md/md.c +++ b/drivers/md/md.c @@ -7130,6 +7130,8 @@ static void reap_sync_thread(mddev_t *mddev) set_bit(MD_RECOVERY_NEEDED, &mddev->recovery); sysfs_notify_dirent_safe(mddev->sysfs_action); md_new_event(mddev); + if (mddev->event_work.func) + queue_work(md_misc_wq, &mddev->event_work); } /*