From 4647e8d512224265afad63aa27a6b22561f50d46 Mon Sep 17 00:00:00 2001 From: Bhumika Goyal Date: Fri, 4 Aug 2017 21:04:41 +0530 Subject: ALSA: ice1712: add const to snd_ak4xxx_private structures Declare snd_ak4xxx_private structures as const as they are only passed to the function snd_ice1712_akm4xxx_init. This argument is of type const, so make the structures const. Done using Coccinelle: @match disable optional_qualifier@ identifier s; position p; @@ static struct snd_ak4xxx_private s@p={...}; @good1@ identifier match.s; position p; @@ snd_ice1712_akm4xxx_init(...,&s@p,...) @bad@ identifier match.s; position p!={match.p,good1.p}; @@ s@p @depends on !bad disable optional_qualifier@ identifier match.s; @@ static +const struct snd_ak4xxx_private s={...}; Signed-off-by: Bhumika Goyal Signed-off-by: Takashi Iwai --- sound/pci/ice1712/phase.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sound/pci/ice1712/phase.c') diff --git a/sound/pci/ice1712/phase.c b/sound/pci/ice1712/phase.c index e9ca89c9174b..4f85482f3407 100644 --- a/sound/pci/ice1712/phase.c +++ b/sound/pci/ice1712/phase.c @@ -108,7 +108,7 @@ static struct snd_akm4xxx akm_phase22 = { .num_adcs = 2, }; -static struct snd_ak4xxx_private akm_phase22_priv = { +static const struct snd_ak4xxx_private akm_phase22_priv = { .caddr = 2, .cif = 1, .data_mask = 1 << 4, -- cgit v1.2.3