Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp523826pxf; Thu, 11 Mar 2021 08:46:00 -0800 (PST) X-Google-Smtp-Source: ABdhPJzF3QI/tD/ku7iNwHMhW1aV8MhU1oM+riqF189rslAriAXqQ+Qn3YiVExysC94sFumcNO+p X-Received: by 2002:aa7:da04:: with SMTP id r4mr9477180eds.343.1615481159859; Thu, 11 Mar 2021 08:45:59 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1615481159; cv=none; d=google.com; s=arc-20160816; b=fnmnbGgXJMDGfvS2IrQWXestx6fg/yBbpT7eGS30lrNYdD5Jw5R5XaHKnl/IIyAfsd n+fqDO/mDQ2ovAkOsJkOSffqTuMOaDPFZC4J16ysiCZVOHIUlCTgp3r1pOCNboZpMc71 BU6HQmw4c3Ga+s+wK5SfVnu/68bGbN0umk45TTuWPilr8e3CylLD7vkKeA2FwDVAqN+j PGh9OFlgoHRQIlV04kqo5UJ9Lr6NzYhnCqCCJUrdTObz9OfXC7hJoS2R7RhraxvKrKv6 k37KVJZ9OidNsNU2vJGFDSog9Xxra4kVZVZozKfAKHxBMSndiDznc4RJNhaCykJ3+X45 amZg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:user-agent:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=HxnAxt4Z3oYtkv8BBfuXZZZBNwIxtJEReOB8hU0HZvQ=; b=zDv+QZKfc4RYRNwsTn6jD7w8tQvedwCtYZ6aoDIvxgZUS4KUk7IGrrO07HeEr2gR/o hdaUWl4GjEtAtLgAoLq6RBX1CaUVcDahv/DH6rOe8klp4y/eAdeWkIl1bag4kwlYP/7C mUEFBkJ2N6njntx1RUBHca6JvIqEVR7ShW0DOkhOanbUydATNYOR/ZdHC2BCtdBWIO+J VGpYuUTKWwlsPR5/SQ+txX7NAmieFElr09rQqwKau/h4ou0MsE+zFfZqE0f/3qMyAfgc ABE7QcVjjzkBr6NvHl6Sqz+rd8N+g1RPDzCIhRFJejE11Im0pGXndREdmfOyK7hB86rs /Zaw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=eR71nWvd; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h12si2472535edj.156.2021.03.11.08.45.36; Thu, 11 Mar 2021 08:45:59 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=eR71nWvd; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229889AbhCKQm6 (ORCPT + 99 others); Thu, 11 Mar 2021 11:42:58 -0500 Received: from mail.kernel.org ([198.145.29.99]:57940 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229601AbhCKQme (ORCPT ); Thu, 11 Mar 2021 11:42:34 -0500 Received: by mail.kernel.org (Postfix) with ESMTPSA id 4193864F9C; Thu, 11 Mar 2021 16:42:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1615480953; bh=/6vQFL+YC53+oP6/fdeoiyO4ZhYeLe3QT/YKKRdQyYY=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=eR71nWvdnbgmZqCoFZFfpumRGVzmdJTDmB64hingCLqVQQRXFhTLfcutl2Bfsxy01 28MHy50cfVkV4BQeNI1j4muoeiVmyUbFZmmFI5HyicrY7tSRG15MqLD1xwvt704x9O 8Zm5HWkhWFUI07wObuNbzQHeYgxuARESL4yTNGHOjX5bOumTWAesVqQnk7K09G9O16 GZA3troXIT6iGqun/ydwipRCYdN1Y3PuuVmAWzdjsfC1snmJYfcw9rZdO5PD+GK70h mRbXGC4DNt0VNFS5UWyRYTklKGLqSLWDYNwJhURI2IwTRw0+0nkuIbmhw54rVRWNGm pjOXWwstfsySg== Date: Thu, 11 Mar 2021 16:41:21 +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: <20210311164121.GH4962@sirena.org.uk> References: <1612939421-19900-2-git-send-email-spujar@nvidia.com> <20210309144156.18887-1-michael@walle.cc> <611ed3362dee3b3b7c7a80edfe763fd0@walle.cc> <36c37df5-dffb-9168-d92f-4b3e482602fa@nvidia.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="gKijDXBCEH69PxaN" Content-Disposition: inline In-Reply-To: X-Cookie: I'm rated PG-34!! User-Agent: Mutt/1.10.1 (2018-07-13) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --gKijDXBCEH69PxaN Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Thu, Mar 11, 2021 at 04:43:20PM +0100, Michael Walle wrote: > This could be a last resort, yes. But I'd rather see a flag which > indicates whether the simple-audio-card should control the (first) > clock of the codec or not. Because until now, this wasn't the case. > And I don't know if this was an oversight or on purpose. Kuninori would > need to comment on that. And with the "we change mclk by default", we > break codecs with automatic sysclk generation. It shouldn't break anything so long as the clock ends up correct via some path. Where there's multiple options we can also try going through them in some order, preferring the clock in the CODEC would probably make sense from both a compatibility and quality point of view. > > > And its fetching just the first clock, doesn't it? What happens if a > > > codec has two clock inputs? > > Yes, it would have been more descriptive if it were specifically > > looking for clock "mclk". I think the original assumption was codec > > takes one input clock (MCLK) and uses it for sysclk. > Yeah, I've just noticed that the clk_get_rate() also only works > for the first clock of the codec. simple-audio-card isn't really intended to work with complex devices, it's very much only for the simplest of use cases. --gKijDXBCEH69PxaN Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQEzBAABCgAdFiEEreZoqmdXGLWf4p/qJNaLcl1Uh9AFAmBKSDAACgkQJNaLcl1U h9BNawf9GPsQcYK9qmE3//5SNFERoM69/yBv84rbvNTtsS0rkB4/XlhUxFM/yrhI 6PbCDI9RiR1smLwcBsrRv9z3/NPQ2sVeW8uOWvWQvXjPMWxSqNSU6XRVUBFBwuZv m4UZqd9ldjRxLGajUkhVCWKCAJ4cx0hx3TvwBjAbKYCfsfFpC6Xx+UcNxsOnMeXt FuzFO4NZ7zmnCBRpsa74nvjfoWdb+FCvh15SVz4anlEeD8fagk5Nf4QZT+KgE+nD xyqchbWdLgFDs4lLfHlxAt/Pu62fPs8gcNPbfVFO8m4Ge638UVbFipmEhoMaubt0 TsIEC7GPWF9EMTk0JQs5kHnrAAAoQA== =EORL -----END PGP SIGNATURE----- --gKijDXBCEH69PxaN--