From: Lars-Peter Clausen <lars@metafoo.de>
To: Mark Brown <broonie@kernel.org>
Cc: Peter Ujfalusi <peter.ujfalusi@ti.com>,
alsa-devel@alsa-project.org, Liam Girdwood <lgirdwood@gmail.com>,
Jarkko Nikula <jarkko.nikula@bitmer.com>,
Grazvydas Ignotas <notasas@gmail.com>
Subject: Re: [PATCH 1/3] ASoC: omap-abe-twl6040: No need to register DMIC routes seperatly
Date: Mon, 10 Mar 2014 11:27:39 +0100 [thread overview]
Message-ID: <531D939B.4050102@metafoo.de> (raw)
In-Reply-To: <20140310101038.GO28112@sirena.org.uk>
On 03/10/2014 11:10 AM, Mark Brown wrote:
> On Mon, Mar 10, 2014 at 10:24:49AM +0100, Lars-Peter Clausen wrote:
>> On 03/10/2014 10:12 AM, Mark Brown wrote:
>
>>> In general anything keying this stuff off DT is going to have that sort
>>> of thing going on - most if not all of the things that are registering
>>> in several chunks are doing so because some of it is conditional.
>
>> Before we had the support for card table based setup you'd had to
>> register them in chunks, because the components became available one
>> after another and you couldn't register DAPM elements for one
>> component in the callback of another one. When using the table based
>> setup the widgets are registered before all components are
>> registered and the routes are registered after all the components
>> have been registered.
>
> No, that's not the case at all - what makes you think that's the case?
The code ;)
> All table based setup did was move things from code to data, I'm not
> sure what you mean by registering DAPM elements from one component in
> the callback for another.
I meant the card level DAPM elements that are related to a certain
component. Not the DAPM elements of the component itself.
> The only thing that should be registering
> things for other components is the card and the general idea was to
> register everything in late_probe().
>
What most machine drivers did before card table based setup is to have a
per-component callback in which they did register the card DAPM elements
associated with that component. E.g. routes from the CODEC output to a
speaker, etc. You couldn't register the card level DAPM elements for one
component in the init callback component of another one since the routes
depend on the widgets being registered first. So those board drivers kept
separate routes and widget tables for separate components. With table based
setup for the card the routes are registered after all components have been
registered, which means you can register all the routes via one table since
all the dependencies are ready. Same is true if you use the card's
late_probe callback to register the DAPM routes and widgets.
- Lars
next prev parent reply other threads:[~2014-03-10 10:27 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-08 18:16 [PATCH 1/3] ASoC: omap-abe-twl6040: No need to register DMIC routes seperatly Lars-Peter Clausen
2014-03-08 18:16 ` [PATCH 2/3] ASoC: rx51: Convert to table based control and DAPM setup Lars-Peter Clausen
2014-03-08 18:16 ` [PATCH 3/3] ASoC: omap3pandora: Convert to table based " Lars-Peter Clausen
2014-03-10 8:13 ` [PATCH 1/3] ASoC: omap-abe-twl6040: No need to register DMIC routes seperatly Peter Ujfalusi
2014-03-10 8:18 ` Lars-Peter Clausen
2014-03-10 9:12 ` Mark Brown
2014-03-10 9:24 ` Lars-Peter Clausen
2014-03-10 10:10 ` Mark Brown
2014-03-10 10:27 ` Lars-Peter Clausen [this message]
2014-03-10 11:05 ` Mark Brown
2014-03-10 11:29 ` Lars-Peter Clausen
2014-03-10 12:09 ` Mark Brown
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=531D939B.4050102@metafoo.de \
--to=lars@metafoo.de \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=jarkko.nikula@bitmer.com \
--cc=lgirdwood@gmail.com \
--cc=notasas@gmail.com \
--cc=peter.ujfalusi@ti.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