On Tue, Sep 03, 2024 at 05:56:29PM +0200, Andrew Lunn wrote: > On Tue, Sep 03, 2024 at 01:45:49PM +0300, Andy Shevchenko wrote: > > On Tue, Sep 3, 2024 at 1:20 PM Marek Behún <kabel@xxxxxxxxxx> wrote: > > > > > > Use dev_err_probe() instead of dev_err() + separate return where > > > appropriate. > > > > ... > > > > > + if (ret) > > > + return dev_err_probe(dev, ret, "Cannot set LED %pOF to software mode\n", np); > > > > Side note: Not sure how np is being used besides the messaging. If > > it's only for the messaging, I would rather see %pfw and fwnode based > > approach. > > This board has a number of Ethernet switches described in DT. Nobody > takes ACPI seriously for any sort of complex networking. So using > fwnode is probably pointless, this board will probably never be used > with anything other than DT. Although this is true, my opinion is that converting drivers to fwnode API would still have some theoretical merit. For example using the device_property_*() functions, where possible, seems nicer semantically. I think I tried it once, or at least asked Pavel if I should, and he turned me down, so I abandoned the effort. But the patch would be a very simple one. Marek