* [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID
@ 2016-03-13 1:02 Irina Tirdea
2016-03-14 15:02 ` Mika Westerberg
2016-03-21 11:54 ` Lee Jones
0 siblings, 2 replies; 3+ messages in thread
From: Irina Tirdea @ 2016-03-13 1:02 UTC (permalink / raw)
To: Lee Jones, linux-kernel
Cc: Mika Westerberg, Andy Shevchenko, Rafael J. Wysocki,
Octavian Purdila, Irina Tirdea
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
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID
2016-03-13 1:02 [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID Irina Tirdea
@ 2016-03-14 15:02 ` Mika Westerberg
2016-03-21 11:54 ` Lee Jones
1 sibling, 0 replies; 3+ messages in thread
From: Mika Westerberg @ 2016-03-14 15:02 UTC (permalink / raw)
To: Irina Tirdea
Cc: Lee Jones, linux-kernel, Andy Shevchenko, Rafael J. Wysocki,
Octavian Purdila
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>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID
2016-03-13 1:02 [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID Irina Tirdea
2016-03-14 15:02 ` Mika Westerberg
@ 2016-03-21 11:54 ` Lee Jones
1 sibling, 0 replies; 3+ messages in thread
From: Lee Jones @ 2016-03-21 11:54 UTC (permalink / raw)
To: Irina Tirdea
Cc: linux-kernel, Mika Westerberg, Andy Shevchenko,
Rafael J. Wysocki, Octavian Purdila
On Sun, 13 Mar 2016, 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>
> ---
> drivers/mfd/mfd-core.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
I've fixed the $SUBJECT line to be more consistent with the subsystem
style for you this time. Please pay more attention to that in the
future.
`git log --oneline -- $SUBSYSTEM` helps with this.
Patch applied, thanks.
> 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;
> }
--
Lee Jones
Linaro STMicroelectronics Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-03-21 11:55 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-03-13 1:02 [PATCH 1/1] mfd: core: fix ACPI child matching by _HID/_CID Irina Tirdea
2016-03-14 15:02 ` Mika Westerberg
2016-03-21 11:54 ` Lee Jones
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).