Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp967234yba; Thu, 4 Apr 2019 01:18:45 -0700 (PDT) X-Google-Smtp-Source: APXvYqzFmswWQrbZAfux/iAQrazyYMWL4mCjyo2tc2b+7UsW40UJ7WrhwYHI7MVjiOuGd73tFS12 X-Received: by 2002:a17:902:a704:: with SMTP id w4mr4791683plq.51.1554365925500; Thu, 04 Apr 2019 01:18:45 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1554365925; cv=none; d=google.com; s=arc-20160816; b=yji0i79JyF3tiEjVkLV51BMPaI0DXwUHmsnDBKm8kRlVHzYR4NyBr7bp8bO9+a2BTk 6VGptNDpMp7cQKPUgcaF8uHvBXxteeoTh5I2wizefF7bVTEIFEYVbcLAiMh4GpuY2lM5 1o7PeioQ5/y0lOVR6Bcke/t9aGCCpccu4gUyrhiXzpFryEixvechY9sPdRJq4noGyW5Q 4NNt8M30sZGj8SNs+XWNAoSzLfeDvO6I1VHL+ImcuE+hIm0vl2LG8XSnNAdTukTyzilv q5uOnx4W1vTuATU9KRAqN49s/MigwSoJmRPz89ZJUWP6nJkSlTWzVTV3f+168jTRXfiP IKtA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:date:message-id:in-reply-to:subject:cc:to :from:dkim-signature; bh=y07oRNI29gzFVOrU96FFCl/Ash0/icVsvDce4ew2BAA=; b=dU9Z5qhaAwoj896LluMEhPLNhdFeLef+jR64rG00lgtY1aaSVWoT3zLCEuJ+qmVCcY SwcMBwdgUsbiCMUg2xGhr9RcK1WlicqRsEFXBScZG3X4u8Bp1cjGmz+GAumMb42U2LtV TNANGLjMhbVUERrFtCyQ25p7hqSG3+cT2tCTZvXov+j0uzHWS1HORYVE6qKr5LIGzxyn 0tNA7u6Q3ntm8b5ZyeRrqkahOETz+Yb2eL/xqKawT8zbwSZbCbbTQ2PQFpSU9+xfIOPi mHz1l3MTVqge53MbtAOauy5hnaW1Hqf4MOdPAGs4c13AZt1duQNE/CjQqieK1BEM74VK 3G5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=EvcWsssQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id t8si15546457pgp.174.2019.04.04.01.18.30; Thu, 04 Apr 2019 01:18:45 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=fail header.i=@sirena.org.uk header.s=20170815-heliosphere header.b=EvcWsssQ; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728752AbfDDIRI (ORCPT + 99 others); Thu, 4 Apr 2019 04:17:08 -0400 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:50936 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728724AbfDDIRE (ORCPT ); Thu, 4 Apr 2019 04:17:04 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=y07oRNI29gzFVOrU96FFCl/Ash0/icVsvDce4ew2BAA=; b=EvcWsssQiA/c 7RY6+FXB04MEChrPW9zZ/PjS60nRrzyVXfzVP1QeKUyCm9xNRmbBCo/cfhwzsd6HUOhP5I/BLoe6s /YUK5F1bo2fJLCGy4YvR6laeS6TI2zv5m+0Eug5Cgawb3DH9A86N/NwKs6QCPPnlb/NMU7pg+oOj3 K09DQ=; Received: from [147.50.13.10] (helo=finisterre.ee.mobilebroadband) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hBxYL-00052K-Hx; Thu, 04 Apr 2019 08:16:53 +0000 Received: by finisterre.ee.mobilebroadband (Postfix, from userid 1000) id 7748C441D3D; Thu, 4 Apr 2019 15:16:50 +0700 (+07) From: Mark Brown To: Sugar Zhang Cc: Mark Brown , heiko@sntech.de, broonie@kernel.org, alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org, Takashi Iwai , Liam Girdwood , linux-rockchip@lists.infradead.org, linux-arm-kernel@lists.infradead.org, alsa-devel@alsa-project.org Subject: Applied "ASoC: rockchip: pdm: optimize clear logic" to the asoc tree In-Reply-To: <1554298856-59028-5-git-send-email-sugar.zhang@rock-chips.com> X-Patchwork-Hint: ignore Message-Id: <20190404081650.7748C441D3D@finisterre.ee.mobilebroadband> Date: Thu, 4 Apr 2019 15:16:50 +0700 (+07) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch ASoC: rockchip: pdm: optimize clear logic has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark From 252163a66a06859f468ef1e00fa5a1f377b16eed Mon Sep 17 00:00:00 2001 From: Sugar Zhang Date: Wed, 3 Apr 2019 21:40:48 +0800 Subject: [PATCH] ASoC: rockchip: pdm: optimize clear logic There is no need to reset controller every time, do this once in pdm_probe. Signed-off-by: Sugar Zhang Signed-off-by: Mark Brown --- sound/soc/rockchip/rockchip_pdm.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/sound/soc/rockchip/rockchip_pdm.c b/sound/soc/rockchip/rockchip_pdm.c index 984d99889a65..eb5216dd7dbc 100644 --- a/sound/soc/rockchip/rockchip_pdm.c +++ b/sound/soc/rockchip/rockchip_pdm.c @@ -183,9 +183,6 @@ static int rockchip_pdm_hw_params(struct snd_pcm_substream *substream, val); regmap_update_bits(pdm->regmap, PDM_DMA_CTRL, PDM_DMA_RDL_MSK, PDM_DMA_RDL(16)); - regmap_update_bits(pdm->regmap, PDM_SYSCONFIG, - PDM_RX_MASK | PDM_RX_CLR_MASK, - PDM_RX_STOP | PDM_RX_CLR_WR); } return 0; @@ -353,6 +350,7 @@ static bool rockchip_pdm_volatile_reg(struct device *dev, unsigned int reg) { switch (reg) { case PDM_SYSCONFIG: + case PDM_FIFO_CTRL: case PDM_INT_CLR: case PDM_INT_ST: return true; @@ -436,6 +434,7 @@ static int rockchip_pdm_probe(struct platform_device *pdev) goto err_suspend; } + rockchip_pdm_rxctrl(pdm, 0); ret = devm_snd_dmaengine_pcm_register(&pdev->dev, NULL, 0); if (ret) { dev_err(&pdev->dev, "could not register pcm: %d\n", ret); -- 2.20.1