Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1356575 > unrolled thread

[PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID

Started byIrina Tirdea <irina.tirdea@intel.com>
First post2016-03-13 02:10 +0100
Last post2016-03-14 16:10 +0100
Articles 2 — 2 participants

Back to article view | Back to linux.kernel


Contents

  [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID Irina Tirdea <irina.tirdea@intel.com> - 2016-03-13 02:10 +0100
    Re: [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID Mika Westerberg <mika.westerberg@linux.intel.com> - 2016-03-14 16:10 +0100

#1356575 — [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID

FromIrina Tirdea <irina.tirdea@intel.com>
Date2016-03-13 02:10 +0100
Subject[PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID
Message-ID<rc2HF-6xE-13@gated-at.bofh.it>
If MDF child devices have separate ACPI nodes identified
by _HID/_CID, they will not be assigned the intended
ACPI companion.

acpi_match_device_ids will return 0 if a the child device
matches the _HID/_CID, so this patch changes the matching
condition to check for 0 on success.

Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>
---
 drivers/mfd/mfd-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mfd/mfd-core.c b/drivers/mfd/mfd-core.c
index 88bd1b1..409da01 100644
--- a/drivers/mfd/mfd-core.c
+++ b/drivers/mfd/mfd-core.c
@@ -107,7 +107,7 @@ static void mfd_acpi_add_device(const struct mfd_cell *cell,
 
 			strlcpy(ids[0].id, match->pnpid, sizeof(ids[0].id));
 			list_for_each_entry(child, &parent->children, node) {
-				if (acpi_match_device_ids(child, ids)) {
+				if (!acpi_match_device_ids(child, ids)) {
 					adev = child;
 					break;
 				}
-- 
1.9.1

[toc] | [next] | [standalone]


#1357340

FromMika Westerberg <mika.westerberg@linux.intel.com>
Date2016-03-14 16:10 +0100
Message-ID<rcCi6-5r0-19@gated-at.bofh.it>
In reply to#1356575
On Sun, Mar 13, 2016 at 03:02:58AM +0200, Irina Tirdea wrote:
> If MDF child devices have separate ACPI nodes identified
> by _HID/_CID, they will not be assigned the intended
> ACPI companion.
> 
> acpi_match_device_ids will return 0 if a the child device
> matches the _HID/_CID, so this patch changes the matching
> condition to check for 0 on success.
> 
> Signed-off-by: Irina Tirdea <irina.tirdea@intel.com>

Good catch!

Acked-by: Mika Westerberg <mika.westeberg@linux.intel.com>

[toc] | [prev] | [standalone]


Back to top | Article view | linux.kernel


csiph-web