From: Jean Delvare Date: Sat, 18 Feb 2012 16:54:23 +0000 (+0100) Subject: mfd: Fix ACPI conflict check X-Git-Tag: firefly_0821_release~3680^2~3227^2~56 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=855cc454341c6ca1212bf86939f2f2a51ab54e18;p=firefly-linux-kernel-4.4.55.git mfd: Fix ACPI conflict check The code is currently always checking the first resource of every device only (several times.) This has been broken since the ACPI check was added in February 2010 in commit 91fedede0338eb6203cdd618d8ece873fdb7c22c. Fix the check to run on each resource individually, once. Signed-off-by: Jean Delvare Cc: stable@vger.kernel.org Signed-off-by: Samuel Ortiz --- diff --git a/drivers/mfd/mfd-core.c b/drivers/mfd/mfd-core.c index 9fc05b9b0bab..ffc3d48676ae 100644 --- a/drivers/mfd/mfd-core.c +++ b/drivers/mfd/mfd-core.c @@ -123,7 +123,7 @@ static int mfd_add_device(struct device *parent, int id, } if (!cell->ignore_resource_conflicts) { - ret = acpi_check_resource_conflict(res); + ret = acpi_check_resource_conflict(&res[r]); if (ret) goto fail_res; }