diff mbox series

[v2,04/11] arm64: dts: meson-g12a-u200: add regulators

Message ID 20190318100458.5619-5-narmstrong@baylibre.com
State New
Headers show
Series None | expand

Commit Message

Neil Armstrong March 18, 2019, 10:04 a.m. UTC
From: Jerome Brunet <jbrunet@baylibre.com>


Add system regulators for the S905D U200 reference design.

Add some regulators. Still missing
* VDD_EE (0.8V - PWM controlled)
* VDD_CPU (PWM controlled)

Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>

Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>

---
 .../boot/dts/amlogic/meson-g12a-u200.dts      | 79 +++++++++++++++++++
 1 file changed, 79 insertions(+)

-- 
2.20.1

Comments

Martin Blumenstingl March 18, 2019, 8:07 p.m. UTC | #1
On Mon, Mar 18, 2019 at 11:06 AM Neil Armstrong <narmstrong@baylibre.com> wrote:
>

> From: Jerome Brunet <jbrunet@baylibre.com>

>

> Add system regulators for the S905D U200 reference design.

>

> Add some regulators. Still missing

> * VDD_EE (0.8V - PWM controlled)

> * VDD_CPU (PWM controlled)

>

> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>

> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>

I have no details about this board but the changes look sane, so:
Acked-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Neil Armstrong April 9, 2019, 10:18 a.m. UTC | #2
Hi Kevin,

Seems this patch is missing in
https://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic.git/log/?h=v5.2/dt64

Thanks,
Neil

On 18/03/2019 11:04, Neil Armstrong wrote:
> From: Jerome Brunet <jbrunet@baylibre.com>

> 

> Add system regulators for the S905D U200 reference design.

> 

> Add some regulators. Still missing

> * VDD_EE (0.8V - PWM controlled)

> * VDD_CPU (PWM controlled)

> 

> Signed-off-by: Jerome Brunet <jbrunet@baylibre.com>

> Signed-off-by: Neil Armstrong <narmstrong@baylibre.com>

> ---

>  .../boot/dts/amlogic/meson-g12a-u200.dts      | 79 +++++++++++++++++++

>  1 file changed, 79 insertions(+)

> 

> diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts b/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts

> index f2afd0bf3e28..c69328d16333 100644

> --- a/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts

> +++ b/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts

> @@ -6,6 +6,8 @@

>  /dts-v1/;

>  

>  #include "meson-g12a.dtsi"

> +#include <dt-bindings/gpio/gpio.h>

> +#include <dt-bindings/gpio/meson-g12a-gpio.h>

>  

>  / {

>  	compatible = "amlogic,u200", "amlogic,g12a";

> @@ -21,6 +23,83 @@

>  		device_type = "memory";

>  		reg = <0x0 0x0 0x0 0x40000000>;

>  	};

> +

> +	flash_1v8: regulator-flash_1v8 {

> +		compatible = "regulator-fixed";

> +		regulator-name = "FLASH_1V8";

> +		regulator-min-microvolt = <1800000>;

> +		regulator-max-microvolt = <1800000>;

> +		vin-supply = <&vcc_3v3>;

> +		regulator-always-on;

> +	};

> +

> +	main_12v: regulator-main_12v {

> +		compatible = "regulator-fixed";

> +		regulator-name = "12V";

> +		regulator-min-microvolt = <12000000>;

> +		regulator-max-microvolt = <12000000>;

> +		regulator-always-on;

> +	};

> +

> +	vcc_1v8: regulator-vcc_1v8 {

> +		compatible = "regulator-fixed";

> +		regulator-name = "VCC_1V8";

> +		regulator-min-microvolt = <1800000>;

> +		regulator-max-microvolt = <1800000>;

> +		vin-supply = <&vcc_3v3>;

> +		regulator-always-on;

> +	};

> +

> +	vcc_3v3: regulator-vcc_3v3 {

> +		compatible = "regulator-fixed";

> +		regulator-name = "VCC_3V3";

> +		regulator-min-microvolt = <3300000>;

> +		regulator-max-microvolt = <3300000>;

> +		vin-supply = <&vddao_3v3>;

> +		regulator-always-on;

> +		/* FIXME: actually controlled by VDDCPU_B_EN */

> +	};

> +

> +	vcc_5v: regulator-vcc_5v {

> +		compatible = "regulator-fixed";

> +		regulator-name = "VCC_5V";

> +		regulator-min-microvolt = <5000000>;

> +		regulator-max-microvolt = <5000000>;

> +		vin-supply = <&main_12v>;

> +

> +		gpio = <&gpio GPIOH_8 GPIO_OPEN_DRAIN>;

> +		enable-active-high;

> +	};

> +

> +	usb_pwr_en: regulator-usb_pwr_en {

> +		compatible = "regulator-fixed";

> +		regulator-name = "USB_PWR_EN";

> +		regulator-min-microvolt = <5000000>;

> +		regulator-max-microvolt = <5000000>;

> +		vin-supply = <&vcc_5v>;

> +

> +		gpio = <&gpio GPIOH_6 GPIO_ACTIVE_HIGH>;

> +		enable-active-high;

> +	};

> +

> +	vddao_1v8: regulator-vddao_1v8 {

> +		compatible = "regulator-fixed";

> +		regulator-name = "VDDAO_1V8";

> +		regulator-min-microvolt = <1800000>;

> +		regulator-max-microvolt = <1800000>;

> +		vin-supply = <&vddao_3v3>;

> +		regulator-always-on;

> +	};

> +

> +	vddao_3v3: regulator-vddao_3v3 {

> +		compatible = "regulator-fixed";

> +		regulator-name = "VDDAO_3V3";

> +		regulator-min-microvolt = <3300000>;

> +		regulator-max-microvolt = <3300000>;

> +		vin-supply = <&main_12v>;

> +		regulator-always-on;

> +	};

> +

>  };

>  

>  &uart_AO {

>
Kevin Hilman April 16, 2019, 12:49 a.m. UTC | #3
Neil Armstrong <narmstrong@baylibre.com> writes:

> Hi Kevin,

>

> Seems this patch is missing in

> https://git.kernel.org/pub/scm/linux/kernel/git/khilman/linux-amlogic.git/log/?h=v5.2/dt64

>


Yup, I noticed it when applying  the rest of the boards peripherals DT.
I've added it now.

Thanks,

Kevin
diff mbox series

Patch

diff --git a/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts b/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts
index f2afd0bf3e28..c69328d16333 100644
--- a/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts
+++ b/arch/arm64/boot/dts/amlogic/meson-g12a-u200.dts
@@ -6,6 +6,8 @@ 
 /dts-v1/;
 
 #include "meson-g12a.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/gpio/meson-g12a-gpio.h>
 
 / {
 	compatible = "amlogic,u200", "amlogic,g12a";
@@ -21,6 +23,83 @@ 
 		device_type = "memory";
 		reg = <0x0 0x0 0x0 0x40000000>;
 	};
+
+	flash_1v8: regulator-flash_1v8 {
+		compatible = "regulator-fixed";
+		regulator-name = "FLASH_1V8";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <1800000>;
+		vin-supply = <&vcc_3v3>;
+		regulator-always-on;
+	};
+
+	main_12v: regulator-main_12v {
+		compatible = "regulator-fixed";
+		regulator-name = "12V";
+		regulator-min-microvolt = <12000000>;
+		regulator-max-microvolt = <12000000>;
+		regulator-always-on;
+	};
+
+	vcc_1v8: regulator-vcc_1v8 {
+		compatible = "regulator-fixed";
+		regulator-name = "VCC_1V8";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <1800000>;
+		vin-supply = <&vcc_3v3>;
+		regulator-always-on;
+	};
+
+	vcc_3v3: regulator-vcc_3v3 {
+		compatible = "regulator-fixed";
+		regulator-name = "VCC_3V3";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+		vin-supply = <&vddao_3v3>;
+		regulator-always-on;
+		/* FIXME: actually controlled by VDDCPU_B_EN */
+	};
+
+	vcc_5v: regulator-vcc_5v {
+		compatible = "regulator-fixed";
+		regulator-name = "VCC_5V";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		vin-supply = <&main_12v>;
+
+		gpio = <&gpio GPIOH_8 GPIO_OPEN_DRAIN>;
+		enable-active-high;
+	};
+
+	usb_pwr_en: regulator-usb_pwr_en {
+		compatible = "regulator-fixed";
+		regulator-name = "USB_PWR_EN";
+		regulator-min-microvolt = <5000000>;
+		regulator-max-microvolt = <5000000>;
+		vin-supply = <&vcc_5v>;
+
+		gpio = <&gpio GPIOH_6 GPIO_ACTIVE_HIGH>;
+		enable-active-high;
+	};
+
+	vddao_1v8: regulator-vddao_1v8 {
+		compatible = "regulator-fixed";
+		regulator-name = "VDDAO_1V8";
+		regulator-min-microvolt = <1800000>;
+		regulator-max-microvolt = <1800000>;
+		vin-supply = <&vddao_3v3>;
+		regulator-always-on;
+	};
+
+	vddao_3v3: regulator-vddao_3v3 {
+		compatible = "regulator-fixed";
+		regulator-name = "VDDAO_3V3";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+		vin-supply = <&main_12v>;
+		regulator-always-on;
+	};
+
 };
 
 &uart_AO {