From: Jeff Dike Date: Sun, 6 May 2007 21:51:01 +0000 (-0700) Subject: uml: handle block device hotplug errors X-Git-Tag: v2.6.22-rc1~882 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b47d2debf229469c78af4145ee7ad35a0f21b67f;p=pandora-kernel.git uml: handle block device hotplug errors If a disk fails to open, i.e. its host file doesn't exist, it won't be removable because the hot-unplug code checks the existence of its gendisk. This won't exist because it is only allocated for successfully opened disks. Thus, a typo on the command line can result in a unusable and unfixable disk. This is fixed by freeing the gendisk if it's there, but not letting that affect the removal. Signed-off-by: Jeff Dike Cc: Paolo 'Blaisorblade' Giarrusso Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- Reading git-diff-tree failed