public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Bjorn Andersson <bjorn.andersson@linaro.org>
To: Laxman Dewangan <ldewangan@nvidia.com>
Cc: broonie@kernel.org, robh+dt@kernel.org, pawel.moll@arm.com,
	mark.rutland@arm.com, ijc+devicetree@hellion.org.uk,
	lgirdwood@gmail.com, bjorn.andersson@sonymobile.com,
	swarren@wwwdotorg.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 1/2] regulator: DT: Add support to scale ramp delay based on platform behavior
Date: Mon, 29 Feb 2016 09:47:51 -0800	[thread overview]
Message-ID: <20160229174751.GQ21240@tuxbot> (raw)
In-Reply-To: <1456756829-2277-1-git-send-email-ldewangan@nvidia.com>

On Mon 29 Feb 06:40 PST 2016, Laxman Dewangan wrote:

> It is observed that voltage change in given rail affected by the load
> and the capacitor in the rail. This may cause the slow ramp in voltage
> against what PMIC has programmed.
> 
> The property regulator-ramp-delay provides the ramp delay configuration
> for PMIC but actual voltage settling time may change based on platform.
> 
> Add new property "regulator-ramp-delay-scale" for platform specific scaling
> in final ramp delay calculation. On this case, final wait delay time
> for voltage change is calculated as the
>    DIV_ROUND_UP(ramp_delay * ramp_delay_scale, 100)
> 
> The value is provided in the term of percentage i.e. 300% means it will
> do the 3x delay of calculated value.
> 
> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
> ---

The regulator-ramp-delay is a variable you can tweak on a board basis,
so I'm not sure what benefit it gives to be able to add a scaling
factor to this.

In my experience your HW engineer will say "you have to wait X ms", not
"you have to wait 125% of X ms".


Can you please elaborate on why the original knob isn't sufficient?

Regards,
Bjorn

>  Documentation/devicetree/bindings/regulator/regulator.txt | 7 +++++++
>  1 file changed, 7 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/regulator/regulator.txt b/Documentation/devicetree/bindings/regulator/regulator.txt
> index 1d112fc..f2e8360 100644
> --- a/Documentation/devicetree/bindings/regulator/regulator.txt
> +++ b/Documentation/devicetree/bindings/regulator/regulator.txt
> @@ -16,6 +16,13 @@ Optional properties:
>  - regulator-ramp-delay: ramp delay for regulator(in uV/uS)
>    For hardware which supports disabling ramp rate, it should be explicitly
>    initialised to zero (regulator-ramp-delay = <0>) for disabling ramp delay.
> +- regulator-ramp-delay-scale: Platform specific scaling in ramp delay to
> +  provide extra guard time to settle down voltage after its change. This will
> +  help to wait for extra time for voltage settling based on platform behavior.
> +  This is provided in terms of percentage scaling like 300% means final delay
> +  will become 3x of calculated ramp delay for voltage change.
> +  The final delay is calculated as:
> +	delay = DIV_ROUND_UP(ramp-delay * ramp-delay-scale, 100)
>  - regulator-enable-ramp-delay: The time taken, in microseconds, for the supply
>    rail to reach the target voltage, plus/minus whatever tolerance the board
>    design requires. This property describes the total system ramp time
> -- 
> 2.1.4
> 

  parent reply	other threads:[~2016-02-29 17:48 UTC|newest]

Thread overview: 40+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-29 14:40 [PATCH 1/2] regulator: DT: Add support to scale ramp delay based on platform behavior Laxman Dewangan
2016-02-29 14:40 ` [PATCH 2/2] regulator: " Laxman Dewangan
2016-02-29 17:47 ` Bjorn Andersson [this message]
2016-03-01  2:23   ` [PATCH 1/2] regulator: DT: " Mark Brown
2016-03-01  3:48     ` Laxman Dewangan
2016-03-02  3:38       ` Mark Brown
2016-03-02  3:35         ` Laxman Dewangan
2016-03-02  4:35           ` Mark Brown
2016-03-02  6:12             ` Laxman Dewangan
2016-03-15 13:41             ` Laxman Dewangan
2016-03-15 14:48               ` Mark Brown
2016-03-16 11:30                 ` Laxman Dewangan
2016-03-19  4:31               ` Bjorn Andersson
2016-03-19  8:35                 ` Laxman Dewangan
2016-03-30 13:29                   ` Laxman Dewangan
2016-03-30 18:16                     ` Mark Brown
2016-03-31  7:06                       ` Laxman Dewangan
2016-03-31 16:51                         ` Mark Brown
2016-03-31 17:13                           ` Laxman Dewangan
2016-03-31 17:47                             ` Mark Brown
2016-03-31 17:47                               ` Laxman Dewangan
2016-03-31 18:31                                 ` Mark Brown
2016-03-31 18:31                                   ` Laxman Dewangan
2016-03-31 18:45                                     ` Mark Brown
2016-03-31 18:39                                       ` Laxman Dewangan
2016-03-31 18:59                                         ` Mark Brown
2016-03-31 18:59                                           ` Laxman Dewangan
2016-03-31 19:22                                             ` Mark Brown
2016-03-31 19:48                                               ` Laxman Dewangan
2016-03-31 20:39                                                 ` Mark Brown
2016-04-01  7:15                                                   ` Laxman Dewangan
2016-04-01 16:11                                                     ` Mark Brown
2016-04-05  8:01                                                       ` Laxman Dewangan
2016-04-12  1:02                                                         ` Mark Brown
2016-04-12 13:29                                                           ` Laxman Dewangan
2016-04-13  6:53                                                             ` Mark Brown
2016-04-19 10:01                                                               ` Laxman Dewangan
2016-04-19 10:55                                                                 ` Mark Brown
2016-04-19 10:56                                                                   ` Laxman Dewangan
2016-04-19 15:47                                                                     ` 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=20160229174751.GQ21240@tuxbot \
    --to=bjorn.andersson@linaro.org \
    --cc=bjorn.andersson@sonymobile.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=ijc+devicetree@hellion.org.uk \
    --cc=ldewangan@nvidia.com \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=pawel.moll@arm.com \
    --cc=robh+dt@kernel.org \
    --cc=swarren@wwwdotorg.org \
    /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