Re: [PATCH] iio: ad5770r: make devicetree property reading consistent

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Aug 13, 2021 at 10:47 AM Sa, Nuno <Nuno.Sa@xxxxxxxxxx> wrote:
> > From: Rob Herring <robh+dt@xxxxxxxxxx>
> > Sent: Thursday, August 12, 2021 5:11 PM
> > On Thu, Aug 12, 2021 at 3:14 AM Sa, Nuno <Nuno.Sa@xxxxxxxxxx>
> > wrote:

...

> > > Could you give your input on this one?
> >
> > There's no context, but I'm assuming this is in channel nodes. Keep
>
> Sorry about that. Your assumption is correct, the binding is for a channel
> node [1]. The driver just get's it as 'num' [2] which is not consistent.
> Naively, I just though changing the driver to use reg would be enough
> but Andy nicely raised the question of someone being already relying
> on 'num'...
>
> > the binding 'reg' and make the driver support both if needed.
> > Considering the author of the binding also changed the binding from
> > num to reg shortly after adding the binding, I don't think 'num'
> > support is needed. If someone used 'num' and didn't run validation,
> > well, that's their problem.
> >
>
> So I guess the solution here is just to change the driver to support both
> reg and num.

As far as I got Rob's answer, if the binding never had the 'num',
dropping it from the driver is what we want now (actually your
original patch) and users, who are 'too much clever' :-) should have
had run validation for their DTs before production.

Taking this into account, I'm fine with the patch (but update a commit
message to summarize this discussion)
Reviewed-by: Andy Shevchenko <andy.shevchenko@xxxxxxxxx>

-- 
With Best Regards,
Andy Shevchenko



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux