On Mon, Jul 13, 2020 at 9:04 AM Calvin Johnson
<calvin.john...@oss.nxp.com> wrote:
> On Sat, Jul 11, 2020 at 02:41:12PM -0700, Florian Fainelli wrote:
> > On 7/10/2020 11:55 PM, Calvin Johnson wrote:

...

> > > +   err = fwnode_property_read_u32(fwnode, "phy-channel", &addr);
> > > +   if (err)
> > > +           return ERR_PTR(err);
> > > +   if (addr < 0 || addr >= PHY_MAX_ADDR)
> >
> > Can an u32 ever be < 0?
>
> Will remove it.

Since it's harmless and we have a fix to shut the compiler up on this
kind of checks and Linus actually in favour of _seeing_ range checks
explicitly I think no need to drop, but it's up to you.


-- 
With Best Regards,
Andy Shevchenko

Reply via email to