From patchwork Tue Dec 23 09:08:29 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jianqun Xu X-Patchwork-Id: 5531481 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 1DC89BEEA8 for ; Tue, 23 Dec 2014 09:12:21 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 5551120165 for ; Tue, 23 Dec 2014 09:12:20 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 2118E2012D for ; Tue, 23 Dec 2014 09:12:19 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 45B68261622; Tue, 23 Dec 2014 10:12:18 +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 EB74526150C; Tue, 23 Dec 2014 10:11:13 +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 000DF2614CE; Tue, 23 Dec 2014 10:11:09 +0100 (CET) Received: from regular1.263xmail.com (regular1.263xmail.com [211.150.99.140]) by alsa0.perex.cz (Postfix) with ESMTP id 158062604BC for ; Tue, 23 Dec 2014 10:10:58 +0100 (CET) Received: from jay.xu?rock-chips.com (unknown [192.168.167.192]) by regular1.263xmail.com (Postfix) with SMTP id 21C8B418F; Tue, 23 Dec 2014 17:10:54 +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 2E9621E55B; Tue, 23 Dec 2014 17:10:47 +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: 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 19522BVZIVP; Tue, 23 Dec 2014 17:10:48 +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: Tue, 23 Dec 2014 17:08:29 +0800 Message-Id: <1419325709-15374-3-git-send-email-jay.xu@rock-chips.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1419325709-15374-1-git-send-email-jay.xu@rock-chips.com> References: <1419325709-15374-1-git-send-email-jay.xu@rock-chips.com> Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, Jianqun Xu , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [alsa-devel] [PATCH 2/2] ASoC: rockchip: i2s: set TDL and RDL to 16 bits 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 bits. Without this setting, the TDL is default to be 0x00 (means 1 bit), and the RDL is default to be 0x1f (means 16 bits). This patch is helpful to fix pop sound, tested on rk3288 board. Signed-off-by: Jianqun Xu --- 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; }