diff options
author | Takashi Iwai <tiwai@suse.de> | 2011-07-07 03:28:47 -0400 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2011-07-07 03:28:47 -0400 |
commit | 8e89995c58644682302fe9e298a9e30ff38d01a1 (patch) | |
tree | efebb038c81d80c930fc1f52a398797ce8e20539 /sound | |
parent | b68785714b67079385188323631b05a8f9093675 (diff) | |
parent | 9c7a083d94656ad6d6f2e03ba90194f2cc5bced5 (diff) |
Merge branch 'fix/hda' into topic/hda
Diffstat (limited to 'sound')
-rw-r--r-- | sound/atmel/abdac.c | 2 | ||||
-rw-r--r-- | sound/atmel/ac97c.c | 2 | ||||
-rw-r--r-- | sound/pci/cs5535audio/cs5535audio_pcm.c | 4 | ||||
-rw-r--r-- | sound/pci/hda/hda_eld.c | 2 | ||||
-rw-r--r-- | sound/pci/hda/patch_realtek.c | 33 | ||||
-rw-r--r-- | sound/pci/rme9652/hdspm.c | 8 | ||||
-rw-r--r-- | sound/spi/at73c213.c | 2 |
7 files changed, 33 insertions, 20 deletions
diff --git a/sound/atmel/abdac.c b/sound/atmel/abdac.c index 6e2409181895..bfee60c4d4c0 100644 --- a/sound/atmel/abdac.c +++ b/sound/atmel/abdac.c | |||
@@ -599,4 +599,4 @@ module_exit(atmel_abdac_exit); | |||
599 | 599 | ||
600 | MODULE_LICENSE("GPL"); | 600 | MODULE_LICENSE("GPL"); |
601 | MODULE_DESCRIPTION("Driver for Atmel Audio Bitstream DAC (ABDAC)"); | 601 | MODULE_DESCRIPTION("Driver for Atmel Audio Bitstream DAC (ABDAC)"); |
602 | MODULE_AUTHOR("Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>"); | 602 | MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>"); |
diff --git a/sound/atmel/ac97c.c b/sound/atmel/ac97c.c index b310702c646e..ac35222ad0dd 100644 --- a/sound/atmel/ac97c.c +++ b/sound/atmel/ac97c.c | |||
@@ -1199,4 +1199,4 @@ module_exit(atmel_ac97c_exit); | |||
1199 | 1199 | ||
1200 | MODULE_LICENSE("GPL"); | 1200 | MODULE_LICENSE("GPL"); |
1201 | MODULE_DESCRIPTION("Driver for Atmel AC97 controller"); | 1201 | MODULE_DESCRIPTION("Driver for Atmel AC97 controller"); |
1202 | MODULE_AUTHOR("Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>"); | 1202 | MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>"); |
diff --git a/sound/pci/cs5535audio/cs5535audio_pcm.c b/sound/pci/cs5535audio/cs5535audio_pcm.c index f16bc8aad6ed..e083122ca55a 100644 --- a/sound/pci/cs5535audio/cs5535audio_pcm.c +++ b/sound/pci/cs5535audio/cs5535audio_pcm.c | |||
@@ -149,7 +149,7 @@ static int cs5535audio_build_dma_packets(struct cs5535audio *cs5535au, | |||
149 | &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[i]; | 149 | &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[i]; |
150 | desc->addr = cpu_to_le32(addr); | 150 | desc->addr = cpu_to_le32(addr); |
151 | desc->size = cpu_to_le32(period_bytes); | 151 | desc->size = cpu_to_le32(period_bytes); |
152 | desc->ctlreserved = cpu_to_le32(PRD_EOP); | 152 | desc->ctlreserved = cpu_to_le16(PRD_EOP); |
153 | desc_addr += sizeof(struct cs5535audio_dma_desc); | 153 | desc_addr += sizeof(struct cs5535audio_dma_desc); |
154 | addr += period_bytes; | 154 | addr += period_bytes; |
155 | } | 155 | } |
@@ -157,7 +157,7 @@ static int cs5535audio_build_dma_packets(struct cs5535audio *cs5535au, | |||
157 | lastdesc = &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[periods]; | 157 | lastdesc = &((struct cs5535audio_dma_desc *) dma->desc_buf.area)[periods]; |
158 | lastdesc->addr = cpu_to_le32((u32) dma->desc_buf.addr); | 158 | lastdesc->addr = cpu_to_le32((u32) dma->desc_buf.addr); |
159 | lastdesc->size = 0; | 159 | lastdesc->size = 0; |
160 | lastdesc->ctlreserved = cpu_to_le32(PRD_JMP); | 160 | lastdesc->ctlreserved = cpu_to_le16(PRD_JMP); |
161 | jmpprd_addr = cpu_to_le32(lastdesc->addr + | 161 | jmpprd_addr = cpu_to_le32(lastdesc->addr + |
162 | (sizeof(struct cs5535audio_dma_desc)*periods)); | 162 | (sizeof(struct cs5535audio_dma_desc)*periods)); |
163 | 163 | ||
diff --git a/sound/pci/hda/hda_eld.c b/sound/pci/hda/hda_eld.c index 473cfa13a30d..28ce17d09c33 100644 --- a/sound/pci/hda/hda_eld.c +++ b/sound/pci/hda/hda_eld.c | |||
@@ -294,7 +294,7 @@ static int hdmi_update_eld(struct hdmi_eld *e, | |||
294 | snd_printd(KERN_INFO "HDMI: out of range MNL %d\n", mnl); | 294 | snd_printd(KERN_INFO "HDMI: out of range MNL %d\n", mnl); |
295 | goto out_fail; | 295 | goto out_fail; |
296 | } else | 296 | } else |
297 | strlcpy(e->monitor_name, buf + ELD_FIXED_BYTES, mnl); | 297 | strlcpy(e->monitor_name, buf + ELD_FIXED_BYTES, mnl + 1); |
298 | 298 | ||
299 | for (i = 0; i < e->sad_count; i++) { | 299 | for (i = 0; i < e->sad_count; i++) { |
300 | if (ELD_FIXED_BYTES + mnl + 3 * (i + 1) > size) { | 300 | if (ELD_FIXED_BYTES + mnl + 3 * (i + 1) > size) { |
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c index 575ffc9fedbd..49f39699ea1b 100644 --- a/sound/pci/hda/patch_realtek.c +++ b/sound/pci/hda/patch_realtek.c | |||
@@ -2707,17 +2707,30 @@ typedef int (*getput_call_t)(struct snd_kcontrol *kcontrol, | |||
2707 | 2707 | ||
2708 | static int alc_cap_getput_caller(struct snd_kcontrol *kcontrol, | 2708 | static int alc_cap_getput_caller(struct snd_kcontrol *kcontrol, |
2709 | struct snd_ctl_elem_value *ucontrol, | 2709 | struct snd_ctl_elem_value *ucontrol, |
2710 | getput_call_t func) | 2710 | getput_call_t func, bool check_adc_switch) |
2711 | { | 2711 | { |
2712 | struct hda_codec *codec = snd_kcontrol_chip(kcontrol); | 2712 | struct hda_codec *codec = snd_kcontrol_chip(kcontrol); |
2713 | struct alc_spec *spec = codec->spec; | 2713 | struct alc_spec *spec = codec->spec; |
2714 | unsigned int adc_idx = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); | 2714 | int i, err; |
2715 | int err; | ||
2716 | 2715 | ||
2717 | mutex_lock(&codec->control_mutex); | 2716 | mutex_lock(&codec->control_mutex); |
2718 | kcontrol->private_value = HDA_COMPOSE_AMP_VAL(spec->adc_nids[adc_idx], | 2717 | if (check_adc_switch && spec->dual_adc_switch) { |
2719 | 3, 0, HDA_INPUT); | 2718 | for (i = 0; i < spec->num_adc_nids; i++) { |
2720 | err = func(kcontrol, ucontrol); | 2719 | kcontrol->private_value = |
2720 | HDA_COMPOSE_AMP_VAL(spec->adc_nids[i], | ||
2721 | 3, 0, HDA_INPUT); | ||
2722 | err = func(kcontrol, ucontrol); | ||
2723 | if (err < 0) | ||
2724 | goto error; | ||
2725 | } | ||
2726 | } else { | ||
2727 | i = snd_ctl_get_ioffidx(kcontrol, &ucontrol->id); | ||
2728 | kcontrol->private_value = | ||
2729 | HDA_COMPOSE_AMP_VAL(spec->adc_nids[i], | ||
2730 | 3, 0, HDA_INPUT); | ||
2731 | err = func(kcontrol, ucontrol); | ||
2732 | } | ||
2733 | error: | ||
2721 | mutex_unlock(&codec->control_mutex); | 2734 | mutex_unlock(&codec->control_mutex); |
2722 | return err; | 2735 | return err; |
2723 | } | 2736 | } |
@@ -2726,14 +2739,14 @@ static int alc_cap_vol_get(struct snd_kcontrol *kcontrol, | |||
2726 | struct snd_ctl_elem_value *ucontrol) | 2739 | struct snd_ctl_elem_value *ucontrol) |
2727 | { | 2740 | { |
2728 | return alc_cap_getput_caller(kcontrol, ucontrol, | 2741 | return alc_cap_getput_caller(kcontrol, ucontrol, |
2729 | snd_hda_mixer_amp_volume_get); | 2742 | snd_hda_mixer_amp_volume_get, false); |
2730 | } | 2743 | } |
2731 | 2744 | ||
2732 | static int alc_cap_vol_put(struct snd_kcontrol *kcontrol, | 2745 | static int alc_cap_vol_put(struct snd_kcontrol *kcontrol, |
2733 | struct snd_ctl_elem_value *ucontrol) | 2746 | struct snd_ctl_elem_value *ucontrol) |
2734 | { | 2747 | { |
2735 | return alc_cap_getput_caller(kcontrol, ucontrol, | 2748 | return alc_cap_getput_caller(kcontrol, ucontrol, |
2736 | snd_hda_mixer_amp_volume_put); | 2749 | snd_hda_mixer_amp_volume_put, true); |
2737 | } | 2750 | } |
2738 | 2751 | ||
2739 | /* capture mixer elements */ | 2752 | /* capture mixer elements */ |
@@ -2743,14 +2756,14 @@ static int alc_cap_sw_get(struct snd_kcontrol *kcontrol, | |||
2743 | struct snd_ctl_elem_value *ucontrol) | 2756 | struct snd_ctl_elem_value *ucontrol) |
2744 | { | 2757 | { |
2745 | return alc_cap_getput_caller(kcontrol, ucontrol, | 2758 | return alc_cap_getput_caller(kcontrol, ucontrol, |
2746 | snd_hda_mixer_amp_switch_get); | 2759 | snd_hda_mixer_amp_switch_get, false); |
2747 | } | 2760 | } |
2748 | 2761 | ||
2749 | static int alc_cap_sw_put(struct snd_kcontrol *kcontrol, | 2762 | static int alc_cap_sw_put(struct snd_kcontrol *kcontrol, |
2750 | struct snd_ctl_elem_value *ucontrol) | 2763 | struct snd_ctl_elem_value *ucontrol) |
2751 | { | 2764 | { |
2752 | return alc_cap_getput_caller(kcontrol, ucontrol, | 2765 | return alc_cap_getput_caller(kcontrol, ucontrol, |
2753 | snd_hda_mixer_amp_switch_put); | 2766 | snd_hda_mixer_amp_switch_put, true); |
2754 | } | 2767 | } |
2755 | 2768 | ||
2756 | #define _DEFINE_CAPMIX(num) \ | 2769 | #define _DEFINE_CAPMIX(num) \ |
diff --git a/sound/pci/rme9652/hdspm.c b/sound/pci/rme9652/hdspm.c index 3f08afc0f0d3..c8e402fc3782 100644 --- a/sound/pci/rme9652/hdspm.c +++ b/sound/pci/rme9652/hdspm.c | |||
@@ -896,11 +896,11 @@ struct hdspm { | |||
896 | unsigned char max_channels_in; | 896 | unsigned char max_channels_in; |
897 | unsigned char max_channels_out; | 897 | unsigned char max_channels_out; |
898 | 898 | ||
899 | char *channel_map_in; | 899 | signed char *channel_map_in; |
900 | char *channel_map_out; | 900 | signed char *channel_map_out; |
901 | 901 | ||
902 | char *channel_map_in_ss, *channel_map_in_ds, *channel_map_in_qs; | 902 | signed char *channel_map_in_ss, *channel_map_in_ds, *channel_map_in_qs; |
903 | char *channel_map_out_ss, *channel_map_out_ds, *channel_map_out_qs; | 903 | signed char *channel_map_out_ss, *channel_map_out_ds, *channel_map_out_qs; |
904 | 904 | ||
905 | char **port_names_in; | 905 | char **port_names_in; |
906 | char **port_names_out; | 906 | char **port_names_out; |
diff --git a/sound/spi/at73c213.c b/sound/spi/at73c213.c index 337a00241a1f..4dd051bdf4fd 100644 --- a/sound/spi/at73c213.c +++ b/sound/spi/at73c213.c | |||
@@ -1124,6 +1124,6 @@ static void __exit at73c213_exit(void) | |||
1124 | } | 1124 | } |
1125 | module_exit(at73c213_exit); | 1125 | module_exit(at73c213_exit); |
1126 | 1126 | ||
1127 | MODULE_AUTHOR("Hans-Christian Egtvedt <hcegtvedt@atmel.com>"); | 1127 | MODULE_AUTHOR("Hans-Christian Egtvedt <egtvedt@samfundet.no>"); |
1128 | MODULE_DESCRIPTION("Sound driver for AT73C213 with Atmel SSC"); | 1128 | MODULE_DESCRIPTION("Sound driver for AT73C213 with Atmel SSC"); |
1129 | MODULE_LICENSE("GPL"); | 1129 | MODULE_LICENSE("GPL"); |