Commit 74729a8f authored by Pierre-Louis Bossart's avatar Pierre-Louis Bossart Committed by Takashi Iwai

ASoC: pci/emu10k1: remove "set but not used' warnings

Fix W=1 warnings. Mark variables used for reads as __always_unused.

sound/pci/emu10k1/emu10k1_main.c: In function
‘snd_emu10k1_cardbus_init’:
sound/pci/emu10k1/emu10k1_main.c:626:15: warning: variable ‘value’ set
but not used [-Wunused-but-set-variable]
  626 |  unsigned int value;
      |               ^~~~~
sound/pci/emu10k1/emu10k1_main.c: In function
‘snd_emu1010_load_firmware_entry’:
sound/pci/emu10k1/emu10k1_main.c:656:15: warning: variable
‘write_post’ set but not used [-Wunused-but-set-variable]
  656 |  unsigned int write_post;
      |               ^~~~~~~~~~
Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20200702193604.169059-12-pierre-louis.bossart@linux.intel.comSigned-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent fe372850
...@@ -623,7 +623,7 @@ static int snd_emu10k1_ecard_init(struct snd_emu10k1 *emu) ...@@ -623,7 +623,7 @@ static int snd_emu10k1_ecard_init(struct snd_emu10k1 *emu)
static int snd_emu10k1_cardbus_init(struct snd_emu10k1 *emu) static int snd_emu10k1_cardbus_init(struct snd_emu10k1 *emu)
{ {
unsigned long special_port; unsigned long special_port;
unsigned int value; __always_unused unsigned int value;
/* Special initialisation routine /* Special initialisation routine
* before the rest of the IO-Ports become active. * before the rest of the IO-Ports become active.
...@@ -653,7 +653,7 @@ static int snd_emu1010_load_firmware_entry(struct snd_emu10k1 *emu, ...@@ -653,7 +653,7 @@ static int snd_emu1010_load_firmware_entry(struct snd_emu10k1 *emu,
int n, i; int n, i;
int reg; int reg;
int value; int value;
unsigned int write_post; __always_unused unsigned int write_post;
unsigned long flags; unsigned long flags;
if (!fw_entry) if (!fw_entry)
......
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