ASoC: soc-pcm: remove shadowing variable
authorPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Thu, 18 Feb 2021 22:19:18 +0000 (16:19 -0600)
committerMark Brown <broonie@kernel.org>
Wed, 10 Mar 2021 13:06:55 +0000 (13:06 +0000)
cppcheck warning:

sound/soc/soc-pcm.c:1718:7: style: Local variable 'i' shadows outer
variable [shadowVariable]
  int i;
      ^
sound/soc/soc-pcm.c:1696:6: note: Shadowed declaration
 int i;
     ^
sound/soc/soc-pcm.c:1718:7: note: Shadow variable
  int i;
      ^

the second variable seems totally unnecessary.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20210218221921.88991-4-pierre-louis.bossart@linux.intel.com
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/soc-pcm.c

index 12fd10a..705fb2d 100644 (file)
@@ -1718,7 +1718,6 @@ static int dpcm_apply_symmetry(struct snd_pcm_substream *fe_substream,
                        snd_soc_dpcm_get_substream(be, stream);
                struct snd_soc_pcm_runtime *rtd;
                struct snd_soc_dai *dai;
-               int i;
 
                /* A backend may not have the requested substream */
                if (!be_substream)