From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.7 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,SPF_HELO_NONE, SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6EB6EC433DB for ; Fri, 12 Mar 2021 13:48:34 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2161964F77 for ; Fri, 12 Mar 2021 13:48:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229728AbhCLNsB (ORCPT ); Fri, 12 Mar 2021 08:48:01 -0500 Received: from mail.kernel.org ([198.145.29.99]:52262 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230491AbhCLNr4 (ORCPT ); Fri, 12 Mar 2021 08:47:56 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id CDD9264F77; Fri, 12 Mar 2021 13:47:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1615556876; bh=sOBXKqeGO4Nq6TKstq0SbVu8mp+HGsMEGseeBq3jg/4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=QfmMSgY+xABbFrE8pXva2Z+2KoRJjF8hUO0QbnHV52jRHwqqsqBu7djvhyP1BlRy0 as1td4ujPDB/8qz9pur2Fp2gmJbCC7Oz2veyQS1ykZQZMlnPnJi7PtAiSo8nXYavRX yzuipZUC87gUAfVZHNpqfBWdfSfBaytYgKO8hm3c+5aVI+6MjyfN+nPPIdwJikV9Nv Mev3vtRCjtt9qRqWV81f0qU07Ikik8s7PmqvrTtv4R0n24H+5LZcjhxjDrFXleVGUq gQohoQEfK/Byb0jI2I6oti8E92QWZBLs94uC2h4xdCvzg4H9boCjjP/z4QfVAJVGa8 CBKSkeQC21f8A== Date: Fri, 12 Mar 2021 13:46:42 +0000 From: Mark Brown To: Michael Walle Cc: Sameer Pujar , alsa-devel@alsa-project.org, devicetree@vger.kernel.org, jonathanh@nvidia.com, kuninori.morimoto.gx@renesas.com, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org, robh@kernel.org, sharadg@nvidia.com, thierry.reding@gmail.com Subject: Re: [PATCH 1/3] ASoC: simple-card-utils: Fix device module clock Message-ID: <20210312134642.GF5348@sirena.org.uk> References: <20210309144156.18887-1-michael@walle.cc> <611ed3362dee3b3b7c7a80edfe763fd0@walle.cc> <20210311161558.GG4962@sirena.org.uk> <20210312113544.GB5348@sirena.org.uk> <6ed28bb5330879b1919aced5174f319f@walle.cc> <20210312120456.GD5348@sirena.org.uk> <684332700f8be9f77348a510eb6eba22@walle.cc> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="p8PhoBjPxaQXD0vg" Content-Disposition: inline In-Reply-To: <684332700f8be9f77348a510eb6eba22@walle.cc> X-Cookie: Lake Erie died for your sins. User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-tegra@vger.kernel.org --p8PhoBjPxaQXD0vg Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Mar 12, 2021 at 01:30:02PM +0100, Michael Walle wrote: > The card calls set_sysclk(), which eventually ends up in the codec. > The codec therefore, could figure out if it needs to configure the > clock or if it can use its internal FLL. > Is that what you mean? Yes. > But the set_sysclk() of the codec isn't even called, because the > card itself already tries to call clk_set_rate() on the Codec's MCLK, > which returns with an error [0]. OK, so I think we need to push this down a level so that the clock setting is implemented by the core/CODEC rather than by simple-card, with the helpers being something the CODEC can opt out of. --p8PhoBjPxaQXD0vg Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmBLcMEACgkQJNaLcl1U h9Dpnwf+Ma+xUvei/ETOcavme1+SPoDJipBJaYbklI5qB5IzBS+8YxBxZpncxWkY 6iuXFmnDpDu8X7u800I+d19Qu/DgQDDdLgq7zPV+NFZKGCscO21J4h3LF3xWk72f bV2rNk5tqpGg/gYw/3eyZFr9UubaP63Ubr0iEVtxMe9zEicsmVvwLrhWxgrVsjAw HEkX6CWSrVMdgSilAAYIUDb1usJFCd5hcyVr5zP5vOtpOnugFoV9GLd7vuT1otiV 9LCai/C2xwF+dscvm3PlXi4+acWmS1SorHpaRRZ1w6W8CH1HZp+mWGdfTUDhz+ei 0k5p1ojMOw4U8Yv+ZpbfnY4fvjxsUw== =6MCd -----END PGP SIGNATURE----- --p8PhoBjPxaQXD0vg-- From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.5 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E9E39C433DB for ; Fri, 12 Mar 2021 13:49:00 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 4859964FCE for ; Fri, 12 Mar 2021 13:48:59 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 4859964FCE Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=alsa-devel-bounces@alsa-project.org 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 51B1D1723; Fri, 12 Mar 2021 14:48:07 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 51B1D1723 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1615556937; bh=sOBXKqeGO4Nq6TKstq0SbVu8mp+HGsMEGseeBq3jg/4=; h=Date:From:To:Subject:References:In-Reply-To:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=prQ+9xJz4DM3rMKvRBMNcAHvZfGf/ijXbC3wlFgTMr1/qyNGwl+/uO6Wesj06feVN MBzzG5sHqgNQJpsjnlTsi5RkvgUyNweSlUBrJF5lhwr7gYPq0Mxc4KxfVMGigriaKK uJrzJrjV7G3J6NT5wOIu0Y8eFebwH5DF7K4y9bB0= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id B2E87F8016C; Fri, 12 Mar 2021 14:48:06 +0100 (CET) Received: by alsa1.perex.cz (Postfix, from userid 50401) id F0012F801D8; Fri, 12 Mar 2021 14:48:04 +0100 (CET) Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id 013F2F8012A for ; Fri, 12 Mar 2021 14:47:58 +0100 (CET) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz 013F2F8012A Authentication-Results: alsa1.perex.cz; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="QfmMSgY+" Received: by mail.kernel.org (Postfix) with ESMTPSA id CDD9264F77; Fri, 12 Mar 2021 13:47:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1615556876; bh=sOBXKqeGO4Nq6TKstq0SbVu8mp+HGsMEGseeBq3jg/4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=QfmMSgY+xABbFrE8pXva2Z+2KoRJjF8hUO0QbnHV52jRHwqqsqBu7djvhyP1BlRy0 as1td4ujPDB/8qz9pur2Fp2gmJbCC7Oz2veyQS1ykZQZMlnPnJi7PtAiSo8nXYavRX yzuipZUC87gUAfVZHNpqfBWdfSfBaytYgKO8hm3c+5aVI+6MjyfN+nPPIdwJikV9Nv Mev3vtRCjtt9qRqWV81f0qU07Ikik8s7PmqvrTtv4R0n24H+5LZcjhxjDrFXleVGUq gQohoQEfK/Byb0jI2I6oti8E92QWZBLs94uC2h4xdCvzg4H9boCjjP/z4QfVAJVGa8 CBKSkeQC21f8A== Date: Fri, 12 Mar 2021 13:46:42 +0000 From: Mark Brown To: Michael Walle Subject: Re: [PATCH 1/3] ASoC: simple-card-utils: Fix device module clock Message-ID: <20210312134642.GF5348@sirena.org.uk> References: <20210309144156.18887-1-michael@walle.cc> <611ed3362dee3b3b7c7a80edfe763fd0@walle.cc> <20210311161558.GG4962@sirena.org.uk> <20210312113544.GB5348@sirena.org.uk> <6ed28bb5330879b1919aced5174f319f@walle.cc> <20210312120456.GD5348@sirena.org.uk> <684332700f8be9f77348a510eb6eba22@walle.cc> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="p8PhoBjPxaQXD0vg" Content-Disposition: inline In-Reply-To: <684332700f8be9f77348a510eb6eba22@walle.cc> X-Cookie: Lake Erie died for your sins. User-Agent: Mutt/1.10.1 (2018-07-13) Cc: devicetree@vger.kernel.org, alsa-devel@alsa-project.org, kuninori.morimoto.gx@renesas.com, robh@kernel.org, Sameer Pujar , linux-kernel@vger.kernel.org, jonathanh@nvidia.com, sharadg@nvidia.com, thierry.reding@gmail.com, linux-tegra@vger.kernel.org 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" --p8PhoBjPxaQXD0vg Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Fri, Mar 12, 2021 at 01:30:02PM +0100, Michael Walle wrote: > The card calls set_sysclk(), which eventually ends up in the codec. > The codec therefore, could figure out if it needs to configure the > clock or if it can use its internal FLL. > Is that what you mean? Yes. > But the set_sysclk() of the codec isn't even called, because the > card itself already tries to call clk_set_rate() on the Codec's MCLK, > which returns with an error [0]. OK, so I think we need to push this down a level so that the clock setting is implemented by the core/CODEC rather than by simple-card, with the helpers being something the CODEC can opt out of. --p8PhoBjPxaQXD0vg Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmBLcMEACgkQJNaLcl1U h9Dpnwf+Ma+xUvei/ETOcavme1+SPoDJipBJaYbklI5qB5IzBS+8YxBxZpncxWkY 6iuXFmnDpDu8X7u800I+d19Qu/DgQDDdLgq7zPV+NFZKGCscO21J4h3LF3xWk72f bV2rNk5tqpGg/gYw/3eyZFr9UubaP63Ubr0iEVtxMe9zEicsmVvwLrhWxgrVsjAw HEkX6CWSrVMdgSilAAYIUDb1usJFCd5hcyVr5zP5vOtpOnugFoV9GLd7vuT1otiV 9LCai/C2xwF+dscvm3PlXi4+acWmS1SorHpaRRZ1w6W8CH1HZp+mWGdfTUDhz+ei 0k5p1ojMOw4U8Yv+ZpbfnY4fvjxsUw== =6MCd -----END PGP SIGNATURE----- --p8PhoBjPxaQXD0vg--