ALSA: hda - consitify string arrays

Signed-off-by: Takashi Iwai <tiwai@suse.de>

+95 -78
+5 -5
sound/pci/hda/hda_codec.c
··· 2134 2134 * This function returns zero if successful or a negative error code. 2135 2135 */ 2136 2136 int snd_hda_add_vmaster(struct hda_codec *codec, char *name, 2137 - unsigned int *tlv, const char **slaves) 2137 + unsigned int *tlv, const char * const *slaves) 2138 2138 { 2139 2139 struct snd_kcontrol *kctl; 2140 - const char **s; 2140 + const char * const *s; 2141 2141 int err; 2142 2142 2143 2143 for (s = slaves; *s && !snd_hda_find_mixer_ctl(codec, *s); s++) ··· 3689 3689 * If no entries are matching, the function returns a negative value. 3690 3690 */ 3691 3691 int snd_hda_check_board_config(struct hda_codec *codec, 3692 - int num_configs, const char **models, 3692 + int num_configs, const char * const *models, 3693 3693 const struct snd_pci_quirk *tbl) 3694 3694 { 3695 3695 if (codec->modelname && models) { ··· 3753 3753 * If no entries are matching, the function returns a negative value. 3754 3754 */ 3755 3755 int snd_hda_check_board_codec_sid_config(struct hda_codec *codec, 3756 - int num_configs, const char **models, 3756 + int num_configs, const char * const *models, 3757 3757 const struct snd_pci_quirk *tbl) 3758 3758 { 3759 3759 const struct snd_pci_quirk *q; ··· 4690 4690 int check_location) 4691 4691 { 4692 4692 unsigned int def_conf; 4693 - static const char *mic_names[] = { 4693 + static const char * const mic_names[] = { 4694 4694 "Internal Mic", "Dock Mic", "Mic", "Front Mic", "Rear Mic", 4695 4695 }; 4696 4696 int attr;
+4 -3
sound/pci/hda/hda_generic.c
··· 762 762 /* 763 763 * build output mixer controls 764 764 */ 765 - static int create_output_mixers(struct hda_codec *codec, const char **names) 765 + static int create_output_mixers(struct hda_codec *codec, 766 + const char * const *names) 766 767 { 767 768 struct hda_gspec *spec = codec->spec; 768 769 int i, err; ··· 781 780 static int build_output_controls(struct hda_codec *codec) 782 781 { 783 782 struct hda_gspec *spec = codec->spec; 784 - static const char *types_speaker[] = { "Speaker", "Headphone" }; 785 - static const char *types_line[] = { "Front", "Headphone" }; 783 + static const char * const types_speaker[] = { "Speaker", "Headphone" }; 784 + static const char * const types_line[] = { "Front", "Headphone" }; 786 785 787 786 switch (spec->pcm_vol_nodes) { 788 787 case 1:
+3 -3
sound/pci/hda/hda_local.h
··· 140 140 struct snd_kcontrol *snd_hda_find_mixer_ctl(struct hda_codec *codec, 141 141 const char *name); 142 142 int snd_hda_add_vmaster(struct hda_codec *codec, char *name, 143 - unsigned int *tlv, const char **slaves); 143 + unsigned int *tlv, const char * const *slaves); 144 144 int snd_hda_codec_reset(struct hda_codec *codec); 145 145 146 146 /* amp value bits */ ··· 341 341 * Misc 342 342 */ 343 343 int snd_hda_check_board_config(struct hda_codec *codec, int num_configs, 344 - const char **modelnames, 344 + const char * const *modelnames, 345 345 const struct snd_pci_quirk *pci_list); 346 346 int snd_hda_check_board_codec_sid_config(struct hda_codec *codec, 347 - int num_configs, const char **models, 347 + int num_configs, const char * const *models, 348 348 const struct snd_pci_quirk *tbl); 349 349 int snd_hda_add_new_ctls(struct hda_codec *codec, 350 350 struct snd_kcontrol_new *knew);
+1 -1
sound/pci/hda/hda_proc.c
··· 418 418 419 419 static const char *get_pwr_state(u32 state) 420 420 { 421 - static const char *buf[4] = { 421 + static const char * const buf[4] = { 422 422 "D0", "D1", "D2", "D3" 423 423 }; 424 424 if (state < 4)
+16 -14
sound/pci/hda/patch_analog.c
··· 84 84 #endif 85 85 /* for virtual master */ 86 86 hda_nid_t vmaster_nid; 87 - const char **slave_vols; 88 - const char **slave_sws; 87 + const char * const *slave_vols; 88 + const char * const *slave_sws; 89 89 }; 90 90 91 91 /* ··· 133 133 return 0; 134 134 } 135 135 136 - static const char *ad_slave_vols[] = { 136 + static const char * const ad_slave_vols[] = { 137 137 "Front Playback Volume", 138 138 "Surround Playback Volume", 139 139 "Center Playback Volume", ··· 146 146 NULL 147 147 }; 148 148 149 - static const char *ad_slave_sws[] = { 149 + static const char * const ad_slave_sws[] = { 150 150 "Front Playback Switch", 151 151 "Surround Playback Switch", 152 152 "Center Playback Switch", ··· 159 159 NULL 160 160 }; 161 161 162 - static const char *ad1988_6stack_fp_slave_vols[] = { 162 + static const char * const ad1988_6stack_fp_slave_vols[] = { 163 163 "Front Playback Volume", 164 164 "Surround Playback Volume", 165 165 "Center Playback Volume", ··· 169 169 NULL 170 170 }; 171 171 172 - static const char *ad1988_6stack_fp_slave_sws[] = { 172 + static const char * const ad1988_6stack_fp_slave_sws[] = { 173 173 "Front Playback Switch", 174 174 "Surround Playback Switch", 175 175 "Center Playback Switch", ··· 1134 1134 AD1986A_MODELS 1135 1135 }; 1136 1136 1137 - static const char *ad1986a_models[AD1986A_MODELS] = { 1137 + static const char * const ad1986a_models[AD1986A_MODELS] = { 1138 1138 [AD1986A_6STACK] = "6stack", 1139 1139 [AD1986A_3STACK] = "3stack", 1140 1140 [AD1986A_LAPTOP] = "laptop", ··· 1878 1878 AD1981_MODELS 1879 1879 }; 1880 1880 1881 - static const char *ad1981_models[AD1981_MODELS] = { 1881 + static const char * const ad1981_models[AD1981_MODELS] = { 1882 1882 [AD1981_HP] = "hp", 1883 1883 [AD1981_THINKPAD] = "thinkpad", 1884 1884 [AD1981_BASIC] = "basic", ··· 2953 2953 const struct auto_pin_cfg *cfg) 2954 2954 { 2955 2955 char name[32]; 2956 - static const char *chname[4] = { "Front", "Surround", NULL /*CLFE*/, "Side" }; 2956 + static const char * const chname[4] = { 2957 + "Front", "Surround", NULL /*CLFE*/, "Side" 2958 + }; 2957 2959 hda_nid_t nid; 2958 2960 int i, err; 2959 2961 ··· 3240 3238 /* 3241 3239 */ 3242 3240 3243 - static const char *ad1988_models[AD1988_MODEL_LAST] = { 3241 + static const char * const ad1988_models[AD1988_MODEL_LAST] = { 3244 3242 [AD1988_6STACK] = "6stack", 3245 3243 [AD1988_6STACK_DIG] = "6stack-dig", 3246 3244 [AD1988_6STACK_DIG_FP] = "6stack-dig-fp", ··· 3575 3573 }; 3576 3574 #endif 3577 3575 3578 - static const char *ad1884_slave_vols[] = { 3576 + static const char * const ad1884_slave_vols[] = { 3579 3577 "PCM Playback Volume", 3580 3578 "Mic Playback Volume", 3581 3579 "Mono Playback Volume", ··· 3813 3811 AD1984_MODELS 3814 3812 }; 3815 3813 3816 - static const char *ad1984_models[AD1984_MODELS] = { 3814 + static const char * const ad1984_models[AD1984_MODELS] = { 3817 3815 [AD1984_BASIC] = "basic", 3818 3816 [AD1984_THINKPAD] = "thinkpad", 3819 3817 [AD1984_DELL_DESKTOP] = "dell_desktop", ··· 4484 4482 AD1884A_MODELS 4485 4483 }; 4486 4484 4487 - static const char *ad1884a_models[AD1884A_MODELS] = { 4485 + static const char * const ad1884a_models[AD1884A_MODELS] = { 4488 4486 [AD1884A_DESKTOP] = "desktop", 4489 4487 [AD1884A_LAPTOP] = "laptop", 4490 4488 [AD1884A_MOBILE] = "mobile", ··· 4872 4870 AD1882_MODELS 4873 4871 }; 4874 4872 4875 - static const char *ad1882_models[AD1986A_MODELS] = { 4873 + static const char * const ad1882_models[AD1986A_MODELS] = { 4876 4874 [AD1882_3STACK] = "3stack", 4877 4875 [AD1882_6STACK] = "6stack", 4878 4876 };
+2 -2
sound/pci/hda/patch_cirrus.c
··· 490 490 * create mixer controls 491 491 */ 492 492 493 - static const char *dir_sfx[2] = { "Playback", "Capture" }; 493 + static const char * const dir_sfx[2] = { "Playback", "Capture" }; 494 494 495 495 static int add_mute(struct hda_codec *codec, const char *name, int index, 496 496 unsigned int pval, int dir, struct snd_kcontrol **kctlp) ··· 1156 1156 return 0; 1157 1157 } 1158 1158 1159 - static const char *cs420x_models[CS420X_MODELS] = { 1159 + static const char * const cs420x_models[CS420X_MODELS] = { 1160 1160 [CS420X_MBP53] = "mbp53", 1161 1161 [CS420X_MBP55] = "mbp55", 1162 1162 [CS420X_IMAC27] = "imac27",
+1 -1
sound/pci/hda/patch_cmedia.c
··· 608 608 /* 609 609 */ 610 610 611 - static const char *cmi9880_models[CMI_MODELS] = { 611 + static const char * const cmi9880_models[CMI_MODELS] = { 612 612 [CMI_MINIMAL] = "minimal", 613 613 [CMI_MIN_FP] = "min_fp", 614 614 [CMI_FULL] = "full",
+7 -7
sound/pci/hda/patch_conexant.c
··· 537 537 }; 538 538 #endif 539 539 540 - static const char *slave_vols[] = { 540 + static const char * const slave_vols[] = { 541 541 "Headphone Playback Volume", 542 542 "Speaker Playback Volume", 543 543 NULL 544 544 }; 545 545 546 - static const char *slave_sws[] = { 546 + static const char * const slave_sws[] = { 547 547 "Headphone Playback Switch", 548 548 "Speaker Playback Switch", 549 549 NULL ··· 1134 1134 CXT5045_MODELS 1135 1135 }; 1136 1136 1137 - static const char *cxt5045_models[CXT5045_MODELS] = { 1137 + static const char * const cxt5045_models[CXT5045_MODELS] = { 1138 1138 [CXT5045_LAPTOP_HPSENSE] = "laptop-hpsense", 1139 1139 [CXT5045_LAPTOP_MICSENSE] = "laptop-micsense", 1140 1140 [CXT5045_LAPTOP_HPMICSENSE] = "laptop-hpmicsense", ··· 1579 1579 CXT5047_MODELS 1580 1580 }; 1581 1581 1582 - static const char *cxt5047_models[CXT5047_MODELS] = { 1582 + static const char * const cxt5047_models[CXT5047_MODELS] = { 1583 1583 [CXT5047_LAPTOP] = "laptop", 1584 1584 [CXT5047_LAPTOP_HP] = "laptop-hp", 1585 1585 [CXT5047_LAPTOP_EAPD] = "laptop-eapd", ··· 1995 1995 CXT5051_MODELS 1996 1996 }; 1997 1997 1998 - static const char *cxt5051_models[CXT5051_MODELS] = { 1998 + static const char *const cxt5051_models[CXT5051_MODELS] = { 1999 1999 [CXT5051_LAPTOP] = "laptop", 2000 2000 [CXT5051_HP] = "hp", 2001 2001 [CXT5051_HP_DV6736] = "hp-dv6736", ··· 3084 3084 CXT5066_MODELS 3085 3085 }; 3086 3086 3087 - static const char *cxt5066_models[CXT5066_MODELS] = { 3087 + static const char * const cxt5066_models[CXT5066_MODELS] = { 3088 3088 [CXT5066_LAPTOP] = "laptop", 3089 3089 [CXT5066_DELL_LAPTOP] = "dell-laptop", 3090 3090 [CXT5066_OLPC_XO_1_5] = "olpc-xo-1_5", ··· 3746 3746 struct conexant_spec *spec = codec->spec; 3747 3747 int i, err; 3748 3748 int num_line = 0, num_hp = 0, num_spk = 0; 3749 - static const char *texts[3] = { "Front", "Surround", "CLFE" }; 3749 + static const char * const texts[3] = { "Front", "Surround", "CLFE" }; 3750 3750 3751 3751 if (spec->dac_info_filled == 1) 3752 3752 return cx_auto_add_pb_volume(codec, spec->dac_info[0].dac,
+18 -16
sound/pci/hda/patch_realtek.c
··· 2916 2916 /* 2917 2917 * slave controls for virtual master 2918 2918 */ 2919 - static const char *alc_slave_vols[] = { 2919 + static const char * const alc_slave_vols[] = { 2920 2920 "Front Playback Volume", 2921 2921 "Surround Playback Volume", 2922 2922 "Center Playback Volume", ··· 2930 2930 NULL, 2931 2931 }; 2932 2932 2933 - static const char *alc_slave_sws[] = { 2933 + static const char * const alc_slave_sws[] = { 2934 2934 "Front Playback Switch", 2935 2935 "Surround Playback Switch", 2936 2936 "Center Playback Switch", ··· 4611 4611 /* 4612 4612 */ 4613 4613 4614 - static const char *alc880_models[ALC880_MODEL_LAST] = { 4614 + static const char * const alc880_models[ALC880_MODEL_LAST] = { 4615 4615 [ALC880_3ST] = "3stack", 4616 4616 [ALC880_TCL_S700] = "tcl", 4617 4617 [ALC880_3ST_DIG] = "3stack-digout", ··· 5144 5144 static int alc880_auto_create_multi_out_ctls(struct alc_spec *spec, 5145 5145 const struct auto_pin_cfg *cfg) 5146 5146 { 5147 - static const char *chname[4] = { 5147 + static const char * const chname[4] = { 5148 5148 "Front", "Surround", NULL /*CLFE*/, "Side" 5149 5149 }; 5150 5150 const char *pfx = alc_get_line_out_pfx(cfg, false); ··· 7158 7158 /* 7159 7159 * ALC260 configurations 7160 7160 */ 7161 - static const char *alc260_models[ALC260_MODEL_LAST] = { 7161 + static const char * const alc260_models[ALC260_MODEL_LAST] = { 7162 7162 [ALC260_BASIC] = "basic", 7163 7163 [ALC260_HP] = "hp", 7164 7164 [ALC260_HP_3013] = "hp-3013", ··· 9781 9781 /* 9782 9782 * configuration and preset 9783 9783 */ 9784 - static const char *alc882_models[ALC882_MODEL_LAST] = { 9784 + static const char * const alc882_models[ALC882_MODEL_LAST] = { 9785 9785 [ALC882_3ST_DIG] = "3stack-dig", 9786 9786 [ALC882_6ST_DIG] = "6stack-dig", 9787 9787 [ALC882_ARIMA] = "arima", ··· 12601 12601 /* 12602 12602 * configuration and preset 12603 12603 */ 12604 - static const char *alc262_models[ALC262_MODEL_LAST] = { 12604 + static const char * const alc262_models[ALC262_MODEL_LAST] = { 12605 12605 [ALC262_BASIC] = "basic", 12606 12606 [ALC262_HIPPO] = "hippo", 12607 12607 [ALC262_HIPPO_1] = "hippo_1", ··· 13789 13789 /* 13790 13790 * configuration and preset 13791 13791 */ 13792 - static const char *alc268_models[ALC268_MODEL_LAST] = { 13792 + static const char * const alc268_models[ALC268_MODEL_LAST] = { 13793 13793 [ALC267_QUANTA_IL1] = "quanta-il1", 13794 13794 [ALC268_3ST] = "3stack", 13795 13795 [ALC268_TOSHIBA] = "toshiba", ··· 14961 14961 /* 14962 14962 * configuration and preset 14963 14963 */ 14964 - static const char *alc269_models[ALC269_MODEL_LAST] = { 14964 + static const char * const alc269_models[ALC269_MODEL_LAST] = { 14965 14965 [ALC269_BASIC] = "basic", 14966 14966 [ALC269_QUANTA_FL1] = "quanta", 14967 14967 [ALC269_AMIC] = "laptop-amic", ··· 16004 16004 const struct auto_pin_cfg *cfg) 16005 16005 { 16006 16006 struct alc_spec *spec = codec->spec; 16007 - static const char *chname[4] = { 16007 + static const char * const chname[4] = { 16008 16008 "Front", "Surround", NULL /*CLFE*/, "Side" 16009 16009 }; 16010 16010 const char *pfx = alc_get_line_out_pfx(cfg, true); ··· 16210 16210 /* 16211 16211 * configuration and preset 16212 16212 */ 16213 - static const char *alc861_models[ALC861_MODEL_LAST] = { 16213 + static const char * const alc861_models[ALC861_MODEL_LAST] = { 16214 16214 [ALC861_3ST] = "3stack", 16215 16215 [ALC660_3ST] = "3stack-660", 16216 16216 [ALC861_3ST_DIG] = "3stack-dig", ··· 16913 16913 /* 16914 16914 * configuration and preset 16915 16915 */ 16916 - static const char *alc861vd_models[ALC861VD_MODEL_LAST] = { 16916 + static const char * const alc861vd_models[ALC861VD_MODEL_LAST] = { 16917 16917 [ALC660VD_3ST] = "3stack-660", 16918 16918 [ALC660VD_3ST_DIG] = "3stack-660-digout", 16919 16919 [ALC660VD_ASUS_V1S] = "asus-v1s", ··· 17133 17133 static int alc861vd_auto_create_multi_out_ctls(struct alc_spec *spec, 17134 17134 const struct auto_pin_cfg *cfg) 17135 17135 { 17136 - static const char *chname[4] = {"Front", "Surround", "CLFE", "Side"}; 17136 + static const char * const chname[4] = { 17137 + "Front", "Surround", "CLFE", "Side" 17138 + }; 17137 17139 const char *pfx = alc_get_line_out_pfx(cfg, true); 17138 17140 hda_nid_t nid_v, nid_s; 17139 17141 int i, err; ··· 18690 18688 /* 18691 18689 * configuration and preset 18692 18690 */ 18693 - static const char *alc662_models[ALC662_MODEL_LAST] = { 18691 + static const char * const alc662_models[ALC662_MODEL_LAST] = { 18694 18692 [ALC662_3ST_2ch_DIG] = "3stack-dig", 18695 18693 [ALC662_3ST_6ch_DIG] = "3stack-6ch-dig", 18696 18694 [ALC662_3ST_6ch] = "3stack-6ch", ··· 19205 19203 const struct auto_pin_cfg *cfg) 19206 19204 { 19207 19205 struct alc_spec *spec = codec->spec; 19208 - static const char *chname[4] = { 19206 + static const char * const chname[4] = { 19209 19207 "Front", "Surround", NULL /*CLFE*/, "Side" 19210 19208 }; 19211 19209 const char *pfx = alc_get_line_out_pfx(cfg, true); ··· 19980 19978 /* 19981 19979 * configuration and preset 19982 19980 */ 19983 - static const char *alc680_models[ALC680_MODEL_LAST] = { 19981 + static const char * const alc680_models[ALC680_MODEL_LAST] = { 19984 19982 [ALC680_BASE] = "base", 19985 19983 [ALC680_AUTO] = "auto", 19986 19984 };
+18 -18
sound/pci/hda/patch_sigmatel.c
··· 266 266 struct sigmatel_mic_route int_mic; 267 267 struct sigmatel_mic_route dock_mic; 268 268 269 - const char **spdif_labels; 269 + const char * const *spdif_labels; 270 270 271 271 hda_nid_t dig_in_nid; 272 272 hda_nid_t mono_nid; ··· 524 524 HDA_COMPOSE_AMP_VAL(0x1d, 3, 0, HDA_OUTPUT), 525 525 }; 526 526 527 - static const char *stac927x_spdif_labels[5] = { 527 + static const char * const stac927x_spdif_labels[5] = { 528 528 "Digital Playback", "ADAT", "Analog Mux 1", 529 529 "Analog Mux 2", "Analog Mux 3" 530 530 }; ··· 1062 1062 .put = stac92xx_smux_enum_put, 1063 1063 }; 1064 1064 1065 - static const char *slave_vols[] = { 1065 + static const char * const slave_vols[] = { 1066 1066 "Front Playback Volume", 1067 1067 "Surround Playback Volume", 1068 1068 "Center Playback Volume", ··· 1073 1073 NULL 1074 1074 }; 1075 1075 1076 - static const char *slave_sws[] = { 1076 + static const char * const slave_sws[] = { 1077 1077 "Front Playback Switch", 1078 1078 "Surround Playback Switch", 1079 1079 "Center Playback Switch", ··· 1354 1354 [STAC_9200_PANASONIC] = ref9200_pin_configs, 1355 1355 }; 1356 1356 1357 - static const char *stac9200_models[STAC_9200_MODELS] = { 1357 + static const char * const stac9200_models[STAC_9200_MODELS] = { 1358 1358 [STAC_AUTO] = "auto", 1359 1359 [STAC_REF] = "ref", 1360 1360 [STAC_9200_OQO] = "oqo", ··· 1500 1500 [STAC_M6] = stac925xM6_pin_configs, 1501 1501 }; 1502 1502 1503 - static const char *stac925x_models[STAC_925x_MODELS] = { 1503 + static const char * const stac925x_models[STAC_925x_MODELS] = { 1504 1504 [STAC_925x_AUTO] = "auto", 1505 1505 [STAC_REF] = "ref", 1506 1506 [STAC_M1] = "m1", ··· 1574 1574 [STAC_92HD73XX_INTEL] = intel_dg45id_pin_configs, 1575 1575 }; 1576 1576 1577 - static const char *stac92hd73xx_models[STAC_92HD73XX_MODELS] = { 1577 + static const char * const stac92hd73xx_models[STAC_92HD73XX_MODELS] = { 1578 1578 [STAC_92HD73XX_AUTO] = "auto", 1579 1579 [STAC_92HD73XX_NO_JD] = "no-jd", 1580 1580 [STAC_92HD73XX_REF] = "ref", ··· 1660 1660 [STAC_HP_DV7_4000] = hp_dv7_4000_pin_configs, 1661 1661 }; 1662 1662 1663 - static const char *stac92hd83xxx_models[STAC_92HD83XXX_MODELS] = { 1663 + static const char * const stac92hd83xxx_models[STAC_92HD83XXX_MODELS] = { 1664 1664 [STAC_92HD83XXX_AUTO] = "auto", 1665 1665 [STAC_92HD83XXX_REF] = "ref", 1666 1666 [STAC_92HD83XXX_PWR_REF] = "mic-ref", ··· 1722 1722 [STAC_HP_DV4_1222NR] = NULL, 1723 1723 }; 1724 1724 1725 - static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = { 1725 + static const char * const stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = { 1726 1726 [STAC_92HD71BXX_AUTO] = "auto", 1727 1727 [STAC_92HD71BXX_REF] = "ref", 1728 1728 [STAC_DELL_M4_1] = "dell-m4-1", ··· 1915 1915 [STAC_922X_DELL_M82] = dell_922x_m82_pin_configs, 1916 1916 }; 1917 1917 1918 - static const char *stac922x_models[STAC_922X_MODELS] = { 1918 + static const char * const stac922x_models[STAC_922X_MODELS] = { 1919 1919 [STAC_922X_AUTO] = "auto", 1920 1920 [STAC_D945_REF] = "ref", 1921 1921 [STAC_D945GTP5] = "5stack", ··· 2077 2077 [STAC_927X_VOLKNOB] = NULL, 2078 2078 }; 2079 2079 2080 - static const char *stac927x_models[STAC_927X_MODELS] = { 2080 + static const char * const stac927x_models[STAC_927X_MODELS] = { 2081 2081 [STAC_927X_AUTO] = "auto", 2082 2082 [STAC_D965_REF_NO_JD] = "ref-no-jd", 2083 2083 [STAC_D965_REF] = "ref", ··· 2180 2180 [STAC_9205_EAPD] = NULL, 2181 2181 }; 2182 2182 2183 - static const char *stac9205_models[STAC_9205_MODELS] = { 2183 + static const char * const stac9205_models[STAC_9205_MODELS] = { 2184 2184 [STAC_9205_AUTO] = "auto", 2185 2185 [STAC_9205_REF] = "ref", 2186 2186 [STAC_9205_DELL_M42] = "dell-m42", ··· 3123 3123 int type) 3124 3124 { 3125 3125 struct sigmatel_spec *spec = codec->spec; 3126 - static const char *chname[4] = { 3126 + static const char * const chname[4] = { 3127 3127 "Front", "Surround", NULL /*CLFE*/, "Side" 3128 3128 }; 3129 3129 hda_nid_t nid; ··· 3256 3256 } 3257 3257 3258 3258 /* labels for mono mux outputs */ 3259 - static const char *stac92xx_mono_labels[4] = { 3259 + static const char * const stac92xx_mono_labels[4] = { 3260 3260 "DAC0", "DAC1", "Mixer", "DAC2" 3261 3261 }; 3262 3262 ··· 3380 3380 return 0; 3381 3381 }; 3382 3382 3383 - static const char *stac92xx_spdif_labels[3] = { 3383 + static const char * const stac92xx_spdif_labels[3] = { 3384 3384 "Digital Playback", "Analog Mux 1", "Analog Mux 2", 3385 3385 }; 3386 3386 ··· 3388 3388 { 3389 3389 struct sigmatel_spec *spec = codec->spec; 3390 3390 struct hda_input_mux *spdif_mux = &spec->private_smux; 3391 - const char **labels = spec->spdif_labels; 3391 + const char * const *labels = spec->spdif_labels; 3392 3392 int i, num_cons; 3393 3393 hda_nid_t con_lst[HDA_MAX_NUM_INPUTS]; 3394 3394 ··· 3409 3409 } 3410 3410 3411 3411 /* labels for dmic mux inputs */ 3412 - static const char *stac92xx_dmic_labels[5] = { 3412 + static const char * const stac92xx_dmic_labels[5] = { 3413 3413 "Analog Inputs", "Digital Mic 1", "Digital Mic 2", 3414 3414 "Digital Mic 3", "Digital Mic 4" 3415 3415 }; ··· 6270 6270 0x90a7013e 6271 6271 }; 6272 6272 6273 - static const char *stac9872_models[STAC_9872_MODELS] = { 6273 + static const char * const stac9872_models[STAC_9872_MODELS] = { 6274 6274 [STAC_9872_AUTO] = "auto", 6275 6275 [STAC_9872_VAIO] = "vaio", 6276 6276 };
+20 -8
sound/pci/hda/patch_via.c
··· 2282 2282 const struct auto_pin_cfg *cfg) 2283 2283 { 2284 2284 char name[32]; 2285 - static const char *chname[4] = { "Front", "Surround", "C/LFE", "Side" }; 2285 + static const char * const chname[4] = { 2286 + "Front", "Surround", "C/LFE", "Side" 2287 + }; 2286 2288 hda_nid_t nid, nid_vol, nid_vols[] = {0x17, 0x19, 0x1a, 0x1b}; 2287 2289 int i, err; 2288 2290 ··· 2373 2371 { 2374 2372 int i; 2375 2373 struct hda_input_mux *imux = &spec->private_imux[1]; 2376 - static const char *texts[] = { "OFF", "ON", NULL}; 2374 + static const char * const texts[] = { "OFF", "ON", NULL}; 2377 2375 2378 2376 /* for hp mode select */ 2379 2377 for (i = 0; texts[i]; i++) ··· 2893 2891 const struct auto_pin_cfg *cfg) 2894 2892 { 2895 2893 char name[32]; 2896 - static const char *chname[4] = { "Front", "Surround", "C/LFE", "Side" }; 2894 + static const char * const chname[4] = { 2895 + "Front", "Surround", "C/LFE", "Side" 2896 + }; 2897 2897 hda_nid_t nid, nid_vol, nid_vols[] = {0x18, 0x1a, 0x1b, 0x29}; 2898 2898 int i, err; 2899 2899 ··· 3438 3434 const struct auto_pin_cfg *cfg) 3439 3435 { 3440 3436 char name[32]; 3441 - static const char *chname[4] = { "Front", "Surround", "C/LFE", "Side" }; 3437 + static const char * const chname[4] = { 3438 + "Front", "Surround", "C/LFE", "Side" 3439 + }; 3442 3440 hda_nid_t nid_vols[] = {0x16, 0x18, 0x26, 0x27}; 3443 3441 hda_nid_t nid, nid_vol = 0; 3444 3442 int i, err; ··· 3868 3862 const struct auto_pin_cfg *cfg) 3869 3863 { 3870 3864 char name[32]; 3871 - static const char *chname[4] = { "Front", "Surround", "C/LFE", "Side" }; 3865 + static const char * const chname[4] = { 3866 + "Front", "Surround", "C/LFE", "Side" 3867 + }; 3872 3868 hda_nid_t nid_vols[] = {0x10, 0x11, 0x24, 0x25}; 3873 3869 hda_nid_t nid_mutes[] = {0x1C, 0x18, 0x26, 0x27}; 3874 3870 hda_nid_t nid, nid_vol, nid_mute; ··· 4313 4305 { 4314 4306 int err, i; 4315 4307 struct hda_input_mux *imux; 4316 - static const char *texts[] = { "ON", "OFF", NULL}; 4308 + static const char * const texts[] = { "ON", "OFF", NULL}; 4317 4309 if (!pin) 4318 4310 return 0; 4319 4311 spec->multiout.hp_nid = 0x1D; ··· 4624 4616 const struct auto_pin_cfg *cfg) 4625 4617 { 4626 4618 char name[32]; 4627 - static const char *chname[4] = { "Front", "Surround", "C/LFE", "Side" }; 4619 + static const char * const chname[4] = { 4620 + "Front", "Surround", "C/LFE", "Side" 4621 + }; 4628 4622 hda_nid_t nid_vols[] = {0x8, 0x9, 0xa, 0xb}; 4629 4623 hda_nid_t nid_mutes[] = {0x24, 0x25, 0x26, 0x27}; 4630 4624 hda_nid_t nid, nid_vol, nid_mute = 0; ··· 5075 5065 const struct auto_pin_cfg *cfg) 5076 5066 { 5077 5067 char name[32]; 5078 - static const char *chname[3] = { "Front", "Surround", "C/LFE" }; 5068 + static const char * const chname[3] = { 5069 + "Front", "Surround", "C/LFE" 5070 + }; 5079 5071 hda_nid_t nid_vols[] = {0x10, 0x11, 0x25}; 5080 5072 hda_nid_t nid_mutes[] = {0x1C, 0x18, 0x27}; 5081 5073 hda_nid_t nid, nid_vol, nid_mute;