Re: [PATCH v3 2/3] hwmon: (emc1403) Convert to use OF bindings

From: Svyatoslav Ryhel

Date: Mon Jul 27 2026 - 04:18:32 EST


сб, 25 лип. 2026 р. о 17:23 Guenter Roeck <linux@xxxxxxxxxxxx> пише:
>
> On 7/25/26 06:24, Svyatoslav Ryhel wrote:
> > чт, 23 лип. 2026 р. о 09:28 Uwe Kleine-König
> > <u.kleine-koenig@xxxxxxxxxxxx> пише:
> >>
> >> Hello,
> >>
> >> On Tue, Jul 21, 2026 at 12:59:34PM +0300, Svyatoslav Ryhel wrote:
> >>> From: Jonas Schwöbel <jonasschwoebel@xxxxxxxx>
> >>>
> >>> Add OF match compatible table to be able to use this driver with Device
> >>> Trees.
> >>>
> >>> Signed-off-by: Jonas Schwöbel <jonasschwoebel@xxxxxxxx>
> >>> Signed-off-by: Svyatoslav Ryhel <clamor95@xxxxxxxxx>
> >>> Reviewed-by: Guenter Roeck <linux@xxxxxxxxxxxx>
> >>
> >> Please put your S-o-b line last.
> >>
> >
> > If S-o-b's should be chronological, then this order is correct.
> > Guenter added his reviewed-by after I have added my signed-off-by.
> >
>
> That refers to S-o-B, not to Reviewed-by: trailers.
>
> Do we really have to argue about something like this ?

I am not arguing, looking for answers.

> Do I have to mandate the order of non-SoB trailers for this subsystem ?
>

That actually may be a decent idea. In you have this stated strictly
for subsystem or have a consensus on kernel level then you can just
point a link to a documentation. Might simplify your maintainer work
;)

> Guenter
>
> >>> ---
> >>> drivers/hwmon/emc1403.c | 16 ++++++++++++++--
> >>> 1 file changed, 14 insertions(+), 2 deletions(-)
> >>>
> >>> diff --git a/drivers/hwmon/emc1403.c b/drivers/hwmon/emc1403.c
> >>> index cd753b38709f2..b7ab6069ec7b1 100644
> >>> --- a/drivers/hwmon/emc1403.c
> >>> +++ b/drivers/hwmon/emc1403.c
> >>> @@ -16,6 +16,7 @@
> >>> #include <linux/hwmon.h>
> >>> #include <linux/hwmon-sysfs.h>
> >>> #include <linux/err.h>
> >>> +#include <linux/mod_devicetable.h>
> >>
> >> Don't add <linux/mod_devicetable.h> please. struct of_device_id is also
> >> provided by <linux/i2c.h> so adding <linux/mod_devicetable.h> isn't
> >> needed.
> >>
> >>> #include <linux/sysfs.h>
> >>> #include <linux/regmap.h>
> >>> #include <linux/util_macros.h>
> >>> [...]
> >>> @@ -682,10 +683,21 @@ static const unsigned short emc1403_address_list[] = {
> >>> 0x18, 0x1c, 0x29, 0x3c, 0x4c, 0x4d, 0x5c, I2C_CLIENT_END
> >>> };
> >>>
> >>> +static const struct of_device_id emc1403_of_match[] = {
> >>> + { .compatible = "smsc,emc1402", .data = (void *)emc1402 },
> >>> + { .compatible = "smsc,emc1403", .data = (void *)emc1403 },
> >>> + { .compatible = "smsc,emc1404", .data = (void *)emc1404 },
> >>> + { .compatible = "smsc,emc1428", .data = (void *)emc1428 },
> >>> + { }
> >>> +
> >>
> >> Unusual empty line here.
> >>
> >>> +};
> >>> +MODULE_DEVICE_TABLE(of, emc1403_of_match);
> >>> +
> >>
> >> Best regards
> >> Uwe
>