/linux/sound/soc/codecs/ |
H A D | ics43432.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | es7134.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | ak4554.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | ak5386.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | spdif_transmitter.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | pcm179x.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | spdif_receiver.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | max9860.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | max98926.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | bt-sco.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | nau8810.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | nau8540.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | rt274.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | ads117x.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | tas5720.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | ad73311.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | pcm3008.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | cs35l33.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | dmic.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | adau1977.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | cs4349.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | rt5616.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | rt5660.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | ssm4567.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|
H A D | inno_rk3036.c | diff a180ba45b1cf630b3bd5912ce235b2ee16606b8e Thu Aug 03 18:00:19 CEST 2017 Bhumika Goyal <bhumirks@gmail.com> ASoC: codecs: add const to snd_soc_codec_driver structures
Declare snd_soc_codec_driver structures as const as they are only passed as an argument to the function snd_soc_register_codec. This argument is of type const, so declare the structures with this property as const. In file codecs/sn95031.c, snd_soc_codec_driver structure is also used in a copy operation along with getting passed to snd_soc_register_codec. So, it can be made const too. Done using Coccinelle:
@match disable optional_qualifier@ identifier s; position p; @@ static struct snd_soc_codec_driver s@p={...};
@good1@ identifier match.s; position p; @@ snd_soc_register_codec(...,&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_soc_codec_driver s={...};
Signed-off-by: Bhumika Goyal <bhumirks@gmail.com> Signed-off-by: Mark Brown <broonie@kernel.org>
|