From patchwork Fri Apr 11 01:16:33 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kuninori Morimoto X-Patchwork-Id: 3971931 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id BD660BFF02 for ; Fri, 11 Apr 2014 20:04:33 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E41F4202FE for ; Fri, 11 Apr 2014 20:04:32 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id A665D202E6 for ; Fri, 11 Apr 2014 20:04:30 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id D02C0265833; Fri, 11 Apr 2014 22:04:28 +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.8 required=5.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, NO_DNS_FOR_FROM, T_DKIM_INVALID, UNPARSEABLE_RELAY autolearn=no version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id B28B82658EB; Fri, 11 Apr 2014 16:03:43 +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 36451267E9A; Fri, 11 Apr 2014 16:03:42 +0200 (CEST) Received: from mail-pd0-f171.google.com (mail-pd0-f171.google.com [209.85.192.171]) by alsa0.perex.cz (Postfix) with ESMTP id DE5922658EB for ; Fri, 11 Apr 2014 03:16:35 +0200 (CEST) Received: by mail-pd0-f171.google.com with SMTP id r10so4582099pdi.16 for ; Thu, 10 Apr 2014 18:16:33 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=date:message-id:from:subject:user-agent:to:cc:mime-version :content-type; bh=xa8V8NynDBMQ0obeExfuHH/04qzdU5dd5AgInL4Y96U=; b=k/aVRdSmEqzYu0dVk8VFuRtG7NEV1XuGTIOv5230cntcht80nXCM9RZZsgHksH9SMJ 6107cckK8P+2UmU1u7muPFUeo+neluoMHX6dRGpEu0vFVtXEiKqIeeiaPpxYF2gLiRQP VUOcqwnyhhDM9etQXPFZ/d3FVjGCrZlS48JDZqwgbCiS8Dw16Gk78hGOX/8raAD7Ojz4 uTLGZOnBBdOcEUCKW75V8IZ/IFttmthp74PClO4Xxto3zaGVige58cTYEL5C9R9khqn/ uhFWXqwZhqbl5Xri/KaweboA2oCMnf4LZrhmfhaD4+YDF9k7AGJj293BIPSCM3SlR9kA bPeA== X-Received: by 10.68.191.138 with SMTP id gy10mr6363419pbc.169.1397178993763; Thu, 10 Apr 2014 18:16:33 -0700 (PDT) Received: from remon.gmail.com (49.14.32.202.bf.2iij.net. [202.32.14.49]) by mx.google.com with ESMTPSA id yo9sm27776591pab.16.2014.04.10.18.16.31 for (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 10 Apr 2014 18:16:33 -0700 (PDT) Date: Thu, 10 Apr 2014 18:16:33 -0700 (PDT) Message-ID: <87ob08oebr.wl%kuninori.morimoto.gx@gmail.com> From: Kuninori Morimoto User-Agent: Wanderlust/2.14.0 Emacs/23.3 Mule/6.0 To: Mark Brown MIME-Version: 1.0 (generated by SEMI 1.14.6 - "Maruoka") Cc: Linux-ALSA , Kuninori Morimoto , Simon , Liam Girdwood , Ben Dooks , Kuninori Morimoto Subject: [alsa-devel] [PATCH] ASoC: rsnd: fix clock prepare/unprepare 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 From: Ben Dooks As with the previous commit, before a clock can be used it must be prepared for use. Change from clk_enable() and clk_disable() to the versions of the calls which also prepare and un-prepare the clocks. Will fix warnings from the clock code when this is used. Signed-off-by: Ben Dooks Signed-off-by: Kuninori Morimoto --- This patch is for current linus/master tree sound/soc/sh/rcar/src.c | 4 ++-- sound/soc/sh/rcar/ssi.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/sound/soc/sh/rcar/src.c b/sound/soc/sh/rcar/src.c index 6232b7d..4d0720e 100644 --- a/sound/soc/sh/rcar/src.c +++ b/sound/soc/sh/rcar/src.c @@ -258,7 +258,7 @@ static int rsnd_src_init(struct rsnd_mod *mod, { struct rsnd_src *src = rsnd_mod_to_src(mod); - clk_enable(src->clk); + clk_prepare_enable(src->clk); return 0; } @@ -269,7 +269,7 @@ static int rsnd_src_quit(struct rsnd_mod *mod, { struct rsnd_src *src = rsnd_mod_to_src(mod); - clk_disable(src->clk); + clk_disable_unprepare(src->clk); return 0; } diff --git a/sound/soc/sh/rcar/ssi.c b/sound/soc/sh/rcar/ssi.c index 4b7e206..1d8387c 100644 --- a/sound/soc/sh/rcar/ssi.c +++ b/sound/soc/sh/rcar/ssi.c @@ -171,7 +171,7 @@ static void rsnd_ssi_hw_start(struct rsnd_ssi *ssi, u32 cr; if (0 == ssi->usrcnt) { - clk_enable(ssi->clk); + clk_prepare_enable(ssi->clk); if (rsnd_dai_is_clk_master(rdai)) { if (rsnd_ssi_clk_from_parent(ssi)) @@ -230,7 +230,7 @@ static void rsnd_ssi_hw_stop(struct rsnd_ssi *ssi, rsnd_ssi_master_clk_stop(ssi); } - clk_disable(ssi->clk); + clk_disable_unprepare(ssi->clk); } dev_dbg(dev, "ssi%d hw stopped\n", rsnd_mod_id(&ssi->mod));