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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:   Thu, 13 Jul 2017 12:41:26 -0500
From:   Thor Thayer <thor.thayer@...ux.intel.com>
To:     "Gustavo A. R. Silva" <garsilva@...eddedor.com>,
        Linus Walleij <linus.walleij@...aro.org>
Cc:     linux-gpio@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] gpio: altera-a10sr: constify gpio_chip structure

On 07/11/2017 05:15 PM, Gustavo A. R. Silva wrote:
> This structure is only used to copy into another structure, so declare
> it as const.

<snip>

> Signed-off-by: Gustavo A. R. Silva <garsilva@...eddedor.com>
> ---
>   drivers/gpio/gpio-altera-a10sr.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/gpio/gpio-altera-a10sr.c b/drivers/gpio/gpio-altera-a10sr.c
> index 16a8951..6b11f13 100644
> --- a/drivers/gpio/gpio-altera-a10sr.c
> +++ b/drivers/gpio/gpio-altera-a10sr.c
> @@ -71,7 +71,7 @@ static int altr_a10sr_gpio_direction_output(struct gpio_chip *gc,
>   	return -EINVAL;
>   }
>   
> -static struct gpio_chip altr_a10sr_gc = {
> +static const struct gpio_chip altr_a10sr_gc = {
>   	.label = "altr_a10sr_gpio",
>   	.owner = THIS_MODULE,
>   	.get = altr_a10sr_gpio_get,
> 
Reviewed-by: Thor Thayer <thor.thayer@...ux.intel.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ