Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit b9fbb62e authored by Charles Keepax's avatar Charles Keepax Committed by Samuel Ortiz
Browse files

mfd: Only unregister platform devices allocated by the mfd core



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.

Cc: stable@vger.kernel.org
Signed-off-by: default avatarCharles Keepax <ckeepax@opensource.wolfsonmicro.com>
Tested-by: default avatarPeter Tyser <ptyser@xes-inc.com>
Reviewed-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: default avatarSamuel Ortiz <sameo@linux.intel.com>
parent d511b9c3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment