mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Roel Kluin <12o3l@tiscali.nl>
To: liam.girdwood@wolfsonmicro.com,
	broonie@opensource.wolfsonmicro.com, alsa-devel@alsa-project.org
Cc: lkml <linux-kernel@vger.kernel.org>
Subject: [PATCH] SOC: fix tests in cs4270_hw_params()
Date: Thu, 17 Apr 2008 17:45:39 +0200	[thread overview]
Message-ID: <480770A3.3070805@tiscali.nl> (raw)

cs4270_hw_params does several times:

ret = snd_soc_write()
if (ret < 0)
	...

This only works when ret is signed.

Signed-off-by: Roel Kluin <12o3l@tiscali.nl>
---
diff --git a/sound/soc/codecs/cs4270.c b/sound/soc/codecs/cs4270.c
index bf2ab72..e73fcfd 100644
--- a/sound/soc/codecs/cs4270.c
+++ b/sound/soc/codecs/cs4270.c
@@ -372,7 +372,7 @@ static int cs4270_hw_params(struct snd_pcm_substream *substream,
 	struct snd_soc_device *socdev = rtd->socdev;
 	struct snd_soc_codec *codec = socdev->codec;
 	struct cs4270_private *cs4270 = codec->private_data;
-	unsigned int ret = 0;
+	int ret;
 	unsigned int i;
 	unsigned int rate;
 	unsigned int ratio;

             reply	other threads:[~2008-04-17 15:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-17 15:45 Roel Kluin [this message]
2008-04-17 16:09 ` [alsa-devel] " 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=480770A3.3070805@tiscali.nl \
    --to=12o3l@tiscali.nl \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@opensource.wolfsonmicro.com \
    --cc=liam.girdwood@wolfsonmicro.com \
    --cc=linux-kernel@vger.kernel.org \
    /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

Powered by JetHome