From: Charles Keepax Date: Fri, 9 Nov 2012 16:15:28 +0000 (+0000) Subject: mfd: Only unregister platform devices allocated by the mfd core X-Git-Tag: v3.2.36~100 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e417ac027a2b834fe0dfc58c59e1a50828b8a577;p=pandora-kernel.git mfd: Only unregister platform devices allocated by the mfd core commit b9fbb62eb61452d728c39b2e5020739c575aac53 upstream. mfd_remove_devices would iterate over all devices sharing a parent with an mfd device regardless of whether they were allocated by the mfd core or not. This especially caused problems when the device structure was not contained within a platform_device, because to_platform_device is used on each device pointer. This patch defines a device_type for mfd devices and checks this is present from mfd_remove_devices_fn before processing the device. Signed-off-by: Charles Keepax Tested-by: Peter Tyser Reviewed-by: Mark Brown Signed-off-by: Samuel Ortiz Signed-off-by: Ben Hutchings --- Reading git-diff-tree failed