lkml.org 
[lkml]   [2022]   [Mar]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 2/6] i2c: fwnode: add fwnode_find_i2c_adapter_by_node()
Le Fri, 18 Mar 2022 18:29:39 +0200,
Andy Shevchenko <andriy.shevchenko@linux.intel.com> a écrit :

> On Fri, Mar 18, 2022 at 05:00:48PM +0100, Clément Léger wrote:
> > Add fwnode_find_i2c_adapter_by_node() which allows to retrieve a i2c
> > adapter using a fwnode. Since dev_fwnode() uses the fwnode provided by
> > the of_node member of the device, this will also work for devices were
> > the of_node has been set and not the fwnode field.
>
> > + /* For ACPI device node, we do not want to match the parent */
>
> Why?
> Neither commit message nor this comment does not answer to this question.
>

Yes you are right. This is done to keep the existing behavior that is
applied by i2c_acpi_find_adapter_by_handle() which only checks the
device node and not the parent one. Using the same behavior than for DT
would add some unwanted behavior in I2C device lookup for ACPI.

--
Clément Léger,
Embedded Linux and Kernel engineer at Bootlin
https://bootlin.com

\
 
 \ /
  Last update: 2022-03-18 17:56    [W:0.089 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site