ALSA: opti9xx: constify pnp_card_device_id
authorArvind Yadav <arvind.yadav.cs@gmail.com>
Thu, 17 Aug 2017 10:06:27 +0000 (15:36 +0530)
committerTakashi Iwai <tiwai@suse.de>
Thu, 17 Aug 2017 10:42:28 +0000 (12:42 +0200)
pnp_card_device_id are not supposed to change at runtime. All functions
working with pnp_card_device_id provided by <linux/pnp.h> work with
const pnp_card_device_id. So mark the non-const structs as const.

Signed-off-by: Arvind Yadav <arvind.yadav.cs@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/isa/opti9xx/miro.c
sound/isa/opti9xx/opti92x-ad1848.c

index 1c5a12fa8be3d5820e2260ea7a239d1ccb7e921a..8894c7c18ad673c8bcebc698f5839e336b68d30d 100644 (file)
@@ -143,7 +143,7 @@ static int snd_miro_pnp_is_probed;
 
 #ifdef CONFIG_PNP
 
-static struct pnp_card_device_id snd_miro_pnpids[] = {
+static const struct pnp_card_device_id snd_miro_pnpids[] = {
        /* PCM20 and PCM12 in PnP mode */
        { .id = "MIR0924",
          .devs = { { "MIR0000" }, { "MIR0002" }, { "MIR0005" } }, },
index 56dc581c57d563c4de37e28dcefdb39708b0ebe5..505cd81e19fa5a40be7d5a9302bb1c0c7a867d00 100644 (file)
@@ -151,7 +151,7 @@ static int snd_opti9xx_pnp_is_probed;
 
 #ifdef CONFIG_PNP
 
-static struct pnp_card_device_id snd_opti9xx_pnpids[] = {
+static const struct pnp_card_device_id snd_opti9xx_pnpids[] = {
 #ifndef OPTi93X
        /* OPTi 82C924 */
        { .id = "OPT0924",