From: Hugh Daschbach Date: Mon, 22 Mar 2010 17:36:37 +0000 (-0700) Subject: Driver core: Protect device shutdown from hot unplug events. X-Git-Tag: v2.6.35-rc1~459^2~22 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=6245838fe4d2ce4aab52f543224f7d1212d9155c;p=pandora-kernel.git Driver core: Protect device shutdown from hot unplug events. While device_shutdown() walks through devices_kset to shutdown all devices, device unplug events may race to shutdown individual devices. Specifically, sd_shutdown(), on behalf of fc_starget_delete(), has been observed deleting devices during device_shutdown()'s list traversal. So we factor out list_for_each_entry_safe_reverse(...) in favor of while (!list_empty(...)). Signed-off-by: Hugh Daschbach Signed-off-by: Greg Kroah-Hartman --- Reading git-diff-tree failed