[PATCH] md: Remove some code that can sleep from under a spinlock

And remove the comments that were put in inplace of a fix too....

Signed-off-by: Neil Brown <neilb@suse.de>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
NeilBrown 2006-03-31 02:32:02 -08:00 committed by Linus Torvalds
parent 6b1117d505
commit 926ce2d8a7

View file

@ -215,13 +215,11 @@ static void mddev_put(mddev_t *mddev)
return; return;
if (!mddev->raid_disks && list_empty(&mddev->disks)) { if (!mddev->raid_disks && list_empty(&mddev->disks)) {
list_del(&mddev->all_mddevs); list_del(&mddev->all_mddevs);
/* that blocks */ spin_unlock(&all_mddevs_lock);
blk_cleanup_queue(mddev->queue); blk_cleanup_queue(mddev->queue);
/* that also blocks */
kobject_unregister(&mddev->kobj); kobject_unregister(&mddev->kobj);
/* result blows... */ } else
} spin_unlock(&all_mddevs_lock);
spin_unlock(&all_mddevs_lock);
} }
static mddev_t * mddev_find(dev_t unit) static mddev_t * mddev_find(dev_t unit)