alsa-devel.alsa-project.org archive mirror
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: "Péter Ujfalusi" <peter.ujfalusi@ti.com>
Cc: "alsa-devel@alsa-project.org" <alsa-devel@alsa-project.org>,
	"Girdwood, Liam" <lrg@ti.com>,
	"Lopez Cruz, Misael" <misael.lopez@ti.com>
Subject: Re: [PATCH v3 2/3] ASoC: soc-dapm: API to attach DAPM_SUPPLY to be used for dai
Date: Mon, 29 Aug 2011 10:16:04 +0100	[thread overview]
Message-ID: <20110829091603.GA9477@opensource.wolfsonmicro.com> (raw)
In-Reply-To: <4740107.jCnGMjlvlq@barack>

On Mon, Aug 29, 2011 at 11:22:52AM +0300, Péter Ujfalusi wrote:
> On Friday 26 August 2011 21:05:02 Mark Brown wrote:
> > This wasn't really what I meant - what I meant was that we ought to be
> > able to change the ordering of DAPM with regard to the stream shutdown
> > without having to have anything more than flags in the devices that can
> > or need to do it (I'd expect more the CODECs more than the CPUs).

> I see, but this is not what I'm trying to achieve here.
> Even, if we could re-order the stream shutdown (for DAIs mostly) and DAPM 
> sequence it won't work for me:
> I need to make sure that the cpu_dai (McPDM) is shut down _after the DAC/ADC, 
> and _before_ the codec is powered down - which would stop the McPDM clocks - 
> which in turn used by McPDM as functional clock.

That's not what you said before...  I did post the sequence I was
suggesting and you seemed fine with it.  Please try to be clear about
what you're trying to do here - previously you'd just said that you
needed to make sure the CODEC was powered down prior to the CPU being
stopped but now you're adding additional stuff here.

Could you please clarify what exactly the system looks like here and
what you need to do?  I'm struggling to understand how you've got PDM
output links providing clocks back into the CPU - usually a PDM output
is two wires going in one direction.  I also don't entirely understand
why your current approach will be robust, though it should be an
improvement on the original change to just put a delay in the shutdown.
You can't rely on pmdown_time happening at all as it's user configurable
and only happens for some cases even when it's there.

> If we really want to reorder the stream shutdown and DAPM, we need to quite a 
> bit of change, since we need to be able to 'delay' the shutdown operations for 
> DAIs/platforms at least. But. Since the stream has been already closed, we can 
> not refer to it anymore in case of pmdown_time > 0 (playback only issue).

Part of what I'm suggesting is that we may as well not bother with the
pmdown_time timeout if we need to shut the DAI down while we're shutting
the CODEC down anyway, the whole thing may as well get shut down at once
which will be a little more power efficient.

> These would work, mostly, but I'm not convinced, that it would work for me, so 
> I anyway need to do something similar as in this series.

Like I say I'm not convinced I understand what you need to do yet.  It
would be easier if we could merge the updated McPDM driver and worry
about this separately; I don't understand why you can't just inline the
event into the regular teardown (it will be noisy but it should at least
run).

  reply	other threads:[~2011-08-29  9:16 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-08-26 13:33 [PATCH v3 0/3] ASoC: omap-mcpdm: New McPDM driver Peter Ujfalusi
2011-08-26 13:33 ` [PATCH v3 1/3] ASoC: DAPM: Add private data pointer for DAPM widget Peter Ujfalusi
2011-08-26 13:33 ` [PATCH v3 2/3] ASoC: soc-dapm: API to attach DAPM_SUPPLY to be used for dai Peter Ujfalusi
2011-08-26 19:05   ` Mark Brown
2011-08-29  8:22     ` Péter Ujfalusi
2011-08-29  9:16       ` Mark Brown [this message]
2011-08-29 11:41         ` Péter Ujfalusi
2011-09-03  6:31           ` Mark Brown
2011-09-06 10:21             ` Péter Ujfalusi
2011-09-06 15:09               ` Mark Brown
2011-08-26 13:33 ` [PATCH v3 3/3] ASoC: omap-mcpdm: Replace legacy driver Peter Ujfalusi

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=20110829091603.GA9477@opensource.wolfsonmicro.com \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=lrg@ti.com \
    --cc=misael.lopez@ti.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;
as well as URLs for NNTP newsgroup(s).