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]
Date:   Fri, 28 Dec 2018 11:55:48 +0000
From:   Charles Keepax <ckeepax@...nsource.cirrus.com>
To:     <broonie@...nel.org>, <matti.vaittinen@...rohmeurope.com>
CC:     <linux-kernel@...r.kernel.org>, <patches@...nsource.cirrus.com>
Subject: Re: [PATCH] regmap: irq: Make IRQ type support optional

On Fri, Dec 28, 2018 at 11:23:58AM +0000, Charles Keepax wrote:
> Currently only gpio-max77620 is using the type support in regmap IRQ,
> but the implementation causes the irq_set_type operation to fail on all
> other regmap IRQ chips. Avoid these regressions by skipping the type
> handling on any chips that don't define a set of supported types.
> 
> Fixes: 1c2928e3e321 ("regmap: regmap-irq/gpio-max77620: add level-irq support")
> Signed-off-by: Charles Keepax <ckeepax@...nsource.cirrus.com>
> ---
>  drivers/base/regmap/regmap-irq.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/base/regmap/regmap-irq.c b/drivers/base/regmap/regmap-irq.c
> index 1bd1145ad8b5e..8c674f1ad0fc8 100644
> --- a/drivers/base/regmap/regmap-irq.c
> +++ b/drivers/base/regmap/regmap-irq.c
> @@ -257,6 +257,9 @@ static int regmap_irq_set_type(struct irq_data *data, unsigned int type)
>  	int reg;
>  	const struct regmap_irq_type *t = &irq_data->type;
>  
> +	if (!t->types_supported)
> +		return 0;
> +
>  	if ((t->types_supported & type) != type)
>  		return -ENOTSUPP;
>  
> -- 
> 2.11.0

+ Matti Vaittinen, apologies for forgetting to include you on the
original sending.

Thanks,
Charles

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ