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]
Message-ID: <alpine.LSU.2.20.1708151103020.30597@cbobk.fhfr.pm>
Date:   Tue, 15 Aug 2017 11:03:12 +0200 (CEST)
From:   Jiri Kosina <jikos@...nel.org>
To:     Julia Lawall <Julia.Lawall@...6.fr>
cc:     bhumirks@...il.com, kernel-janitors@...r.kernel.org,
        Benjamin Tissoires <benjamin.tissoires@...hat.com>,
        linux-input@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/3] HID: prodikeys: constify snd_rawmidi_ops
 structures

On Tue, 15 Aug 2017, Julia Lawall wrote:

> This snd_rawmidi_ops structure is only passed as the third
> argument of snd_rawmidi_set_ops.  This argument is const, so the
> snd_rawmidi_ops structure can be const too.
> 
> Done with the help of Coccinelle.
> 
> Signed-off-by: Julia Lawall <Julia.Lawall@...6.fr>
> 
> ---
>  drivers/hid/hid-prodikeys.c |    2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/hid/hid-prodikeys.c b/drivers/hid/hid-prodikeys.c
> index f095bf8..49c4bd3 100644
> --- a/drivers/hid/hid-prodikeys.c
> +++ b/drivers/hid/hid-prodikeys.c
> @@ -593,7 +593,7 @@ static void pcmidi_in_trigger(struct snd_rawmidi_substream *substream, int up)
>  	pm->in_triggered = up;
>  }
>  
> -static struct snd_rawmidi_ops pcmidi_in_ops = {
> +static const struct snd_rawmidi_ops pcmidi_in_ops = {
>  	.open = pcmidi_in_open,
>  	.close = pcmidi_in_close,
>  	.trigger = pcmidi_in_trigger

Applied to for-4.14/upstream, thanks.

-- 
Jiri Kosina
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ