From patchwork Thu Apr 3 09:10:54 2014
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
X-Patchwork-Submitter: Xiubo Li
X-Patchwork-Id: 3932201
Return-Path:
X-Original-To: patchwork-alsa-devel@patchwork.kernel.org
Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org
Received: from mail.kernel.org (mail.kernel.org [198.145.19.201])
by patchwork1.web.kernel.org (Postfix) with ESMTP id 38B499F2F7
for ;
Thu, 3 Apr 2014 09:56:42 +0000 (UTC)
Received: from mail.kernel.org (localhost [127.0.0.1])
by mail.kernel.org (Postfix) with ESMTP id 66FA92034F
for ;
Thu, 3 Apr 2014 09:56:41 +0000 (UTC)
Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243])
by mail.kernel.org (Postfix) with ESMTP id 10CB22026D
for ;
Thu, 3 Apr 2014 09:56:40 +0000 (UTC)
Received: by alsa0.perex.cz (Postfix, from userid 1000)
id 2311626568B; Thu, 3 Apr 2014 11:56:38 +0200 (CEST)
X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org
X-Spam-Status: No, score=-0.6 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY,
UNRESOLVED_TEMPLATE autolearn=no version=3.3.1
Received: from alsa0.perex.cz (localhost [IPv6:::1])
by alsa0.perex.cz (Postfix) with ESMTP id 18FEB265696;
Thu, 3 Apr 2014 11:55:20 +0200 (CEST)
X-Original-To: alsa-devel@alsa-project.org
Delivered-To: alsa-devel@alsa-project.org
Received: by alsa0.perex.cz (Postfix, from userid 1000)
id 2E2CD265696; Thu, 3 Apr 2014 11:55:19 +0200 (CEST)
Received: from va3outboundpool.messaging.microsoft.com
(va3ehsobe004.messaging.microsoft.com [216.32.180.14])
by alsa0.perex.cz (Postfix) with ESMTP id 63668265687
for ;
Thu, 3 Apr 2014 11:54:19 +0200 (CEST)
Received: from mail103-va3-R.bigfish.com (10.7.14.241) by
VA3EHSOBE004.bigfish.com (10.7.40.24) with Microsoft SMTP Server id
14.1.225.22; Thu, 3 Apr 2014 09:54:18 +0000
Received: from mail103-va3 (localhost [127.0.0.1]) by
mail103-va3-R.bigfish.com (Postfix) with ESMTP id 55F593E03FB;
Thu, 3 Apr 2014 09:54:18 +0000 (UTC)
X-Forefront-Antispam-Report: CIP:70.37.183.190; KIP:(null); UIP:(null);
IPV:NLI;
H:mail.freescale.net; RD:none; EFVD:NLI
X-SpamScore: 0
X-BigFish:
VS0(zzzz1f42h2148h1ee6h1de0h1fdah2073h2146h1202h1e76h2189h1d1ah1d2ah21bch1fc6h208chzdchz1de098h8275bh1de097hz2dh2a8h839he5bhf0ah1288h12a5h12a9h12bdh12e5h137ah139eh13b6h1441h1504h1537h162dh1631h1758h1898h18e1h1946h19b5h1ad9h1b0ah1b2fh2222h224fh1fb3h1d0ch1d2eh1d3fh1dfeh1dffh1e23h1fe8h1ff5h2218h2216h226dh22d0h24afh2327h2336h2438h2461h2487h24d7h2516h2545h255eh25cch25f6h2605h268bh26d3h1155h)
Received: from mail103-va3 (localhost.localdomain [127.0.0.1]) by mail103-va3
(MessageSwitch) id 139651885799846_7478;
Thu, 3 Apr 2014 09:54:17 +0000 (UTC)
Received: from VA3EHSMHS041.bigfish.com (unknown [10.7.14.249]) by
mail103-va3.bigfish.com (Postfix) with ESMTP id 0FBF03A0073;
Thu, 3 Apr 2014 09:54:17 +0000 (UTC)
Received: from mail.freescale.net (70.37.183.190) by VA3EHSMHS041.bigfish.com
(10.7.99.51) with Microsoft SMTP Server (TLS) id 14.16.227.3;
Thu, 3 Apr 2014 09:54:16 +0000
Received: from tx30smr01.am.freescale.net (10.81.153.31) by
039-SN1MMR1-003.039d.mgd.msft.net (10.84.1.16) with Microsoft SMTP
Server (TLS) id 14.3.158.2; Thu, 3 Apr 2014 09:54:15 +0000
Received: from rock.am.freescale.net (rock.ap.freescale.net [10.193.20.106])
by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id
s339s9cW025509; Thu, 3 Apr 2014 02:54:13 -0700
From: Xiubo Li
To: , , ,
Date: Thu, 3 Apr 2014 17:10:54 +0800
Message-ID: <1396516257-25354-2-git-send-email-Li.Xiubo@freescale.com>
X-Mailer: git-send-email 1.8.0
In-Reply-To: <1396516257-25354-1-git-send-email-Li.Xiubo@freescale.com>
References: <1396516257-25354-1-git-send-email-Li.Xiubo@freescale.com>
MIME-Version: 1.0
X-OriginatorOrg: freescale.com
X-FOPE-CONNECTOR: Id%0$Dn%*$RO%0$TLS%0$FQDN%$TlsDn%
X-FOPE-CONNECTOR:
Id%0$Dn%FREESCALE.MAIL.ONMICROSOFT.COM$RO%1$TLS%0$FQDN%$TlsDn%
Cc: alsa-devel@alsa-project.org, Xiubo Li
Subject: [alsa-devel] [PATCH 1/4] ASoC: esai: fix buggy of 'ret' type
definition.
X-BeenThere: alsa-devel@alsa-project.org
X-Mailman-Version: 2.1.14
Precedence: list
List-Id: "Alsa-devel mailing list for ALSA developers -
http://www.alsa-project.org"
List-Unsubscribe:
,
List-Archive:
List-Post:
List-Help:
List-Subscribe: ,
Errors-To: alsa-devel-bounces@alsa-project.org
Sender: alsa-devel-bounces@alsa-project.org
X-Virus-Scanned: ClamAV using ClamSMTP
Signed-off-by: Xiubo Li
---
sound/soc/fsl/fsl_esai.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/sound/soc/fsl/fsl_esai.c b/sound/soc/fsl/fsl_esai.c
index 912104f..8efc89e 100644
--- a/sound/soc/fsl/fsl_esai.c
+++ b/sound/soc/fsl/fsl_esai.c
@@ -209,8 +209,9 @@ static int fsl_esai_set_dai_sysclk(struct snd_soc_dai *dai, int clk_id,
struct clk *clksrc = esai_priv->extalclk;
bool tx = clk_id <= ESAI_HCKT_EXTAL;
bool in = dir == SND_SOC_CLOCK_IN;
- u32 ret, ratio, ecr = 0;
+ u32 ratio, ecr = 0;
unsigned long clk_rate;
+ int ret;
/* sck_div can be only bypassed if ETO/ERO=0 and SNC_SOC_CLOCK_OUT */
esai_priv->sck_div[tx] = true;
@@ -432,8 +433,8 @@ static int fsl_esai_set_dai_fmt(struct snd_soc_dai *dai, unsigned int fmt)
static int fsl_esai_startup(struct snd_pcm_substream *substream,
struct snd_soc_dai *dai)
{
- int ret;
struct fsl_esai *esai_priv = snd_soc_dai_get_drvdata(dai);
+ int ret;
/*
* Some platforms might use the same bit to gate all three or two of
@@ -491,7 +492,8 @@ static int fsl_esai_hw_params(struct snd_pcm_substream *substream,
bool tx = substream->stream == SNDRV_PCM_STREAM_PLAYBACK;
u32 width = snd_pcm_format_width(params_format(params));
u32 channels = params_channels(params);
- u32 bclk, mask, val, ret;
+ u32 bclk, mask, val;
+ int ret;
bclk = params_rate(params) * esai_priv->slot_width * 2;