On Mon, May 20, 2024 at 01:20:30PM +0100, Jonathan Cameron wrote: > On Sun, 19 May 2024 22:37:58 +0300 > Alisa-Dariana Roman <alisadariana@xxxxxxxxx> wrote: > > On 19.05.2024 21:03, Jonathan Cameron wrote: ... > > +static bool ad7194_validate_ain_channel(struct device *dev, u32 ain) > > +{ > > + return in_range(ain, AD7194_CH_AIN_START, AD7194_CH_AIN_NR); > > +} > > And the negation got lost here. > > Ouch :( And negation most likely should be on the caller's side. -- With Best Regards, Andy Shevchenko