From patchwork Thu Aug 4 14:35:37 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Adam Thomson X-Patchwork-Id: 9264647 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id C5E8260754 for ; Fri, 5 Aug 2016 00:29:46 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B50BE27C2D for ; Fri, 5 Aug 2016 00:29:46 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id A647427FAC; Fri, 5 Aug 2016 00:29:46 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E3E2027C2D for ; Fri, 5 Aug 2016 00:29:45 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id E3DE8267035; Fri, 5 Aug 2016 02:29:44 +0200 (CEST) Received: from alsa0.perex.cz (localhost [127.0.0.1]) by alsa0.perex.cz (Postfix) with ESMTP id 1CE06267187; Fri, 5 Aug 2016 01:21:06 +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 2508B265A46; Fri, 5 Aug 2016 01:20:59 +0200 (CEST) Received: from mail1.bemta3.messagelabs.com (mail1.bemta3.messagelabs.com [195.245.230.163]) by alsa0.perex.cz (Postfix) with ESMTP id 5E5CC265A79 for ; Thu, 4 Aug 2016 16:35:40 +0200 (CEST) Received: from [85.158.137.99] by server-3.bemta-3.messagelabs.com id 4A/55-23620-BB253A75; Thu, 04 Aug 2016 14:35:39 +0000 X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFvrAIsWRWlGSWpSXmKPExsUSt3Opse7uoMX hBgfvCFtcuXiIyWLqwydsFt+udDBZXN41h82ic1c/q8WG72sZHdg8NnxuYvPYOesuu8emVZ1s HvveLmPzWL/lKovH501yAWxRrJl5SfkVCawZfw6aFhxmr1jx4wFjA+M+ti5GLg4hgXWMEn86z gE5nEBOhcSyY7PZuxg5OHgFMiXWtZuBhDkF3CXendjGCFHiJjFj7h4WEJtNwEJi8okHYK0sAi oSxw/8ZQexhQXCJZquzWUFmS8i0MUosfrVY7AEs0C5xJZPE5lBbF4BQYmTM5+wQMQlJA6+eME MscBA4vSCRrC4hIC9xPT3V5lB7pEQ0JdoPBYLETaU+D7rGwtE2FzixTTjCYyCs5AMnYVk6AJG plWMGsWpRWWpRbqG5npJRZnpGSW5iZk5uoYGxnq5qcXFiempOYlJxXrJ+bmbGIGhzwAEOxhfn vY8xCjJwaQkyjsjYHG4EF9SfkplRmJxRnxRaU5q8SFGGQ4OJQneo4FAOcGi1PTUirTMHGAUwq QlOHiURHj7QNK8xQWJucWZ6RCpU4y6HAt+3F7LJMSSl5+XKiXOuwKkSACkKKM0D24ELCFcYpS VEuZlBDpKiKcgtSg3swRV/hWjOAejkjDvLJApPJl5JXCbXgEdwQR0xAmDBSBHlCQipKQaGHkW FXzy32UWvtvAxvjt7yW/eLeLJheIuReEmd6/ELqI6dxuMR4jCafE1AVqT9weHSxs3/tp6bVfs m/MJ+8O9nI4fzY1e9qpmcKN4afcLk3b+vfrlY8rZ7XNfaOxsln52fFtq178udgdI1Z8teRK4L xdybFbbtz5OrV37uuVaRzdSpX7DXSTTq5VYinOSDTUYi4qTgQA0+MJAgMDAAA= X-Env-Sender: Adam.Thomson.Opensource@diasemi.com X-Msg-Ref: server-8.tower-217.messagelabs.com!1470321339!46081956!1 X-Originating-IP: [94.185.165.51] X-StarScan-Received: X-StarScan-Version: 8.77; banners=-,-,- X-VirusChecked: Checked Received: (qmail 16482 invoked from network); 4 Aug 2016 14:35:39 -0000 Received: from mailrelay2.diasemi.com (HELO sw-ex-cashub01.diasemi.com) (94.185.165.51) by server-8.tower-217.messagelabs.com with AES128-SHA encrypted SMTP; 4 Aug 2016 14:35:39 -0000 Received: from swsrvapps-01.diasemi.com (10.20.28.141) by SW-EX-CASHUB01.diasemi.com (10.20.16.140) with Microsoft SMTP Server id 14.3.248.2; Thu, 4 Aug 2016 15:35:38 +0100 Received: by swsrvapps-01.diasemi.com (Postfix, from userid 22379) id 21DD13FB50; Thu, 4 Aug 2016 15:35:37 +0100 (BST) Message-ID: In-Reply-To: References: From: Adam Thomson Date: Thu, 4 Aug 2016 15:35:37 +0100 To: Mark Brown , Liam Girdwood , Jaroslav Kysela , Takashi Iwai MIME-Version: 1.0 X-KSE-AttachmentFiltering-Interceptor-Info: protection disabled X-KSE-ServerInfo: sw-ex-cashub01.diasemi.com, 9 X-KSE-Antivirus-Interceptor-Info: scan successful X-KSE-Antivirus-Info: Clean, bases: 04/08/2016 12:49:00 Cc: alsa-devel@alsa-project.org, Support Opensource , linux-kernel@vger.kernel.org Subject: [alsa-devel] [PATCH 1/4] ASoC: da7213: Default to 64 BCLKs per WCLK to support all formats 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 Previously code defaulted to 32 BCLKS per WCLK which meant 24 and 32 bit DAI formats would not work properly. This patch fixes the issue by defaulting to 64 BCLKs per WCLK. Signed-off-by: Adam Thomson Tested-by: Peter Meerwald-Stadler --- sound/soc/codecs/da7213.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc/codecs/da7213.c b/sound/soc/codecs/da7213.c index e5527bc..bcf1834 100644 --- a/sound/soc/codecs/da7213.c +++ b/sound/soc/codecs/da7213.c @@ -1247,8 +1247,8 @@ static int da7213_set_dai_fmt(struct snd_soc_dai *codec_dai, unsigned int fmt) return -EINVAL; } - /* By default only 32 BCLK per WCLK is supported */ - dai_clk_mode |= DA7213_DAI_BCLKS_PER_WCLK_32; + /* By default only 64 BCLK per WCLK is supported */ + dai_clk_mode |= DA7213_DAI_BCLKS_PER_WCLK_64; snd_soc_write(codec, DA7213_DAI_CLK_MODE, dai_clk_mode); snd_soc_update_bits(codec, DA7213_DAI_CTRL, DA7213_DAI_FORMAT_MASK,