Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Rafael J. Wysocki
On Fri, Jan 22, 2021 at 7:13 PM Rafael J. Wysocki wrote: > > On Fri, Jan 22, 2021 at 4:46 PM Calvin Johnson > wrote: > > > > Using fwnode_get_id(), get the reg property value for DT node > > or get the _ADR object value for ACPI node. This is not accurate AFAICS, because if the "reg" property is

Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Rafael J. Wysocki
On Fri, Jan 22, 2021 at 7:11 PM Rafael J. Wysocki wrote: > > On Fri, Jan 22, 2021 at 6:12 PM Andy Shevchenko > wrote: > > > > On Fri, Jan 22, 2021 at 05:40:41PM +0100, Rafael J. Wysocki wrote: > > > On Fri, Jan 22, 2021 at 4:46 PM Calvin Johnson > > > wrote: > > > > > > > > Using fwnode_get_id()

Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Rafael J. Wysocki
On Fri, Jan 22, 2021 at 4:46 PM Calvin Johnson wrote: > > Using fwnode_get_id(), get the reg property value for DT node > or get the _ADR object value for ACPI node. > > Signed-off-by: Calvin Johnson > --- > > Changes in v4: > - Improve code structure to handle all cases > > Changes in v3: > - Mo

Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Rafael J. Wysocki
On Fri, Jan 22, 2021 at 6:12 PM Andy Shevchenko wrote: > > On Fri, Jan 22, 2021 at 05:40:41PM +0100, Rafael J. Wysocki wrote: > > On Fri, Jan 22, 2021 at 4:46 PM Calvin Johnson > > wrote: > > > > > > Using fwnode_get_id(), get the reg property value for DT node > > > or get the _ADR object value

Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Andy Shevchenko
On Fri, Jan 22, 2021 at 05:40:41PM +0100, Rafael J. Wysocki wrote: > On Fri, Jan 22, 2021 at 4:46 PM Calvin Johnson > wrote: > > > > Using fwnode_get_id(), get the reg property value for DT node > > or get the _ADR object value for ACPI node. > > So I'm not really sure if this is going to be gene

Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Rafael J. Wysocki
On Fri, Jan 22, 2021 at 4:46 PM Calvin Johnson wrote: > > Using fwnode_get_id(), get the reg property value for DT node > or get the _ADR object value for ACPI node. So I'm not really sure if this is going to be generically useful. First of all, the meaning of the _ADR return value is specific t

Re: [net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Andy Shevchenko
On Fri, Jan 22, 2021 at 09:12:54PM +0530, Calvin Johnson wrote: > Using fwnode_get_id(), get the reg property value for DT node > or get the _ADR object value for ACPI node. ... > +/** > + * fwnode_get_id - Get the id of a fwnode. > + * @fwnode: firmware node > + * @id: id of the fwnode > + * > +

[net-next PATCH v4 09/15] device property: Introduce fwnode_get_id()

2021-01-22 Thread Calvin Johnson
Using fwnode_get_id(), get the reg property value for DT node or get the _ADR object value for ACPI node. Signed-off-by: Calvin Johnson --- Changes in v4: - Improve code structure to handle all cases Changes in v3: - Modified to retrieve reg property value for ACPI as well - Resolved compilatio