[2/2] ALSA: usb: update old-style static const declaration
diff mbox series

Message ID 20200111214736.3002-3-pierre-louis.bossart@linux.intel.com
State New
Headers show
Series
  • ALSA: fix compiler warnings
Related show

Commit Message

Pierre-Louis Bossart Jan. 11, 2020, 9:47 p.m. UTC
GCC reports the following warning with W=1

sound/usb/mixer_quirks.c: In function ‘snd_microii_controls_create’:
sound/usb/mixer_quirks.c:1694:2: warning: ‘static’ is not at beginning
of declaration [-Wold-style-declaration]
 1694 |  const static usb_mixer_elem_resume_func_t resume_funcs[] = {
      |  ^~~~~

Move static to the beginning of declaration

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
---
 sound/usb/mixer_quirks.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Takashi Iwai Jan. 12, 2020, 8:44 a.m. UTC | #1
On Sat, 11 Jan 2020 22:47:36 +0100,
Pierre-Louis Bossart wrote:
> 
> GCC reports the following warning with W=1
> 
> sound/usb/mixer_quirks.c: In function ‘snd_microii_controls_create’:
> sound/usb/mixer_quirks.c:1694:2: warning: ‘static’ is not at beginning
> of declaration [-Wold-style-declaration]
>  1694 |  const static usb_mixer_elem_resume_func_t resume_funcs[] = {
>       |  ^~~~~
> 
> Move static to the beginning of declaration
> 
> Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>

Thanks, applied now.


Takashi

Patch
diff mbox series

diff --git a/sound/usb/mixer_quirks.c b/sound/usb/mixer_quirks.c
index b9f5a9c18040..c237e24f08d9 100644
--- a/sound/usb/mixer_quirks.c
+++ b/sound/usb/mixer_quirks.c
@@ -1691,7 +1691,7 @@  static const struct snd_kcontrol_new snd_microii_mixer_spdif[] = {
 static int snd_microii_controls_create(struct usb_mixer_interface *mixer)
 {
 	int err, i;
-	const static usb_mixer_elem_resume_func_t resume_funcs[] = {
+	static const usb_mixer_elem_resume_func_t resume_funcs[] = {
 		snd_microii_spdif_default_update,
 		NULL,
 		snd_microii_spdif_switch_update