From patchwork Mon May 19 17:30:38 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Sylwester Nawrocki/Kernel \\(PLT\\) /SRPOL/Staff Engineer/Samsung Electronics" X-Patchwork-Id: 4204761 Return-Path: X-Original-To: patchwork-linux-arm@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 9323D9F32A for ; Mon, 19 May 2014 17:34:05 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id C42FF20211 for ; Mon, 19 May 2014 17:34:04 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.9]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 01743201F2 for ; Mon, 19 May 2014 17:34:04 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1WmRPq-00005q-LM; Mon, 19 May 2014 17:31:58 +0000 Received: from mailout3.samsung.com ([203.254.224.33]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WmRPR-0008Ep-Tp for linux-arm-kernel@lists.infradead.org; Mon, 19 May 2014 17:31:35 +0000 Received: from epcpsbgm2.samsung.com (epcpsbgm2 [203.254.230.27]) by mailout3.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0N5U00LHB0NZI1A0@mailout3.samsung.com> for linux-arm-kernel@lists.infradead.org; Tue, 20 May 2014 02:31:11 +0900 (KST) X-AuditID: cbfee61b-b7fbb6d000001be3-d1-537a3fdf4027 Received: from epmmp2 ( [203.254.227.17]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id 30.12.07139.FDF3A735; Tue, 20 May 2014 02:31:11 +0900 (KST) Received: from amdc1344.digital.local ([106.116.147.32]) by mmp2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0N5U00K1I0N43W10@mmp2.samsung.com>; Tue, 20 May 2014 02:31:11 +0900 (KST) From: Sylwester Nawrocki To: broonie@kernel.org Subject: [PATCH] ASoC: samsung: Allow setting OP_CLK of the IIS Multi Audio Interface Date: Mon, 19 May 2014 19:30:38 +0200 Message-id: <1400520638-6907-1-git-send-email-s.nawrocki@samsung.com> X-Mailer: git-send-email 1.7.9.5 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrIJMWRmVeSWpSXmKPExsVy+t9jQd379lXBBo/nClpcuXiIyWLqwyds FpseX2O1mHF+H5PF4TftrA6sHhs+N7F5bFrVyeaxeUm9R9+WVYwenzfJBbBGcdmkpOZklqUW 6dslcGW07X7JXvCGo+L0jRbmBsYl7F2MnBwSAiYSTbs/sULYYhIX7q1n62Lk4hASmM4oseXj FmYIp4NJorfpFlgHm4ChRO/RPkYQWwSo4/acTrAiZoGZjBKTVneBFQkLhEts2XGRBcRmEVCV OLn+LtgKXgFXiVWfHgDFOYDWKUjMmWQzgZF7ASPDKkbR1ILkguKk9FwjveLE3OLSvHS95Pzc TYzggHgmvYNxVYPFIUYBDkYlHt4D4lXBQqyJZcWVuYcYJTiYlUR43UyAQrwpiZVVqUX58UWl OanFhxilOViUxHkPtloHCgmkJ5akZqemFqQWwWSZODilGhgTX+hm/K1hXC9/g3XbwyReQWsO HdkW/7USjEpHL7HxlBee9OSbnuXjO/vWwbOWrL+bJ7ofmzitXSnbyHjJieuV38T2MTOd7dH+ dOprWq7sRae9Jvx/GcKZg+p+a/3683Oi7617b6tWTf0xkz/oVIOx3JpNkkrhuUx7uSttWtYs fXJudp7cEm4lluKMREMt5qLiRABEmGVgBAIAAA== X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140519_103134_136579_DC55C350 X-CRM114-Status: UNSURE ( 9.34 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -5.7 (-----) Cc: alsa-devel@alsa-project.org, linux-samsung-soc@vger.kernel.org, Sylwester Nawrocki , linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-2.5 required=5.0 tests=BAYES_00,RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP This patch adds support for setting source clock of the "Core CLK" of the IIS Multi Audio Interface. Signed-off-by: Sylwester Nawrocki --- sound/soc/samsung/i2s.c | 4 ++++ sound/soc/samsung/i2s.h | 1 + 2 files changed, 5 insertions(+) diff --git a/sound/soc/samsung/i2s.c b/sound/soc/samsung/i2s.c index 048ead9..ae02811 100644 --- a/sound/soc/samsung/i2s.c +++ b/sound/soc/samsung/i2s.c @@ -451,6 +451,10 @@ static int i2s_set_sysclk(struct snd_soc_dai *dai, u32 mod = readl(i2s->addr + I2SMOD); switch (clk_id) { + case SAMSUNG_I2S_OPCLK: + mod &= ~MOD_OPCLK_MASK; + mod |= dir; + break; case SAMSUNG_I2S_CDCLK: /* Shouldn't matter in GATING(CLOCK_IN) mode */ if (dir == SND_SOC_CLOCK_IN) diff --git a/sound/soc/samsung/i2s.h b/sound/soc/samsung/i2s.h index 7966afc..21ff24e 100644 --- a/sound/soc/samsung/i2s.h +++ b/sound/soc/samsung/i2s.h @@ -18,5 +18,6 @@ #define SAMSUNG_I2S_RCLKSRC_0 0 #define SAMSUNG_I2S_RCLKSRC_1 1 #define SAMSUNG_I2S_CDCLK 2 +#define SAMSUNG_I2S_OPCLK 3 #endif /* __SND_SOC_SAMSUNG_I2S_H */