linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexandre Belloni <alexandre.belloni@bootlin.com>
To: Mark Brown <broonie@kernel.org>
Cc: Miquel Raynal <miquel.raynal@bootlin.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Jaroslav Kysela <perex@perex.cz>, Takashi Iwai <tiwai@suse.com>,
	alsa-devel@alsa-project.org, linux-kernel@vger.kernel.org,
	Thomas Petazzoni <thomas.petazzoni@bootlin.com>
Subject: Re: [PATCH 3/3] ASoC: tlv320aic32x4: Enable fast charge
Date: Tue, 15 Sep 2020 15:02:07 +0200	[thread overview]
Message-ID: <20200915130207.GA9675@piout.net> (raw)
In-Reply-To: <20200915115034.GA5576@sirena.org.uk>

On 15/09/2020 12:50:34+0100, Mark Brown wrote:
> On Tue, Sep 15, 2020 at 10:26:02AM +0200, Alexandre Belloni wrote:
> > On 11/09/2020 19:31:40+0200, Miquel Raynal wrote:
> 
> > > +	/*
> > > +	 * Enable the fast charging feature and ensure the needed 40ms ellapsed
> > > +	 * before using the analog circuits.
> > > +	 */
> > > +	snd_soc_component_write(component, AIC32X4_REFPOWERUP,
> > > +				AIC32X4_REFPOWERUP_40MS);
> > > +	msleep(40);
> > > +
> 
> > Maybe the actual REFPOWERUP value could be exposed as a control so
> > userspace has a way to set the policy? 
> 
> We very rarely do this, there's not usially anything 
> 

Could you suggest something then? This mainly changes the power
codec power consumption. I guess people will want to trade latency
for less consumption.

> > I'm not sure it make sense to have the delay in probe because it is not
> > enable the analog part of the codec. The delay should probable be after
> > the clocks have been set up because the datasheet says that it is mdac
> > and madc that is starting the analog circuitry.
> 
> Deferring the delay to a workqueue is the usual thing where there's
> concerns about slowing down boot.

Well, that was not my concern. I didn't realize Miquel actually used the
Force power-up values and though the actual power up happened after
configuring the clocks (as is the case for the dafule values). In this
case, the delay is at the proper location.

-- 
Alexandre Belloni, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

  reply	other threads:[~2020-09-16  0:43 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-09-11 17:31 [PATCH 0/3] tlv320aic3xx4 updates Miquel Raynal
2020-09-11 17:31 ` [PATCH 1/3] ASoC: tlv320aic32x4: Ensure a minimum delay before clock stabilization Miquel Raynal
2020-09-11 17:31 ` [PATCH 2/3] ASoC: tlv320aic32x4: Fix bdiv clock rate derivation Miquel Raynal
2020-09-11 17:31 ` [PATCH 3/3] ASoC: tlv320aic32x4: Enable fast charge Miquel Raynal
2020-09-15  8:26   ` Alexandre Belloni
2020-09-15 11:50     ` Mark Brown
2020-09-15 13:02       ` Alexandre Belloni [this message]
2020-09-15 14:10         ` Mark Brown
2020-09-15 14:14           ` Miquel Raynal
2020-09-15 14:27             ` Alexandre Belloni
2020-09-15 15:46               ` Mark Brown
2020-09-21 21:40 ` [PATCH 0/3] tlv320aic3xx4 updates 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=20200915130207.GA9675@piout.net \
    --to=alexandre.belloni@bootlin.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=miquel.raynal@bootlin.com \
    --cc=perex@perex.cz \
    --cc=thomas.petazzoni@bootlin.com \
    --cc=tiwai@suse.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).