lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250831162746.7dab74c2@jic23-huawei>
Date: Sun, 31 Aug 2025 16:27:46 +0100
From: Jonathan Cameron <jic23@...nel.org>
To: Qianfeng Rong <rongqianfeng@...o.com>
Cc: Lars-Peter Clausen <lars@...afoo.de>, Michael Hennerich
 <Michael.Hennerich@...log.com>, David Lechner <dlechner@...libre.com>, Nuno
 Sá <nuno.sa@...log.com>, Andy Shevchenko <andy@...nel.org>,
 linux-iio@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] iio: dac: use int instead of u32 to store error codes

On Tue, 26 Aug 2025 18:18:25 +0800
Qianfeng Rong <rongqianfeng@...o.com> wrote:

> Use int instead of unsigned int for 'ret' variable to store negative error
> codes returned by ad5421_write_unlocked() and ad5360_write_unlocked().
> 
> Signed-off-by: Qianfeng Rong <rongqianfeng@...o.com>
This is a fix, so needs a fixes tag.

Given the two drivers were introduced in separate patches
I would suggest splitting this into two different patches so
we can call out how far to backport each one (via the appropriate
fixes tags!)

> ---
>  drivers/iio/dac/ad5360.c | 2 +-
>  drivers/iio/dac/ad5421.c | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/iio/dac/ad5360.c b/drivers/iio/dac/ad5360.c
> index a57b0a093112..8271849b1c83 100644
> --- a/drivers/iio/dac/ad5360.c
> +++ b/drivers/iio/dac/ad5360.c
> @@ -262,7 +262,7 @@ static int ad5360_update_ctrl(struct iio_dev *indio_dev, unsigned int set,
>  	unsigned int clr)
>  {
>  	struct ad5360_state *st = iio_priv(indio_dev);
> -	unsigned int ret;
> +	int ret;
>  
>  	mutex_lock(&st->lock);
>  
> diff --git a/drivers/iio/dac/ad5421.c b/drivers/iio/dac/ad5421.c
> index 1462ee640b16..d9d7031c4432 100644
> --- a/drivers/iio/dac/ad5421.c
> +++ b/drivers/iio/dac/ad5421.c
> @@ -186,7 +186,7 @@ static int ad5421_update_ctrl(struct iio_dev *indio_dev, unsigned int set,
>  	unsigned int clr)
>  {
>  	struct ad5421_state *st = iio_priv(indio_dev);
> -	unsigned int ret;
> +	int ret;
>  
>  	mutex_lock(&st->lock);
>  


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ