From patchwork Mon May 9 10:42:30 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Peter Ujfalusi X-Patchwork-Id: 9044791 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.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id B6BA99F30C for ; Mon, 9 May 2016 10:44:47 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E1F2020149 for ; Mon, 9 May 2016 10:44:46 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id A9CB42012D for ; Mon, 9 May 2016 10:44:45 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id DC557265906; Mon, 9 May 2016 12:44:39 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id C59D92657C3; Mon, 9 May 2016 12:43:09 +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 2648B26578B; Mon, 9 May 2016 12:43:07 +0200 (CEST) Received: from devils.ext.ti.com (devils.ext.ti.com [198.47.26.153]) by alsa0.perex.cz (Postfix) with ESMTP id 52F6126578F for ; Mon, 9 May 2016 12:42:40 +0200 (CEST) Received: from dflxv15.itg.ti.com ([128.247.5.124]) by devils.ext.ti.com (8.13.7/8.13.7) with ESMTP id u49AgdYH009036; Mon, 9 May 2016 05:42:39 -0500 Received: from DLEE71.ent.ti.com (dlee71.ent.ti.com [157.170.170.114]) by dflxv15.itg.ti.com (8.14.3/8.13.8) with ESMTP id u49AgdUY009711; Mon, 9 May 2016 05:42:39 -0500 Received: from dlep32.itg.ti.com (157.170.170.100) by DLEE71.ent.ti.com (157.170.170.114) with Microsoft SMTP Server id 14.3.224.2; Mon, 9 May 2016 05:42:39 -0500 Received: from dlep32.itg.ti.com (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep32.itg.ti.com (8.14.3/8.13.8) with ESMTP id u49AgXAY031040; Mon, 9 May 2016 05:42:37 -0500 From: Peter Ujfalusi To: , Date: Mon, 9 May 2016 13:42:30 +0300 Message-ID: <1462790552-6438-3-git-send-email-peter.ujfalusi@ti.com> X-Mailer: git-send-email 2.8.2 In-Reply-To: <1462790552-6438-1-git-send-email-peter.ujfalusi@ti.com> References: <1462790552-6438-1-git-send-email-peter.ujfalusi@ti.com> MIME-Version: 1.0 Cc: alsa-devel@alsa-project.org, jsarha@ti.com Subject: [alsa-devel] [PATCH 2/4] ASoC: davinci-mcasp: Change __davinci_mcasp_set_clkdiv() first parameter 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 Change the first parameter to struct davinci_mcasp* from struct snd_soc_dai* The function internally does not use or need the DAI information. Signed-off-by: Peter Ujfalusi --- sound/soc/davinci/davinci-mcasp.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/sound/soc/davinci/davinci-mcasp.c b/sound/soc/davinci/davinci-mcasp.c index 836f694e4b9d..47be74d74384 100644 --- a/sound/soc/davinci/davinci-mcasp.c +++ b/sound/soc/davinci/davinci-mcasp.c @@ -540,11 +540,9 @@ out: return ret; } -static int __davinci_mcasp_set_clkdiv(struct snd_soc_dai *dai, int div_id, +static int __davinci_mcasp_set_clkdiv(struct davinci_mcasp *mcasp, int div_id, int div, bool explicit) { - struct davinci_mcasp *mcasp = snd_soc_dai_get_drvdata(dai); - pm_runtime_get_sync(mcasp->dev); switch (div_id) { case MCASP_CLKDIV_AUXCLK: /* MCLK divider */ @@ -592,7 +590,9 @@ static int __davinci_mcasp_set_clkdiv(struct snd_soc_dai *dai, int div_id, static int davinci_mcasp_set_clkdiv(struct snd_soc_dai *dai, int div_id, int div) { - return __davinci_mcasp_set_clkdiv(dai, div_id, div, 1); + struct davinci_mcasp *mcasp = snd_soc_dai_get_drvdata(dai); + + return __davinci_mcasp_set_clkdiv(mcasp, div_id, div, 1); } static int davinci_mcasp_set_sysclk(struct snd_soc_dai *dai, int clk_id, @@ -1056,7 +1056,7 @@ static int davinci_mcasp_hw_params(struct snd_pcm_substream *substream, dev_info(mcasp->dev, "Sample-rate is off by %d PPM\n", ppm); - __davinci_mcasp_set_clkdiv(cpu_dai, 1, div, 0); + __davinci_mcasp_set_clkdiv(mcasp, 1, div, 0); } ret = mcasp_common_hw_param(mcasp, substream->stream,