All of lore.kernel.org
 help / color / mirror / Atom feed
From: Angus Ainslie <angus@akkea.ca>
To: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>
Cc: mazzisaccount@gmail.com, Lee Jones <lee.jones@linaro.org>,
	Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	Liam Girdwood <lgirdwood@gmail.com>,
	Mark Brown <broonie@kernel.org>,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	heikki.haikola@fi.rohmeurope.com,
	mikko.mutanen@fi.rohmeurope.com, Robin Gong <yibin.gong@nxp.com>,
	Elven Wang <elven.wang@nxp.com>,
	Anson Huang <anson.huang@nxp.com>,
	Angus Ainslie <angus.ainslie@puri.sm>,
	linux-kernel-owner@vger.kernel.org
Subject: Re: [PATCH v3 1/3] devicetree: bindings: bd718x7: document HW state  related ROHM specific properties
Date: Thu, 14 Feb 2019 06:58:35 -0800	[thread overview]
Message-ID: <b5d87fef13b16e8b5da8bd88958c6d74@www.akkea.ca> (raw)
In-Reply-To: <6ed4238fb083f52de0f5f013647b2334bad8ebe4.1550135853.git.matti.vaittinen@fi.rohmeurope.com>

On 2019-02-14 01:34, Matti Vaittinen wrote:
> Add ROHM BD71837 / BD71847 specific device tree bindings for
> controlling the PMIC shutdown/reset states and voltages for
> different HW states. The PMIC was designed to be used with NXP
> i.MX8 SoC and it supports SNVS low power state which seems to
> be typical for NXP i.MX SoCs. However, when SNVS is used we must
> not allow SW to control enabling/disabling those regulators which
> are crucial for system to boot as there is a HW limitation which
> causes SW controlled regulators to be kept shut down after SNVS
> reset.
> 
> Allow setting the SNVS to be used as reset target state and allow
> marking those regulators which are critical for boot.
> 
> Signed-off-by: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>

One small nit below

Tested-by: Angus Ainslie <angus@akkea.ca>
Reviewed-by: Angus Ainslie <angus@akkea.ca>

> ---
>  .../devicetree/bindings/mfd/rohm,bd71837-pmic.txt  | 17 ++++++++++
>  .../bindings/regulator/rohm,bd71837-regulator.txt  | 38 
> ++++++++++++++++++++++
>  2 files changed, 55 insertions(+)
> 
> diff --git
> a/Documentation/devicetree/bindings/mfd/rohm,bd71837-pmic.txt
> b/Documentation/devicetree/bindings/mfd/rohm,bd71837-pmic.txt
> index a4b056761eaa..d5f68ac78d15 100644
> --- a/Documentation/devicetree/bindings/mfd/rohm,bd71837-pmic.txt
> +++ b/Documentation/devicetree/bindings/mfd/rohm,bd71837-pmic.txt
> @@ -23,6 +23,20 @@ Required properties:
> 
>  Optional properties:
>  - clock-output-names	: Should contain name for output clock.
> +- rohm,reset-snvs-powered : Transfer BD718x7 to SNVS state at reset.
> +
> +The BD718x7 supports two different HW states as reset target states. 
> States
> +are called as SNVS and READY. At READY state all the PMIC power 
> outputs go
> +down and OTP is reload. At the SNVS state all other logic and external
> +devices apart from the SNVS power domain are shut off. Please refer to 
> NXP
> +i.MX8 documentation for further information regarding SNVS state. When 
> a
> +reset is done via SNVS state the PMIC OTP data is not reload. This 
> causes

Typo s/reload/reloaded/

> +power outputs that have been under SW control to stay down when reset 
> has
> +switched power state to SNVS. If reset is done via READY state the 
> power
> +outputs will be returned to HW control by OTP loading. Thus the reset
> +target state is set to READY by default. If SNVS state is used the 
> boot
> +crucial regulators must have the regulator-always-on and 
> regulator-boot-on
> +properties set in regulator node.
> 
>  Example:
> 
> @@ -43,6 +57,7 @@ Example:
>  		#clock-cells = <0>;
>  		clocks = <&osc 0>;
>  		clock-output-names = "bd71837-32k-out";
> +		rohm,reset-snvs-powered;
> 
>  		regulators {
>  			buck1: BUCK1 {
> @@ -50,8 +65,10 @@ Example:
>  				regulator-min-microvolt = <700000>;
>  				regulator-max-microvolt = <1300000>;
>  				regulator-boot-on;
> +				regulator-always-on;
>  				regulator-ramp-delay = <1250>;
>  			};
> +			// [...]
>  		};
>  	};
> 
> diff --git
> a/Documentation/devicetree/bindings/regulator/rohm,bd71837-regulator.txt
> b/Documentation/devicetree/bindings/regulator/rohm,bd71837-regulator.txt
> index 4b98ca26e61a..cbce62c22b60 100644
> --- 
> a/Documentation/devicetree/bindings/regulator/rohm,bd71837-regulator.txt
> +++ 
> b/Documentation/devicetree/bindings/regulator/rohm,bd71837-regulator.txt
> @@ -27,8 +27,38 @@ BUCK1, BUCK2, BUCK3, BUCK4, BUCK5, BUCK6
>  LDO1, LDO2, LDO3, LDO4, LDO5, LDO6
> 
>  Optional properties:
> +- rohm,dvs-run-voltage		: PMIC default "RUN" state voltage in uV.
> +				  See below table for bucks which support this.
> +- rohm,dvs-idle-voltage		: PMIC default "IDLE" state voltage in uV.
> +				  See below table for bucks which support this.
> +- rohm,dvs-suspend-voltage	: PMIC default "SUSPEND" state voltage in 
> uV.
> +				  See below table for bucks which support this.
>  - Any optional property defined in bindings/regulator/regulator.txt
> 
> +Supported default DVS states:
> +
> +BD71837:
> +buck	| dvs-run-voltage	| dvs-idle-voltage	| dvs-suspend-voltage
> +-----------------------------------------------------------------------------
> +1	| supported		| supported		| supported
> +----------------------------------------------------------------------------
> +2	| supported		| supported		| not supported
> +----------------------------------------------------------------------------
> +3	| supported		| not supported		| not supported
> +----------------------------------------------------------------------------
> +4	| supported		| not supported		| not supported
> +----------------------------------------------------------------------------
> +rest	| not supported		| not supported		| not supported
> +
> +BD71847:
> +buck	| dvs-run-voltage	| dvs-idle-voltage	| dvs-suspend-voltage
> +-----------------------------------------------------------------------------
> +1	| supported		| supported		| supported
> +----------------------------------------------------------------------------
> +2	| supported		| supported		| not supported
> +----------------------------------------------------------------------------
> +rest	| not supported		| not supported		| not supported
> +
>  Example:
>  regulators {
>  	buck1: BUCK1 {
> @@ -36,7 +66,11 @@ regulators {
>  		regulator-min-microvolt = <700000>;
>  		regulator-max-microvolt = <1300000>;
>  		regulator-boot-on;
> +		regulator-always-on;
>  		regulator-ramp-delay = <1250>;
> +		rohm,dvs-run-voltage = <900000>;
> +		rohm,dvs-idle-voltage = <850000>;
> +		rohm,dvs-suspend-voltage = <800000>;
>  	};
>  	buck2: BUCK2 {
>  		regulator-name = "buck2";
> @@ -45,18 +79,22 @@ regulators {
>  		regulator-boot-on;
>  		regulator-always-on;
>  		regulator-ramp-delay = <1250>;
> +		rohm,dvs-run-voltage = <1000000>;
> +		rohm,dvs-idle-voltage = <900000>;
>  	};
>  	buck3: BUCK3 {
>  		regulator-name = "buck3";
>  		regulator-min-microvolt = <700000>;
>  		regulator-max-microvolt = <1300000>;
>  		regulator-boot-on;
> +		rohm,dvs-run-voltage = <1000000>;
>  	};
>  	buck4: BUCK4 {
>  		regulator-name = "buck4";
>  		regulator-min-microvolt = <700000>;
>  		regulator-max-microvolt = <1300000>;
>  		regulator-boot-on;
> +		rohm,dvs-run-voltage = <1000000>;
>  	};
>  	buck5: BUCK5 {
>  		regulator-name = "buck5";
> --
> 2.14.3


  reply	other threads:[~2019-02-14 14:58 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-02-14  9:34 [PATCH v3 0/3] bd718x7: Support SNVS low power state Matti Vaittinen
2019-02-14  9:34 ` [PATCH v3 1/3] devicetree: bindings: bd718x7: document HW state related ROHM specific properties Matti Vaittinen
2019-02-14 14:58   ` Angus Ainslie [this message]
2019-03-20 13:02   ` Lee Jones
2019-03-20 14:17     ` Matti Vaittinen
2019-03-21  8:23       ` Lee Jones
2019-03-21 12:50         ` Vaittinen, Matti
2019-03-25  6:28           ` Lee Jones
2019-02-14  9:38 ` [PATCH v3 2/3] regulator: add regulator_desc_list_voltage_linear_range Matti Vaittinen
2019-02-14 14:59   ` Angus Ainslie
2019-02-14  9:39 ` [PATCH v3 3/3] regulator: bd718x7: Support SNVS low power state Matti Vaittinen
2019-02-14 15:00   ` Angus Ainslie

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=b5d87fef13b16e8b5da8bd88958c6d74@www.akkea.ca \
    --to=angus@akkea.ca \
    --cc=angus.ainslie@puri.sm \
    --cc=anson.huang@nxp.com \
    --cc=broonie@kernel.org \
    --cc=devicetree@vger.kernel.org \
    --cc=elven.wang@nxp.com \
    --cc=heikki.haikola@fi.rohmeurope.com \
    --cc=lee.jones@linaro.org \
    --cc=lgirdwood@gmail.com \
    --cc=linux-kernel-owner@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=matti.vaittinen@fi.rohmeurope.com \
    --cc=mazzisaccount@gmail.com \
    --cc=mikko.mutanen@fi.rohmeurope.com \
    --cc=robh+dt@kernel.org \
    --cc=yibin.gong@nxp.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.