Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

mfd: Check for ACPI conflicts

For ACPI based systems, we should check for ACPI conflicts when adding the
platform devices. The test will always succeed for non ACPI platforms.

Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>

+5
+5
drivers/mfd/mfd-core.c
··· 13 13 14 14 #include <linux/kernel.h> 15 15 #include <linux/platform_device.h> 16 + #include <linux/acpi.h> 16 17 #include <linux/mfd/core.h> 17 18 18 19 static int mfd_add_device(struct device *parent, int id, ··· 63 62 res[r].start = cell->resources[r].start; 64 63 res[r].end = cell->resources[r].end; 65 64 } 65 + 66 + ret = acpi_check_resource_conflict(res); 67 + if (ret) 68 + goto fail_res; 66 69 } 67 70 68 71 platform_device_add_resources(pdev, res, cell->num_resources);