aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2019-07-18 12:36:51 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2019-07-18 12:36:51 -0400
commit2ae048e16636afd7521270acacb08d9c42fd23f0 (patch)
tree3e54f7a87c43213efdfd1b911c1caa128c4a98da
parentd0411ec8ca6b98061023873e334323ef102100cc (diff)
parent4914da2fb0c89205790503f20dfdde854f3afdd8 (diff)
Merge tag 'sound-fix-5.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound
Pull sound fixes from Takashi Iwai: "A collection of small fixes. - The optimization of PM resume with HD-audio HDMI codecs, which eventually work around weird issues - A correction of Intel Icelake HDMI audio code - Quirks for Dell machines with Realtek HD-audio codecs - The fix for too long sequencer write stall that was spotted by syzkaller - A few trivial cleanups reported by coccinelle" * tag 'sound-fix-5.3-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound: ALSA: hda - Don't resume forcibly i915 HDMI/DP codec ALSA: hda/hdmi - Fix i915 reverse port/pin mapping ALSA: hda/hdmi - Remove duplicated define ALSA: seq: Break too long mutex context in the write loop ALSA: hda/realtek: apply ALC891 headset fixup to one Dell machine ALSA: rme9652: Unneeded variable: "result". ALSA: emu10k1: Remove unneeded variable "change" ALSA: au88x0: Remove unneeded variable: "changed" ALSA: hda/realtek - Fixed Headphone Mic can't record on Dell platform ALSA: ps3: Remove Unneeded variable: "ret" ALSA: lx6464es: Remove unneeded variable err
-rw-r--r--include/sound/hda_codec.h2
-rw-r--r--sound/core/seq/seq_clientmgr.c11
-rw-r--r--sound/pci/au88x0/au88x0_a3d.c15
-rw-r--r--sound/pci/emu10k1/emu10k1x.c3
-rw-r--r--sound/pci/hda/hda_codec.c8
-rw-r--r--sound/pci/hda/patch_hdmi.c31
-rw-r--r--sound/pci/hda/patch_realtek.c10
-rw-r--r--sound/pci/lx6464es/lx6464es.c3
-rw-r--r--sound/pci/rme9652/rme9652.c3
-rw-r--r--sound/ppc/snd_ps3.c3
10 files changed, 62 insertions, 27 deletions
diff --git a/include/sound/hda_codec.h b/include/sound/hda_codec.h
index 8f46ff3449d5..871993696c5f 100644
--- a/include/sound/hda_codec.h
+++ b/include/sound/hda_codec.h
@@ -252,6 +252,8 @@ struct hda_codec {
252 unsigned int auto_runtime_pm:1; /* enable automatic codec runtime pm */ 252 unsigned int auto_runtime_pm:1; /* enable automatic codec runtime pm */
253 unsigned int force_pin_prefix:1; /* Add location prefix */ 253 unsigned int force_pin_prefix:1; /* Add location prefix */
254 unsigned int link_down_at_suspend:1; /* link down at runtime suspend */ 254 unsigned int link_down_at_suspend:1; /* link down at runtime suspend */
255 unsigned int relaxed_resume:1; /* don't resume forcibly for jack */
256
255#ifdef CONFIG_PM 257#ifdef CONFIG_PM
256 unsigned long power_on_acct; 258 unsigned long power_on_acct;
257 unsigned long power_off_acct; 259 unsigned long power_off_acct;
diff --git a/sound/core/seq/seq_clientmgr.c b/sound/core/seq/seq_clientmgr.c
index a60e7a17f0b8..7737b2670064 100644
--- a/sound/core/seq/seq_clientmgr.c
+++ b/sound/core/seq/seq_clientmgr.c
@@ -1021,7 +1021,7 @@ static ssize_t snd_seq_write(struct file *file, const char __user *buf,
1021{ 1021{
1022 struct snd_seq_client *client = file->private_data; 1022 struct snd_seq_client *client = file->private_data;
1023 int written = 0, len; 1023 int written = 0, len;
1024 int err; 1024 int err, handled;
1025 struct snd_seq_event event; 1025 struct snd_seq_event event;
1026 1026
1027 if (!(snd_seq_file_flags(file) & SNDRV_SEQ_LFLG_OUTPUT)) 1027 if (!(snd_seq_file_flags(file) & SNDRV_SEQ_LFLG_OUTPUT))
@@ -1034,6 +1034,8 @@ static ssize_t snd_seq_write(struct file *file, const char __user *buf,
1034 if (!client->accept_output || client->pool == NULL) 1034 if (!client->accept_output || client->pool == NULL)
1035 return -ENXIO; 1035 return -ENXIO;
1036 1036
1037 repeat:
1038 handled = 0;
1037 /* allocate the pool now if the pool is not allocated yet */ 1039 /* allocate the pool now if the pool is not allocated yet */
1038 mutex_lock(&client->ioctl_mutex); 1040 mutex_lock(&client->ioctl_mutex);
1039 if (client->pool->size > 0 && !snd_seq_write_pool_allocated(client)) { 1041 if (client->pool->size > 0 && !snd_seq_write_pool_allocated(client)) {
@@ -1093,12 +1095,19 @@ static ssize_t snd_seq_write(struct file *file, const char __user *buf,
1093 0, 0, &client->ioctl_mutex); 1095 0, 0, &client->ioctl_mutex);
1094 if (err < 0) 1096 if (err < 0)
1095 break; 1097 break;
1098 handled++;
1096 1099
1097 __skip_event: 1100 __skip_event:
1098 /* Update pointers and counts */ 1101 /* Update pointers and counts */
1099 count -= len; 1102 count -= len;
1100 buf += len; 1103 buf += len;
1101 written += len; 1104 written += len;
1105
1106 /* let's have a coffee break if too many events are queued */
1107 if (++handled >= 200) {
1108 mutex_unlock(&client->ioctl_mutex);
1109 goto repeat;
1110 }
1102 } 1111 }
1103 1112
1104 out: 1113 out:
diff --git a/sound/pci/au88x0/au88x0_a3d.c b/sound/pci/au88x0/au88x0_a3d.c
index 73471037d59f..2db183f8826a 100644
--- a/sound/pci/au88x0/au88x0_a3d.c
+++ b/sound/pci/au88x0/au88x0_a3d.c
@@ -765,7 +765,7 @@ snd_vortex_a3d_hrtf_put(struct snd_kcontrol *kcontrol,
765 struct snd_ctl_elem_value *ucontrol) 765 struct snd_ctl_elem_value *ucontrol)
766{ 766{
767 a3dsrc_t *a = kcontrol->private_data; 767 a3dsrc_t *a = kcontrol->private_data;
768 int changed = 1, i; 768 int i;
769 int coord[6]; 769 int coord[6];
770 for (i = 0; i < 6; i++) 770 for (i = 0; i < 6; i++)
771 coord[i] = ucontrol->value.integer.value[i]; 771 coord[i] = ucontrol->value.integer.value[i];
@@ -774,7 +774,7 @@ snd_vortex_a3d_hrtf_put(struct snd_kcontrol *kcontrol,
774 vortex_a3d_coord2hrtf(a->hrtf[1], coord); 774 vortex_a3d_coord2hrtf(a->hrtf[1], coord);
775 a3dsrc_SetHrtfTarget(a, a->hrtf[0], a->hrtf[1]); 775 a3dsrc_SetHrtfTarget(a, a->hrtf[0], a->hrtf[1]);
776 a3dsrc_SetHrtfCurrent(a, a->hrtf[0], a->hrtf[1]); 776 a3dsrc_SetHrtfCurrent(a, a->hrtf[0], a->hrtf[1]);
777 return changed; 777 return 1;
778} 778}
779 779
780static int 780static int
@@ -783,7 +783,7 @@ snd_vortex_a3d_itd_put(struct snd_kcontrol *kcontrol,
783{ 783{
784 a3dsrc_t *a = kcontrol->private_data; 784 a3dsrc_t *a = kcontrol->private_data;
785 int coord[6]; 785 int coord[6];
786 int i, changed = 1; 786 int i;
787 for (i = 0; i < 6; i++) 787 for (i = 0; i < 6; i++)
788 coord[i] = ucontrol->value.integer.value[i]; 788 coord[i] = ucontrol->value.integer.value[i];
789 /* Translate orientation coordinates to a3d params. */ 789 /* Translate orientation coordinates to a3d params. */
@@ -793,7 +793,7 @@ snd_vortex_a3d_itd_put(struct snd_kcontrol *kcontrol,
793 a3dsrc_SetItdTarget(a, a->itd[0], a->itd[1]); 793 a3dsrc_SetItdTarget(a, a->itd[0], a->itd[1]);
794 a3dsrc_SetItdCurrent(a, a->itd[0], a->itd[1]); 794 a3dsrc_SetItdCurrent(a, a->itd[0], a->itd[1]);
795 a3dsrc_SetItdDline(a, a->dline); 795 a3dsrc_SetItdDline(a, a->dline);
796 return changed; 796 return 1;
797} 797}
798 798
799static int 799static int
@@ -801,7 +801,6 @@ snd_vortex_a3d_ild_put(struct snd_kcontrol *kcontrol,
801 struct snd_ctl_elem_value *ucontrol) 801 struct snd_ctl_elem_value *ucontrol)
802{ 802{
803 a3dsrc_t *a = kcontrol->private_data; 803 a3dsrc_t *a = kcontrol->private_data;
804 int changed = 1;
805 int l, r; 804 int l, r;
806 /* There may be some scale tranlation needed here. */ 805 /* There may be some scale tranlation needed here. */
807 l = ucontrol->value.integer.value[0]; 806 l = ucontrol->value.integer.value[0];
@@ -810,7 +809,7 @@ snd_vortex_a3d_ild_put(struct snd_kcontrol *kcontrol,
810 /* Left Right panning. */ 809 /* Left Right panning. */
811 a3dsrc_SetGainTarget(a, l, r); 810 a3dsrc_SetGainTarget(a, l, r);
812 a3dsrc_SetGainCurrent(a, l, r); 811 a3dsrc_SetGainCurrent(a, l, r);
813 return changed; 812 return 1;
814} 813}
815 814
816static int 815static int
@@ -818,7 +817,7 @@ snd_vortex_a3d_filter_put(struct snd_kcontrol *kcontrol,
818 struct snd_ctl_elem_value *ucontrol) 817 struct snd_ctl_elem_value *ucontrol)
819{ 818{
820 a3dsrc_t *a = kcontrol->private_data; 819 a3dsrc_t *a = kcontrol->private_data;
821 int i, changed = 1; 820 int i;
822 int params[6]; 821 int params[6];
823 for (i = 0; i < 6; i++) 822 for (i = 0; i < 6; i++)
824 params[i] = ucontrol->value.integer.value[i]; 823 params[i] = ucontrol->value.integer.value[i];
@@ -831,7 +830,7 @@ snd_vortex_a3d_filter_put(struct snd_kcontrol *kcontrol,
831 a3dsrc_SetAtmosCurrent(a, a->filter[0], 830 a3dsrc_SetAtmosCurrent(a, a->filter[0],
832 a->filter[1], a->filter[2], 831 a->filter[1], a->filter[2],
833 a->filter[3], a->filter[4]); 832 a->filter[3], a->filter[4]);
834 return changed; 833 return 1;
835} 834}
836 835
837static const struct snd_kcontrol_new vortex_a3d_kcontrol = { 836static const struct snd_kcontrol_new vortex_a3d_kcontrol = {
diff --git a/sound/pci/emu10k1/emu10k1x.c b/sound/pci/emu10k1/emu10k1x.c
index 67d6473ab0cd..9cf81832259c 100644
--- a/sound/pci/emu10k1/emu10k1x.c
+++ b/sound/pci/emu10k1/emu10k1x.c
@@ -1074,7 +1074,6 @@ static int snd_emu10k1x_shared_spdif_put(struct snd_kcontrol *kcontrol,
1074{ 1074{
1075 struct emu10k1x *emu = snd_kcontrol_chip(kcontrol); 1075 struct emu10k1x *emu = snd_kcontrol_chip(kcontrol);
1076 unsigned int val; 1076 unsigned int val;
1077 int change = 0;
1078 1077
1079 val = ucontrol->value.integer.value[0] ; 1078 val = ucontrol->value.integer.value[0] ;
1080 1079
@@ -1089,7 +1088,7 @@ static int snd_emu10k1x_shared_spdif_put(struct snd_kcontrol *kcontrol,
1089 snd_emu10k1x_ptr_write(emu, ROUTING, 0, 0x1003F); 1088 snd_emu10k1x_ptr_write(emu, ROUTING, 0, 0x1003F);
1090 snd_emu10k1x_gpio_write(emu, 0x1080); 1089 snd_emu10k1x_gpio_write(emu, 0x1080);
1091 } 1090 }
1092 return change; 1091 return 0;
1093} 1092}
1094 1093
1095static const struct snd_kcontrol_new snd_emu10k1x_shared_spdif = 1094static const struct snd_kcontrol_new snd_emu10k1x_shared_spdif =
diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 5346631df1ec..e30e86ca6b72 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -2941,15 +2941,19 @@ static int hda_codec_runtime_resume(struct device *dev)
2941#ifdef CONFIG_PM_SLEEP 2941#ifdef CONFIG_PM_SLEEP
2942static int hda_codec_force_resume(struct device *dev) 2942static int hda_codec_force_resume(struct device *dev)
2943{ 2943{
2944 struct hda_codec *codec = dev_to_hda_codec(dev);
2945 bool forced_resume = !codec->relaxed_resume;
2944 int ret; 2946 int ret;
2945 2947
2946 /* The get/put pair below enforces the runtime resume even if the 2948 /* The get/put pair below enforces the runtime resume even if the
2947 * device hasn't been used at suspend time. This trick is needed to 2949 * device hasn't been used at suspend time. This trick is needed to
2948 * update the jack state change during the sleep. 2950 * update the jack state change during the sleep.
2949 */ 2951 */
2950 pm_runtime_get_noresume(dev); 2952 if (forced_resume)
2953 pm_runtime_get_noresume(dev);
2951 ret = pm_runtime_force_resume(dev); 2954 ret = pm_runtime_force_resume(dev);
2952 pm_runtime_put(dev); 2955 if (forced_resume)
2956 pm_runtime_put(dev);
2953 return ret; 2957 return ret;
2954} 2958}
2955 2959
diff --git a/sound/pci/hda/patch_hdmi.c b/sound/pci/hda/patch_hdmi.c
index 40323d91f9e4..bea7b0961080 100644
--- a/sound/pci/hda/patch_hdmi.c
+++ b/sound/pci/hda/patch_hdmi.c
@@ -2292,8 +2292,10 @@ static void generic_hdmi_free(struct hda_codec *codec)
2292 struct hdmi_spec *spec = codec->spec; 2292 struct hdmi_spec *spec = codec->spec;
2293 int pin_idx, pcm_idx; 2293 int pin_idx, pcm_idx;
2294 2294
2295 if (codec_has_acomp(codec)) 2295 if (codec_has_acomp(codec)) {
2296 snd_hdac_acomp_register_notifier(&codec->bus->core, NULL); 2296 snd_hdac_acomp_register_notifier(&codec->bus->core, NULL);
2297 codec->relaxed_resume = 0;
2298 }
2297 2299
2298 for (pin_idx = 0; pin_idx < spec->num_pins; pin_idx++) { 2300 for (pin_idx = 0; pin_idx < spec->num_pins; pin_idx++) {
2299 struct hdmi_spec_per_pin *per_pin = get_pin(spec, pin_idx); 2301 struct hdmi_spec_per_pin *per_pin = get_pin(spec, pin_idx);
@@ -2417,7 +2419,6 @@ static void intel_haswell_fixup_connect_list(struct hda_codec *codec,
2417} 2419}
2418 2420
2419#define INTEL_GET_VENDOR_VERB 0xf81 2421#define INTEL_GET_VENDOR_VERB 0xf81
2420#define INTEL_GET_VENDOR_VERB 0xf81
2421#define INTEL_SET_VENDOR_VERB 0x781 2422#define INTEL_SET_VENDOR_VERB 0x781
2422#define INTEL_EN_DP12 0x02 /* enable DP 1.2 features */ 2423#define INTEL_EN_DP12 0x02 /* enable DP 1.2 features */
2423#define INTEL_EN_ALL_PIN_CVTS 0x01 /* enable 2nd & 3rd pins and convertors */ 2424#define INTEL_EN_ALL_PIN_CVTS 0x01 /* enable 2nd & 3rd pins and convertors */
@@ -2525,18 +2526,32 @@ static int intel_pin2port(void *audio_ptr, int pin_nid)
2525 return -1; 2526 return -1;
2526} 2527}
2527 2528
2529static int intel_port2pin(struct hda_codec *codec, int port)
2530{
2531 struct hdmi_spec *spec = codec->spec;
2532
2533 if (!spec->port_num) {
2534 /* we assume only from port-B to port-D */
2535 if (port < 1 || port > 3)
2536 return 0;
2537 /* intel port is 1-based */
2538 return port + intel_base_nid(codec) - 1;
2539 }
2540
2541 if (port < 1 || port > spec->port_num)
2542 return 0;
2543 return spec->port_map[port - 1];
2544}
2545
2528static void intel_pin_eld_notify(void *audio_ptr, int port, int pipe) 2546static void intel_pin_eld_notify(void *audio_ptr, int port, int pipe)
2529{ 2547{
2530 struct hda_codec *codec = audio_ptr; 2548 struct hda_codec *codec = audio_ptr;
2531 int pin_nid; 2549 int pin_nid;
2532 int dev_id = pipe; 2550 int dev_id = pipe;
2533 2551
2534 /* we assume only from port-B to port-D */ 2552 pin_nid = intel_port2pin(codec, port);
2535 if (port < 1 || port > 3) 2553 if (!pin_nid)
2536 return; 2554 return;
2537
2538 pin_nid = port + intel_base_nid(codec) - 1; /* intel port is 1-based */
2539
2540 /* skip notification during system suspend (but not in runtime PM); 2555 /* skip notification during system suspend (but not in runtime PM);
2541 * the state will be updated at resume 2556 * the state will be updated at resume
2542 */ 2557 */
@@ -2566,6 +2581,8 @@ static void register_i915_notifier(struct hda_codec *codec)
2566 spec->drm_audio_ops.pin_eld_notify = intel_pin_eld_notify; 2581 spec->drm_audio_ops.pin_eld_notify = intel_pin_eld_notify;
2567 snd_hdac_acomp_register_notifier(&codec->bus->core, 2582 snd_hdac_acomp_register_notifier(&codec->bus->core,
2568 &spec->drm_audio_ops); 2583 &spec->drm_audio_ops);
2584 /* no need for forcible resume for jack check thanks to notifier */
2585 codec->relaxed_resume = 1;
2569} 2586}
2570 2587
2571/* setup_stream ops override for HSW+ */ 2588/* setup_stream ops override for HSW+ */
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index f24a757f8239..de224cbea7a0 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -7657,9 +7657,12 @@ static const struct snd_hda_pin_quirk alc269_pin_fixup_tbl[] = {
7657 {0x12, 0x90a60130}, 7657 {0x12, 0x90a60130},
7658 {0x17, 0x90170110}, 7658 {0x17, 0x90170110},
7659 {0x21, 0x03211020}), 7659 {0x21, 0x03211020}),
7660 SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, 7660 SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
7661 {0x14, 0x90170110}, 7661 {0x14, 0x90170110},
7662 {0x21, 0x04211020}), 7662 {0x21, 0x04211020}),
7663 SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL4_MIC_NO_PRESENCE,
7664 {0x14, 0x90170110},
7665 {0x21, 0x04211030}),
7663 SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE, 7666 SND_HDA_PIN_QUIRK(0x10ec0295, 0x1028, "Dell", ALC269_FIXUP_DELL1_MIC_NO_PRESENCE,
7664 ALC295_STANDARD_PINS, 7667 ALC295_STANDARD_PINS,
7665 {0x17, 0x21014020}, 7668 {0x17, 0x21014020},
@@ -8800,6 +8803,11 @@ static const struct snd_hda_pin_quirk alc662_pin_fixup_tbl[] = {
8800 {0x18, 0x01a19030}, 8803 {0x18, 0x01a19030},
8801 {0x1a, 0x01813040}, 8804 {0x1a, 0x01813040},
8802 {0x21, 0x01014020}), 8805 {0x21, 0x01014020}),
8806 SND_HDA_PIN_QUIRK(0x10ec0867, 0x1028, "Dell", ALC891_FIXUP_DELL_MIC_NO_PRESENCE,
8807 {0x16, 0x01813030},
8808 {0x17, 0x02211010},
8809 {0x18, 0x01a19040},
8810 {0x21, 0x01014020}),
8803 SND_HDA_PIN_QUIRK(0x10ec0662, 0x1028, "Dell", ALC662_FIXUP_DELL_MIC_NO_PRESENCE, 8811 SND_HDA_PIN_QUIRK(0x10ec0662, 0x1028, "Dell", ALC662_FIXUP_DELL_MIC_NO_PRESENCE,
8804 {0x14, 0x01014010}, 8812 {0x14, 0x01014010},
8805 {0x18, 0x01a19020}, 8813 {0x18, 0x01a19020},
diff --git a/sound/pci/lx6464es/lx6464es.c b/sound/pci/lx6464es/lx6464es.c
index 1771a6dcbe18..583ca7384d83 100644
--- a/sound/pci/lx6464es/lx6464es.c
+++ b/sound/pci/lx6464es/lx6464es.c
@@ -253,9 +253,8 @@ exit:
253 253
254static int lx_pcm_close(struct snd_pcm_substream *substream) 254static int lx_pcm_close(struct snd_pcm_substream *substream)
255{ 255{
256 int err = 0;
257 dev_dbg(substream->pcm->card->dev, "->lx_pcm_close\n"); 256 dev_dbg(substream->pcm->card->dev, "->lx_pcm_close\n");
258 return err; 257 return 0;
259} 258}
260 259
261static snd_pcm_uframes_t lx_pcm_stream_pointer(struct snd_pcm_substream 260static snd_pcm_uframes_t lx_pcm_stream_pointer(struct snd_pcm_substream
diff --git a/sound/pci/rme9652/rme9652.c b/sound/pci/rme9652/rme9652.c
index cb9818af5b41..4c851f8dcaf8 100644
--- a/sound/pci/rme9652/rme9652.c
+++ b/sound/pci/rme9652/rme9652.c
@@ -2158,13 +2158,12 @@ static int snd_rme9652_prepare(struct snd_pcm_substream *substream)
2158{ 2158{
2159 struct snd_rme9652 *rme9652 = snd_pcm_substream_chip(substream); 2159 struct snd_rme9652 *rme9652 = snd_pcm_substream_chip(substream);
2160 unsigned long flags; 2160 unsigned long flags;
2161 int result = 0;
2162 2161
2163 spin_lock_irqsave(&rme9652->lock, flags); 2162 spin_lock_irqsave(&rme9652->lock, flags);
2164 if (!rme9652->running) 2163 if (!rme9652->running)
2165 rme9652_reset_hw_pointer(rme9652); 2164 rme9652_reset_hw_pointer(rme9652);
2166 spin_unlock_irqrestore(&rme9652->lock, flags); 2165 spin_unlock_irqrestore(&rme9652->lock, flags);
2167 return result; 2166 return 0;
2168} 2167}
2169 2168
2170static const struct snd_pcm_hardware snd_rme9652_playback_subinfo = 2169static const struct snd_pcm_hardware snd_rme9652_playback_subinfo =
diff --git a/sound/ppc/snd_ps3.c b/sound/ppc/snd_ps3.c
index 71b7fd344c58..c213eb7ca23c 100644
--- a/sound/ppc/snd_ps3.c
+++ b/sound/ppc/snd_ps3.c
@@ -628,7 +628,6 @@ static int snd_ps3_pcm_trigger(struct snd_pcm_substream *substream,
628 int cmd) 628 int cmd)
629{ 629{
630 struct snd_ps3_card_info *card = snd_pcm_substream_chip(substream); 630 struct snd_ps3_card_info *card = snd_pcm_substream_chip(substream);
631 int ret = 0;
632 631
633 switch (cmd) { 632 switch (cmd) {
634 case SNDRV_PCM_TRIGGER_START: 633 case SNDRV_PCM_TRIGGER_START:
@@ -665,7 +664,7 @@ static int snd_ps3_pcm_trigger(struct snd_pcm_substream *substream,
665 664
666 } 665 }
667 666
668 return ret; 667 return 0;
669}; 668};
670 669
671/* 670/*