Re: [PATCH] iio: light: cm32181: return zero after writing calibscale

Jonathan Cameron <[email protected]> Sun, 2 Aug 2026 02:46:48 +0100
Newsgroups org.kernel.vger.linux-iio,org.kernel.vger.linux-kernel
Message-ID <20260802024648.48f19c30@jic23-huawei>
On Fri, 31 Jul 2026 16:11:27 +0200
Joshua Crofts <[email protected]> wrote:

> On Fri, 31 Jul 2026 17:20:48 +0400
> Giorgi Tchankvetadze <[email protected]> wrote:
> 
> > From: Giorgi Tchankvetadze <[email protected]>
> > 
> > The write_raw callback is documented to return 0 on success or a
> > negative error code.  However, the IIO_CHAN_INFO_CALIBSCALE case
> > returns 'val' (the user-supplied value) instead of 0.
> > 
> > Fix it by returning 0 on success, matching the behavior of other
> > calibscale implementations in the subsystem.
> > 
> > Fixes: 971672c0b3cc ("iio: add Capella CM32181 ambient light sensor driver.")
> > Signed-off-by: Giorgi Tchankvetadze <[email protected]>
> > ---  
> 
> LGTM.
> 
> Reviewed-by: Joshua Crofts <[email protected]>
> 


Applied to the testing branch of iio.git and marked for stable.

Thanks,

Jonathan