From: Hariprasad Kelam <hariprasad.kelam@gmail.com>
To: Geoff Levand <geoff@infradead.org>,
Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
Benjamin Herrenschmidt <benh@kernel.crashing.org>,
Paul Mackerras <paulus@samba.org>,
Michael Ellerman <mpe@ellerman.id.au>,
linuxppc-dev@lists.ozlabs.org, alsa-devel@alsa-project.org,
linux-kernel@vger.kernel.org
Subject: [PATCH] sound: ppc: snd_ps3: Remove Unneeded variable: "ret"
Date: Wed, 10 Jul 2019 08:09:46 +0530 [thread overview]
Message-ID: <20190710023946.GA15604@hari-Inspiron-1545> (raw)
This patch fixes below issue reported by coccicheck
sound/ppc/snd_ps3.c:631:5-8: Unneeded variable: "ret". Return "0" on
line 668
We cannot change return type of snd_ps3_pcm_trigger as it is registered
with snd_pcm_ops->trigger
Signed-off-by: Hariprasad Kelam <hariprasad.kelam@gmail.com>
---
sound/ppc/snd_ps3.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/sound/ppc/snd_ps3.c b/sound/ppc/snd_ps3.c
index 71b7fd3..c213eb7 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,
int cmd)
{
struct snd_ps3_card_info *card = snd_pcm_substream_chip(substream);
- int ret = 0;
switch (cmd) {
case SNDRV_PCM_TRIGGER_START:
@@ -665,7 +664,7 @@ static int snd_ps3_pcm_trigger(struct snd_pcm_substream *substream,
}
- return ret;
+ return 0;
};
/*
--
2.7.4
next reply other threads:[~2019-07-10 4:27 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-10 2:39 Hariprasad Kelam [this message]
2019-07-10 9:56 ` [PATCH] sound: ppc: snd_ps3: Remove Unneeded variable: "ret" Takashi Iwai
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20190710023946.GA15604@hari-Inspiron-1545 \
--to=hariprasad.kelam@gmail.com \
--cc=alsa-devel@alsa-project.org \
--cc=benh@kernel.crashing.org \
--cc=geoff@infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=mpe@ellerman.id.au \
--cc=paulus@samba.org \
--cc=perex@perex.cz \
--cc=tiwai@suse.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox