From patchwork Wed Dec 24 09:37:01 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jianqun Xu X-Patchwork-Id: 5538711 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 3FA7E9F301 for ; Wed, 24 Dec 2014 09:41:11 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7F1D4201BC for ; Wed, 24 Dec 2014 09:41:10 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 41DEF201BB for ; Wed, 24 Dec 2014 09:41:09 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 46F2E2625C4; Wed, 24 Dec 2014 10:41:08 +0100 (CET) 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, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id 5E2412619D7; Wed, 24 Dec 2014 10:39:29 +0100 (CET) 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 9C5372619D9; Wed, 24 Dec 2014 10:39:28 +0100 (CET) Received: from regular1.263xmail.com (regular1.263xmail.com [211.150.99.133]) by alsa0.perex.cz (Postfix) with ESMTP id 3A6992614D0 for ; Wed, 24 Dec 2014 10:39:14 +0100 (CET) Received: from jay.xu?rock-chips.com (unknown [192.168.167.225]) by regular1.263xmail.com (Postfix) with SMTP id 7B35A7409; Wed, 24 Dec 2014 17:39:08 +0800 (CST) X-263anti-spam: KSV:0; X-MAIL-GRAY: 0 X-MAIL-DELIVERY: 1 X-KSVirus-check: 0 X-ABS-CHECKED: 4 X-ADDR-CHECKED: 0 Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.263.net (Postfix) with ESMTP id 59100478; Wed, 24 Dec 2014 17:39:08 +0800 (CST) X-RL-SENDER: jay.xu@rock-chips.com X-SENDER-IP: 58.22.7.114 X-LOGIN-NAME: jay.xu@rock-chips.com X-UNIQUE-TAG: <4c21586cc7c5f2e7fb0e1e36ab9e251c> X-ATTACHMENT-NUM: 0 X-SENDER: xjq@rock-chips.com X-DNS-TYPE: 0 Received: from unknown (unknown [58.22.7.114]) by smtp.263.net (Postfix) whith SMTP id 15863KL865O; Wed, 24 Dec 2014 17:39:09 +0800 (CST) From: Jianqun Xu To: lgirdwood@gmail.com, heiko@sntech.de, broonie@kernel.org, perex@perex.cz, tiwai@suse.de, sonnyrao@chromium.org Date: Wed, 24 Dec 2014 17:37:01 +0800 Message-Id: <1419413822-11539-3-git-send-email-jay.xu@rock-chips.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1419413822-11539-1-git-send-email-jay.xu@rock-chips.com> References: <1419325709-15374-1-git-send-email-jay.xu@rock-chips.com> <1419413822-11539-1-git-send-email-jay.xu@rock-chips.com> Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, Jianqun Xu , linux-arm-kernel@lists.infradead.org Subject: [alsa-devel] [PATCH v2 2/3] ASoC: rockchip: i2s: set TDL and RDL to 16 samples 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: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP Set Transmit Data Level(TDL) and Receive Data Level(RDL) to 16 samples. Without this setting, the TDL is default to be 0x00 (means 0 sample), and the RDL is default to be 0x1f (means 32 samples). Signed-off-by: Jianqun Xu --- changes since v1: - modify commit message "bit" to "sample", suggested by dgreid sound/soc/rockchip/rockchip_i2s.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/sound/soc/rockchip/rockchip_i2s.c b/sound/soc/rockchip/rockchip_i2s.c index c74ba37..1cd7efc 100644 --- a/sound/soc/rockchip/rockchip_i2s.c +++ b/sound/soc/rockchip/rockchip_i2s.c @@ -247,6 +247,10 @@ static int rockchip_i2s_hw_params(struct snd_pcm_substream *substream, regmap_update_bits(i2s->regmap, I2S_TXCR, I2S_TXCR_VDW_MASK, val); regmap_update_bits(i2s->regmap, I2S_RXCR, I2S_RXCR_VDW_MASK, val); + regmap_update_bits(i2s->regmap, I2S_DMACR, I2S_DMACR_TDL_MASK, + I2S_DMACR_TDL(16)); + regmap_update_bits(i2s->regmap, I2S_DMACR, I2S_DMACR_RDL_MASK, + I2S_DMACR_RDL(16)); return 0; }