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] [day] [month] [year] [list]
Date:   Mon, 1 Apr 2019 09:46:40 +0000
From:   "Vaittinen, Matti" <Matti.Vaittinen@...rohmeurope.com>
To:     "srinivas.kandagatla@...aro.org" <srinivas.kandagatla@...aro.org>,
        "broonie@...nel.org" <broonie@...nel.org>
CC:     "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "gregkh@...uxfoundation.org" <gregkh@...uxfoundation.org>,
        "rafael@...nel.org" <rafael@...nel.org>
Subject: Re: [PATCH] regmap: regmap-irq: fix getting type default values

On Thu, 2019-03-28 at 16:22 +0000, Srinivas Kandagatla wrote:
> Checking for value of type default value just after allocating will
> always be zero and the type register default values will never be
> read,
> so fix this!
> 
> Without this patch setting irq type will be silently ignored.
> Patch "regmap: regmap-irq: Remove default irq type setting from core"
> did remove the default mask but it forgot to remove the check before
> reading the default type register.
> 
> Fixes: 84267d1b18ab ("regmap: regmap-irq: Remove default irq type
> setting from core")
> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@...aro.org>
Acked-by: Matti Vaittinen <matti.vaittinen@...rohmeurope.com>

> ---
>  drivers/base/regmap/regmap-irq.c | 3 ---
>  1 file changed, 3 deletions(-)
> 
> diff --git a/drivers/base/regmap/regmap-irq.c
> b/drivers/base/regmap/regmap-irq.c
> index 5059748afd4c..02eb75646141 100644
> --- a/drivers/base/regmap/regmap-irq.c
> +++ b/drivers/base/regmap/regmap-irq.c
> @@ -761,9 +761,6 @@ int regmap_add_irq_chip(struct regmap *map, int
> irq, int irq_flags,
>  
>  	if (chip->num_type_reg && !chip->type_in_mask) {
>  		for (i = 0; i < chip->num_type_reg; ++i) {
> -			if (!d->type_buf_def[i])
> -				continue;
> -
>  			reg = chip->type_base +
>  				(i * map->reg_stride * d-
> >type_reg_stride);
>  
It looks like I left a bug there. Thanks for the fix!

Br,
    Matti


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ