Commit 14667403 authored by Pierre-Louis Bossart's avatar Pierre-Louis Bossart Committed by Mark Brown

ASoC: mediatek: mt8173: rename local irq variable

cppcheck warning:

sound/soc/mediatek/mt8173/mt8173-afe-pcm.c:929:28: style: Local
variable 'irq' shadows outer argument [shadowArgument]
  struct mtk_base_afe_irq *irq;
                           ^
sound/soc/mediatek/mt8173/mt8173-afe-pcm.c:914:47: note: Shadowed
declaration
static irqreturn_t mt8173_afe_irq_handler(int irq, void *dev_id)
                                              ^
sound/soc/mediatek/mt8173/mt8173-afe-pcm.c:929:28: note: Shadow
variable
  struct mtk_base_afe_irq *irq;
                           ^

Not a great idea to have two 'irq' variables in the same function...
Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20210311004904.121205-5-pierre-louis.bossart@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent d9cdc133
...@@ -926,14 +926,14 @@ static irqreturn_t mt8173_afe_irq_handler(int irq, void *dev_id) ...@@ -926,14 +926,14 @@ static irqreturn_t mt8173_afe_irq_handler(int irq, void *dev_id)
for (i = 0; i < MT8173_AFE_MEMIF_NUM; i++) { for (i = 0; i < MT8173_AFE_MEMIF_NUM; i++) {
struct mtk_base_afe_memif *memif = &afe->memif[i]; struct mtk_base_afe_memif *memif = &afe->memif[i];
struct mtk_base_afe_irq *irq; struct mtk_base_afe_irq *irq_p;
if (memif->irq_usage < 0) if (memif->irq_usage < 0)
continue; continue;
irq = &afe->irqs[memif->irq_usage]; irq_p = &afe->irqs[memif->irq_usage];
if (!(reg_value & (1 << irq->irq_data->irq_clr_shift))) if (!(reg_value & (1 << irq_p->irq_data->irq_clr_shift)))
continue; continue;
snd_pcm_period_elapsed(memif->substream); snd_pcm_period_elapsed(memif->substream);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment