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: <20220320133229.6026f51a@jic23-huawei>
Date:   Sun, 20 Mar 2022 13:32:29 +0000
From:   Jonathan Cameron <jic23@...nel.org>
To:     Cixi Geng <gengcixi@...il.com>
Cc:     lars@...afoo.de, robh+dt@...nel.org, orsonzhai@...il.com,
        baolin.wang7@...il.com, zhang.lyra@...il.com, lgirdwood@...il.com,
        broonie@...nel.org, yuming.zhu1@...soc.com,
        linux-iio@...r.kernel.org, devicetree@...r.kernel.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH V2 2/7] iio: adc: sc27xx: fix read big scale voltage not
 right

On Sat, 12 Mar 2022 00:46:23 +0800
Cixi Geng <gengcixi@...il.com> wrote:

> From: Cixi Geng <cixi.geng1@...soc.com>
> 
> Fix wrong configuration value of SC27XX_ADC_SCALE_MASK and
> SC27XX_ADC_SCALE_SHIFT by spec documetation.
> 
> Signed-off-by: Yuming Zhu <yuming.zhu1@...soc.com>
> Signed-off-by: Cixi Geng <cixi.geng1@...soc.com>
> 
No blank lines in a tag block (they break people's scripts)
Also, if this is a fix, I'd expect a fixes tag.

> Reviewed-by: Baolin Wang <baolin.wang7@...il.com>
> ---
>  drivers/iio/adc/sc27xx_adc.c | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/iio/adc/sc27xx_adc.c b/drivers/iio/adc/sc27xx_adc.c
> index 00098caf6d9e..aee076c8e2b1 100644
> --- a/drivers/iio/adc/sc27xx_adc.c
> +++ b/drivers/iio/adc/sc27xx_adc.c
> @@ -36,8 +36,8 @@
>  
>  /* Bits and mask definition for SC27XX_ADC_CH_CFG register */
>  #define SC27XX_ADC_CHN_ID_MASK		GENMASK(4, 0)
> -#define SC27XX_ADC_SCALE_MASK		GENMASK(10, 8)
> -#define SC27XX_ADC_SCALE_SHIFT		8
> +#define SC27XX_ADC_SCALE_MASK		GENMASK(10, 9)
> +#define SC27XX_ADC_SCALE_SHIFT		9

This driver would benefit from use of FIELD_GET() / FIELD_PREP()
but that is obviously unrelated to this particular series.


Jonathan

>  
>  /* Bits definitions for SC27XX_ADC_INT_EN registers */
>  #define SC27XX_ADC_IRQ_EN		BIT(0)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ