diff options
Diffstat (limited to 'sound/pci/hda/patch_si3054.c')
-rw-r--r-- | sound/pci/hda/patch_si3054.c | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/sound/pci/hda/patch_si3054.c b/sound/pci/hda/patch_si3054.c index f419ee8d75f0..2f55f32876fa 100644 --- a/sound/pci/hda/patch_si3054.c +++ b/sound/pci/hda/patch_si3054.c | |||
@@ -130,7 +130,7 @@ static int si3054_switch_put(struct snd_kcontrol *kcontrol, | |||
130 | } | 130 | } |
131 | 131 | ||
132 | 132 | ||
133 | static struct snd_kcontrol_new si3054_modem_mixer[] = { | 133 | static const struct snd_kcontrol_new si3054_modem_mixer[] = { |
134 | SI3054_KCONTROL("Off-hook Switch", SI3054_GPIO_CONTROL, SI3054_GPIO_OH), | 134 | SI3054_KCONTROL("Off-hook Switch", SI3054_GPIO_CONTROL, SI3054_GPIO_OH), |
135 | SI3054_KCONTROL("Caller ID Switch", SI3054_GPIO_CONTROL, SI3054_GPIO_CID), | 135 | SI3054_KCONTROL("Caller ID Switch", SI3054_GPIO_CONTROL, SI3054_GPIO_CID), |
136 | {} | 136 | {} |
@@ -181,7 +181,7 @@ static int si3054_pcm_open(struct hda_pcm_stream *hinfo, | |||
181 | } | 181 | } |
182 | 182 | ||
183 | 183 | ||
184 | static struct hda_pcm_stream si3054_pcm = { | 184 | static const struct hda_pcm_stream si3054_pcm = { |
185 | .substreams = 1, | 185 | .substreams = 1, |
186 | .channels_min = 1, | 186 | .channels_min = 1, |
187 | .channels_max = 1, | 187 | .channels_max = 1, |
@@ -200,12 +200,13 @@ static int si3054_build_pcms(struct hda_codec *codec) | |||
200 | { | 200 | { |
201 | struct si3054_spec *spec = codec->spec; | 201 | struct si3054_spec *spec = codec->spec; |
202 | struct hda_pcm *info = &spec->pcm; | 202 | struct hda_pcm *info = &spec->pcm; |
203 | si3054_pcm.nid = codec->mfg; | ||
204 | codec->num_pcms = 1; | 203 | codec->num_pcms = 1; |
205 | codec->pcm_info = info; | 204 | codec->pcm_info = info; |
206 | info->name = "Si3054 Modem"; | 205 | info->name = "Si3054 Modem"; |
207 | info->stream[SNDRV_PCM_STREAM_PLAYBACK] = si3054_pcm; | 206 | info->stream[SNDRV_PCM_STREAM_PLAYBACK] = si3054_pcm; |
208 | info->stream[SNDRV_PCM_STREAM_CAPTURE] = si3054_pcm; | 207 | info->stream[SNDRV_PCM_STREAM_CAPTURE] = si3054_pcm; |
208 | info->stream[SNDRV_PCM_STREAM_PLAYBACK].nid = codec->mfg; | ||
209 | info->stream[SNDRV_PCM_STREAM_CAPTURE].nid = codec->mfg; | ||
209 | info->pcm_type = HDA_PCM_TYPE_MODEM; | 210 | info->pcm_type = HDA_PCM_TYPE_MODEM; |
210 | return 0; | 211 | return 0; |
211 | } | 212 | } |
@@ -263,7 +264,7 @@ static void si3054_free(struct hda_codec *codec) | |||
263 | /* | 264 | /* |
264 | */ | 265 | */ |
265 | 266 | ||
266 | static struct hda_codec_ops si3054_patch_ops = { | 267 | static const struct hda_codec_ops si3054_patch_ops = { |
267 | .build_controls = si3054_build_controls, | 268 | .build_controls = si3054_build_controls, |
268 | .build_pcms = si3054_build_pcms, | 269 | .build_pcms = si3054_build_pcms, |
269 | .init = si3054_init, | 270 | .init = si3054_init, |
@@ -283,7 +284,7 @@ static int patch_si3054(struct hda_codec *codec) | |||
283 | /* | 284 | /* |
284 | * patch entries | 285 | * patch entries |
285 | */ | 286 | */ |
286 | static struct hda_codec_preset snd_hda_preset_si3054[] = { | 287 | static const struct hda_codec_preset snd_hda_preset_si3054[] = { |
287 | { .id = 0x163c3055, .name = "Si3054", .patch = patch_si3054 }, | 288 | { .id = 0x163c3055, .name = "Si3054", .patch = patch_si3054 }, |
288 | { .id = 0x163c3155, .name = "Si3054", .patch = patch_si3054 }, | 289 | { .id = 0x163c3155, .name = "Si3054", .patch = patch_si3054 }, |
289 | { .id = 0x11c13026, .name = "Si3054", .patch = patch_si3054 }, | 290 | { .id = 0x11c13026, .name = "Si3054", .patch = patch_si3054 }, |