diff mbox series

[03/16] ASoC: wcd-mbhc-v2: remove useless initialization

Message ID 20220520211719.607543-4-pierre-louis.bossart@linux.intel.com
State Accepted
Commit cac24a360a6b948ffb75c3d7ccc819064300454c
Headers show
Series ASoC: trivial changes for cppcheck warnings | expand

Commit Message

Pierre-Louis Bossart May 20, 2022, 9:17 p.m. UTC
cppcheck warning:

sound/soc/codecs/wcd-mbhc-v2.c:1309:17: style: Variable 'clamp_state'
is assigned a value that is never used. [unreadVariable]
 u8 clamp_state = 0;
                ^

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com>
Reviewed-by: Péter Ujfalusi <peter.ujfalusi@linux.intel.com>
---
 sound/soc/codecs/wcd-mbhc-v2.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/sound/soc/codecs/wcd-mbhc-v2.c b/sound/soc/codecs/wcd-mbhc-v2.c
index c53c2ef33e1a2..31009283e7d4a 100644
--- a/sound/soc/codecs/wcd-mbhc-v2.c
+++ b/sound/soc/codecs/wcd-mbhc-v2.c
@@ -1306,7 +1306,7 @@  static irqreturn_t wcd_mbhc_adc_hs_rem_irq(int irq, void *data)
 static irqreturn_t wcd_mbhc_adc_hs_ins_irq(int irq, void *data)
 {
 	struct wcd_mbhc *mbhc = data;
-	u8 clamp_state = 0;
+	u8 clamp_state;
 	u8 clamp_retry = WCD_MBHC_FAKE_INS_RETRY;
 
 	/*