public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@kernel.org>
To: Sylwester Nawrocki <s.nawrocki@samsung.com>
Cc: Charles Keepax <ckeepax@opensource.wolfsonmicro.com>,
	alsa-devel@alsa-project.org, lee.jones@linaro.org,
	linux-kernel@vger.kernel.org
Subject: Re: [alsa-devel] [RFC PATCH] mfd: arizona: Add gating of external MCLKn clocks
Date: Mon, 22 Aug 2016 18:41:04 +0100	[thread overview]
Message-ID: <20160822174104.GT22076@sirena.org.uk> (raw)
In-Reply-To: <d47e7106-037f-b40c-71e5-099ee30874e6@samsung.com>

[-- Attachment #1: Type: text/plain, Size: 1149 bytes --]

On Mon, Aug 22, 2016 at 07:22:47PM +0200, Sylwester Nawrocki wrote:

> I got suggestion from Mark not to request the main MCLK clock
> in the machine driver.  But even if gating of that clock was
> added to the CODEC driver I would need to get hold of it in
> the machine driver to get rate of MCLK.  So I thought about
> exporting a helper from the MFD for requesting MCLK clock or
> specifying MCLK clock back in the sound DT node.

No, the immediate suggestion is more about the requesting bit than the
management bit - once the DT is there it's set in stone.

> If we provided an interface like:

> struct clk * arizona_get_mclk(struct arizona *arizona, int id);
> void arizona_put_mclk(struct clk *clk);

> the machine driver would need to get hold of struct arizona*,
> which is not that straightforward if we are given on CODEC
> of_node (it can be a child of I2S or SPI bus).

We could add an interface for the machine driver to retrieve a clock
from the CODEC as a transition measure...

> Then how about specifying MCLK in the sound node and using
> regular devm_clk_get()?

This is what we're trying to avoid?

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 473 bytes --]

  reply	other threads:[~2016-08-22 17:41 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-08-19 17:17 [RFC PATCH] mfd: arizona: Add gating of external MCLKn clocks Sylwester Nawrocki
2016-08-22  9:22 ` Charles Keepax
2016-08-22 17:22   ` [alsa-devel] " Sylwester Nawrocki
2016-08-22 17:41     ` Mark Brown [this message]
2016-08-23 16:44       ` Sylwester Nawrocki
2016-08-23 16:28     ` Charles Keepax
2016-08-25 10:18       ` Sylwester Nawrocki
2016-08-25 13:02         ` Charles Keepax
2016-08-25 13:26           ` Sylwester Nawrocki

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160822174104.GT22076@sirena.org.uk \
    --to=broonie@kernel.org \
    --cc=alsa-devel@alsa-project.org \
    --cc=ckeepax@opensource.wolfsonmicro.com \
    --cc=lee.jones@linaro.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=s.nawrocki@samsung.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox