Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 4B325C43334 for ; Fri, 3 Jun 2022 10:11:20 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 1677D17EA; Fri, 3 Jun 2022 12:10:28 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 1677D17EA DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1654251078; bh=J55PX6csgV8KmYD5kOPsQtYHR74lOtEt0I9fGh4u6ms=; h=Date:From:To:Subject:References:In-Reply-To:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=MSl9tsxeFwiMffOU01qYU1ogMjHGu3WsmwY/vVo1Va+bEtOXtVGiRoQ3dPgIJNJj+ BQLQ6fRguHjwipqjlBF09TkPY9vle1LhO0RDyaY9+n1S1shgZzNsfIPATcY7to73BK QY8dxicrVumtsMP9v+AlnXqJxGblh/pWh12j2kiw= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id 86AE7F804C1; Fri, 3 Jun 2022 12:10:27 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 4C7A0F804CC; Fri, 3 Jun 2022 12:10:26 +0200 (CEST) Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 13B45F80124 for ; Fri, 3 Jun 2022 12:10:23 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 13B45F80124 Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="So4TqyYF" Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 29B99B822A5; Fri, 3 Jun 2022 10:10:22 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9F536C385A9; Fri, 3 Jun 2022 10:10:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1654251020; bh=J55PX6csgV8KmYD5kOPsQtYHR74lOtEt0I9fGh4u6ms=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=So4TqyYF9CaBN4+t1oqwZVvSwZh4KGaqP4+XpNl9bi4nplUQ9Lex4J80w4lg96812 a+i7scDhovhfOwDPBrJSc0j4fN4nPK4f7ySYSNadvO8Jn66rfhgmHeUg6qCMVshlW6 NyRc9PIn+UzFJBzLK6lkSTPRGsO94yjmh9mcATuqyPC4YY/bwsdp/ZMTqXp6Uo1tEF rCanOqy6nf11k1QVqN3LTTYSKBnOTeo0sayj2aoodzhCThEQrQGoGFvubB3rzY79sA +4zsFykm2ceJlEfMbyuyxASm5ky8SKg2IJB/oO489Ia7sMIT2RK5qC/YMhH5PUmYyo 8zeCgxec806Gw== Date: Fri, 3 Jun 2022 12:10:18 +0200 From: Mark Brown To: Hui Wang Subject: Re: [PATCH 1/2] ASoC: nau8822: Add operation for internal PLL off and on Message-ID: References: <20220530040151.95221-1-hui.wang@canonical.com> <20220530040151.95221-2-hui.wang@canonical.com> <817ab950-db61-9d48-f51f-41009c8bd23d@canonical.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="i5kKgdxwkXk3utbi" Content-Disposition: inline In-Reply-To: X-Cookie: May your camel be as swift as the wind. Cc: wtli@nuvoton.com, ctlin0@nuvoton.com, alsa-devel@alsa-project.org, kchsu0@nuvoton.com, David Lin X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 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" --i5kKgdxwkXk3utbi Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Fri, Jun 03, 2022 at 05:55:18PM +0800, Hui Wang wrote: > On 6/2/22 18:33, Mark Brown wrote: > > > Thanks for your comment. But it is weird, it doesn't work like you sa= id, > > > probably need specific route setting in the machine driver level? > > Is this triggering due to reprogramming the PLL for one direction > > while the other is already active (eg, starting a capture during > > a playba > Yes, it is. With the current machine driver of fsl-asoc-card.c, if starti= ng > a capture during a playback or starting a playback during a capture, the > codec driver will reprogram PLL parameters while PLL is on. So your patch fixes that case - note however that you're probably getting an audio glitch in the already active stream while doing this. I'll send a patch which should improve that shortly. BTW, shouldn't the PLL power be left off if the output frequency is 0? > And in another case, if the=A0 snd_soc_dai_set_pll() is called in the > card->set_bias_level() instead of card_hw_params(), the PLL will keep bei= ng > off since check_mclk_select_pll() always returns false. That should be fixable... --i5kKgdxwkXk3utbi Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmKZ3gYACgkQJNaLcl1U h9AN6gf+M1F0w1bypWQFE+XhFlaGZmS/KQ5dSipgw8MCws6hQ9lR7pbU06hkF1CJ KTSd9HBbpI5FKeEh/FL4IIuXrM/XD91RurxULoK+FNCkoM6RY+f5l0igRJgVf0oG +9CroWnmUbVAmZ/AIseC1vDmKUPOO40zM7vDSkEzYpY3748d11jtDLae9bNr2gYe jqMEM4cqcpoth3Jf6pGqrO6i6lP81DSSMstK1oYONS0XJkbhPz9ggLN6D9j92GwR QlySPwzEDrbd6SWxWi0h6UpP9IfFF2leTzLQ4W9MBNpdSGcO2FXJX2BhVlcBUR8/ JwIYs8FeRL3naN3sdhCMh7CrFXBtJA== =TVhA -----END PGP SIGNATURE----- --i5kKgdxwkXk3utbi--