ARM: dts: stm32: Fix AV96 and DHCOR split
authorMarek Vasut <marex@denx.de>
Mon, 27 Apr 2020 11:16:02 +0000 (13:16 +0200)
committerPatrick Delaunay <patrick.delaunay@st.com>
Thu, 14 May 2020 07:02:12 +0000 (09:02 +0200)
The commit 132e5b68986d ("ARM: dts: stm32: Split AV96 into DHCOR SoM
and AV96 board") was not applied correctly and in full, and omitted
an important split of the SoM into 3V3 and 1V8 options. The Avenger96
board is based on the 1V8 IO option of the DHCOR SoM, however this is
an optional modification of the 3V3 IO DHCOR SoM with extra on-SoM
regulator to cater for the 96boards 1V8 IO requirements.

Reinstate the split between the 1V8 and 3V3 IO variants.

Fixes: 132e5b68986d ("ARM: dts: stm32: Split AV96 into DHCOR SoM and AV96 board")
Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
Cc: Patrick Delaunay <patrick.delaunay@st.com>
Cc: Patrice Chotard <patrice.chotard@st.com>
Reviewed-by: Patrick Delaunay <patrick.delaunay@st.com>
arch/arm/dts/stm32mp15xx-dhcor-avenger96.dts
arch/arm/dts/stm32mp15xx-dhcor-io1v8.dtsi [new file with mode: 0644]
arch/arm/dts/stm32mp15xx-dhcor-io3v3.dtsi [new file with mode: 0644]
arch/arm/dts/stm32mp15xx-dhcor.dtsi [deleted file]

index a6006775637ccbc6d2578d481521a3c719a5b655..1b0579c8abddb4ce6b727d9f1c7a5d62b2b8a3e2 100644 (file)
@@ -7,7 +7,7 @@
 
 /dts-v1/;
 
-#include "stm32mp15xx-dhcor.dtsi"
+#include "stm32mp15xx-dhcor-io1v8.dtsi"
 #include "stm32mp15xx-dhcor-avenger96-u-boot.dtsi"
 
 / {
diff --git a/arch/arm/dts/stm32mp15xx-dhcor-io1v8.dtsi b/arch/arm/dts/stm32mp15xx-dhcor-io1v8.dtsi
new file mode 100644 (file)
index 0000000..7543542
--- /dev/null
@@ -0,0 +1,24 @@
+// SPDX-License-Identifier: (GPL-2.0 OR BSD-3-Clause)
+/*
+ * Copyright (C) 2020 Marek Vasut <marex@denx.de>
+ */
+
+#include "stm32mp15xx-dhcor-io3v3.dtsi"
+
+/ {
+       /* Enpirion EP3A8LQI U2 on the 1V8 IO DHCOR */
+       vdd_io: regulator-buck-io {
+               compatible = "regulator-fixed";
+               regulator-name = "buck-io";
+               regulator-min-microvolt = <1800000>;
+               regulator-max-microvolt = <1800000>;
+               regulator-always-on;
+               regulator-boot-on;
+               vin-supply = <&vdd>;
+       };
+};
+
+&pwr_regulators {
+       vdd-supply = <&vdd_io>;
+       vdd_3v3_usbfs-supply = <&vdd_usb>;
+};
diff --git a/arch/arm/dts/stm32mp15xx-dhcor-io3v3.dtsi b/arch/arm/dts/stm32mp15xx-dhcor-io3v3.dtsi
new file mode 100644 (file)
index 0000000..248fc45
--- /dev/null
@@ -0,0 +1,221 @@
+// SPDX-License-Identifier: (GPL-2.0 OR BSD-3-Clause)
+/*
+ * Copyright (C) Linaro Ltd 2019 - All Rights Reserved
+ * Author: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
+ * Copyright (C) 2020 Marek Vasut <marex@denx.de>
+ */
+/dts-v1/;
+
+#include "stm32mp157.dtsi"
+#include "stm32mp15-pinctrl.dtsi"
+#include "stm32mp15xxac-pinctrl.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/mfd/st,stpmic1.h>
+
+/ {
+       aliases {
+               spi0 = &qspi;
+       };
+
+       memory@c0000000 {
+               device_type = "memory";
+               reg = <0xc0000000 0x40000000>;
+       };
+};
+
+&i2c4 {
+       pinctrl-names = "default";
+       pinctrl-0 = <&i2c4_pins_a>;
+       i2c-scl-rising-time-ns = <185>;
+       i2c-scl-falling-time-ns = <20>;
+       status = "okay";
+       /delete-property/dmas;
+       /delete-property/dma-names;
+
+       pmic: stpmic@33 {
+               compatible = "st,stpmic1";
+               reg = <0x33>;
+               interrupts-extended = <&exti 55 IRQ_TYPE_EDGE_FALLING>;
+               interrupt-controller;
+               #interrupt-cells = <2>;
+               status = "okay";
+
+               st,main-control-register = <0x04>;
+               st,vin-control-register = <0xc0>;
+               st,usb-control-register = <0x30>;
+
+               regulators {
+                       compatible = "st,stpmic1-regulators";
+
+                       ldo1-supply = <&v3v3>;
+                       ldo2-supply = <&v3v3>;
+                       ldo3-supply = <&vdd_ddr>;
+                       ldo5-supply = <&v3v3>;
+                       ldo6-supply = <&v3v3>;
+                       pwr_sw1-supply = <&bst_out>;
+                       pwr_sw2-supply = <&bst_out>;
+
+                       vddcore: buck1 {
+                               regulator-name = "vddcore";
+                               regulator-min-microvolt = <800000>;
+                               regulator-max-microvolt = <1350000>;
+                               regulator-always-on;
+                               regulator-initial-mode = <0>;
+                               regulator-over-current-protection;
+                       };
+
+                       vdd_ddr: buck2 {
+                               regulator-name = "vdd_ddr";
+                               regulator-min-microvolt = <1350000>;
+                               regulator-max-microvolt = <1350000>;
+                               regulator-always-on;
+                               regulator-initial-mode = <0>;
+                               regulator-over-current-protection;
+                       };
+
+                       vdd: buck3 {
+                               regulator-name = "vdd";
+                               regulator-min-microvolt = <2900000>;
+                               regulator-max-microvolt = <2900000>;
+                               regulator-always-on;
+                               st,mask_reset;
+                               regulator-initial-mode = <0>;
+                               regulator-over-current-protection;
+                       };
+
+                       v3v3: buck4 {
+                               regulator-name = "v3v3";
+                               regulator-min-microvolt = <3300000>;
+                               regulator-max-microvolt = <3300000>;
+                               regulator-always-on;
+                               regulator-over-current-protection;
+                               regulator-initial-mode = <0>;
+                       };
+
+                       vdda: ldo1 {
+                               regulator-name = "vdda";
+                               regulator-min-microvolt = <2900000>;
+                               regulator-max-microvolt = <2900000>;
+                               interrupts = <IT_CURLIM_LDO1 0>;
+                               interrupt-parent = <&pmic>;
+                       };
+
+                       v2v8: ldo2 {
+                               regulator-name = "v2v8";
+                               regulator-min-microvolt = <2800000>;
+                               regulator-max-microvolt = <2800000>;
+                               interrupts = <IT_CURLIM_LDO2 0>;
+                               interrupt-parent = <&pmic>;
+                       };
+
+                       vtt_ddr: ldo3 {
+                               regulator-name = "vtt_ddr";
+                               regulator-min-microvolt = <500000>;
+                               regulator-max-microvolt = <750000>;
+                               regulator-always-on;
+                               regulator-over-current-protection;
+                       };
+
+                       vdd_usb: ldo4 {
+                               regulator-name = "vdd_usb";
+                               regulator-min-microvolt = <3300000>;
+                               regulator-max-microvolt = <3300000>;
+                               interrupts = <IT_CURLIM_LDO4 0>;
+                               interrupt-parent = <&pmic>;
+                       };
+
+                       vdd_sd: ldo5 {
+                               regulator-name = "vdd_sd";
+                               regulator-min-microvolt = <2900000>;
+                               regulator-max-microvolt = <2900000>;
+                               interrupts = <IT_CURLIM_LDO5 0>;
+                               interrupt-parent = <&pmic>;
+                               regulator-boot-on;
+                       };
+
+                       v1v8: ldo6 {
+                               regulator-name = "v1v8";
+                               regulator-min-microvolt = <1800000>;
+                               regulator-max-microvolt = <1800000>;
+                               interrupts = <IT_CURLIM_LDO6 0>;
+                               interrupt-parent = <&pmic>;
+                               regulator-enable-ramp-delay = <300000>;
+                       };
+
+                       vref_ddr: vref_ddr {
+                               regulator-name = "vref_ddr";
+                               regulator-always-on;
+                               regulator-over-current-protection;
+                       };
+
+                       bst_out: boost {
+                               regulator-name = "bst_out";
+                               interrupts = <IT_OCP_BOOST 0>;
+                               interrupt-parent = <&pmic>;
+                       };
+
+                       vbus_otg: pwr_sw1 {
+                               regulator-name = "vbus_otg";
+                               interrupts = <IT_OCP_OTG 0>;
+                               interrupt-parent = <&pmic>;
+                               regulator-active-discharge = <1>;
+                       };
+
+                       vbus_sw: pwr_sw2 {
+                               regulator-name = "vbus_sw";
+                               interrupts = <IT_OCP_SWOUT 0>;
+                               interrupt-parent = <&pmic>;
+                               regulator-active-discharge = <1>;
+                       };
+               };
+
+               onkey {
+                       compatible = "st,stpmic1-onkey";
+                       interrupts = <IT_PONKEY_F 0>, <IT_PONKEY_R 1>;
+                       interrupt-names = "onkey-falling", "onkey-rising";
+                       status = "okay";
+               };
+
+               watchdog {
+                       compatible = "st,stpmic1-wdt";
+                       status = "disabled";
+               };
+       };
+};
+
+&iwdg2 {
+       timeout-sec = <32>;
+       status = "okay";
+};
+
+&pwr_regulators {
+       vdd-supply = <&vdd>;
+       vdd_3v3_usbfs-supply = <&vdd_usb>;
+};
+
+&qspi {
+       pinctrl-names = "default", "sleep";
+       pinctrl-0 = <&qspi_clk_pins_a &qspi_bk1_pins_a>;
+       pinctrl-1 = <&qspi_clk_sleep_pins_a &qspi_bk1_sleep_pins_a>;
+       reg = <0x58003000 0x1000>, <0x70000000 0x200000>;
+       #address-cells = <1>;
+       #size-cells = <0>;
+       status = "okay";
+
+       flash0: spi-flash@0 {
+               compatible = "jedec,spi-nor";
+               reg = <0>;
+               spi-rx-bus-width = <4>;
+               spi-max-frequency = <108000000>;
+               #address-cells = <1>;
+               #size-cells = <1>;
+       };
+};
+
+&rng1 {
+       status = "okay";
+};
+
+&rtc {
+       status = "okay";
+};
diff --git a/arch/arm/dts/stm32mp15xx-dhcor.dtsi b/arch/arm/dts/stm32mp15xx-dhcor.dtsi
deleted file mode 100644 (file)
index 97d370e..0000000
+++ /dev/null
@@ -1,232 +0,0 @@
-// SPDX-License-Identifier: (GPL-2.0 OR BSD-3-Clause)
-/*
- * Copyright (C) Linaro Ltd 2019 - All Rights Reserved
- * Author: Manivannan Sadhasivam <manivannan.sadhasivam@linaro.org>
- * Copyright (C) 2020 Marek Vasut <marex@denx.de>
- */
-/dts-v1/;
-
-#include "stm32mp157.dtsi"
-#include "stm32mp15-pinctrl.dtsi"
-#include "stm32mp15xxac-pinctrl.dtsi"
-#include <dt-bindings/gpio/gpio.h>
-#include <dt-bindings/mfd/st,stpmic1.h>
-
-/ {
-       aliases {
-               spi0 = &qspi;
-       };
-
-       memory@c0000000 {
-               device_type = "memory";
-               reg = <0xc0000000 0x40000000>;
-       };
-
-       /* Enpirion EP3A8LQI U2 on the DHCOR */
-       vdd_io: regulator-buck-io {
-               compatible = "regulator-fixed";
-               regulator-name = "buck-io";
-               regulator-min-microvolt = <1800000>;
-               regulator-max-microvolt = <1800000>;
-               regulator-always-on;
-               regulator-boot-on;
-               vin-supply = <&vdd>;
-       };
-};
-
-&i2c4 {
-       pinctrl-names = "default";
-       pinctrl-0 = <&i2c4_pins_a>;
-       i2c-scl-rising-time-ns = <185>;
-       i2c-scl-falling-time-ns = <20>;
-       status = "okay";
-       /delete-property/dmas;
-       /delete-property/dma-names;
-
-       pmic: stpmic@33 {
-               compatible = "st,stpmic1";
-               reg = <0x33>;
-               interrupts-extended = <&exti 55 IRQ_TYPE_EDGE_FALLING>;
-               interrupt-controller;
-               #interrupt-cells = <2>;
-               status = "okay";
-
-               st,main-control-register = <0x04>;
-               st,vin-control-register = <0xc0>;
-               st,usb-control-register = <0x30>;
-
-               regulators {
-                       compatible = "st,stpmic1-regulators";
-
-                       ldo1-supply = <&v3v3>;
-                       ldo2-supply = <&v3v3>;
-                       ldo3-supply = <&vdd_ddr>;
-                       ldo5-supply = <&v3v3>;
-                       ldo6-supply = <&v3v3>;
-                       pwr_sw1-supply = <&bst_out>;
-                       pwr_sw2-supply = <&bst_out>;
-
-                       vddcore: buck1 {
-                               regulator-name = "vddcore";
-                               regulator-min-microvolt = <800000>;
-                               regulator-max-microvolt = <1350000>;
-                               regulator-always-on;
-                               regulator-initial-mode = <0>;
-                               regulator-over-current-protection;
-                       };
-
-                       vdd_ddr: buck2 {
-                               regulator-name = "vdd_ddr";
-                               regulator-min-microvolt = <1350000>;
-                               regulator-max-microvolt = <1350000>;
-                               regulator-always-on;
-                               regulator-initial-mode = <0>;
-                               regulator-over-current-protection;
-                       };
-
-                       vdd: buck3 {
-                               regulator-name = "vdd";
-                               regulator-min-microvolt = <2900000>;
-                               regulator-max-microvolt = <2900000>;
-                               regulator-always-on;
-                               st,mask_reset;
-                               regulator-initial-mode = <0>;
-                               regulator-over-current-protection;
-                       };
-
-                       v3v3: buck4 {
-                               regulator-name = "v3v3";
-                               regulator-min-microvolt = <3300000>;
-                               regulator-max-microvolt = <3300000>;
-                               regulator-always-on;
-                               regulator-over-current-protection;
-                               regulator-initial-mode = <0>;
-                       };
-
-                       vdda: ldo1 {
-                               regulator-name = "vdda";
-                               regulator-min-microvolt = <2900000>;
-                               regulator-max-microvolt = <2900000>;
-                               interrupts = <IT_CURLIM_LDO1 0>;
-                               interrupt-parent = <&pmic>;
-                       };
-
-                       v2v8: ldo2 {
-                               regulator-name = "v2v8";
-                               regulator-min-microvolt = <2800000>;
-                               regulator-max-microvolt = <2800000>;
-                               interrupts = <IT_CURLIM_LDO2 0>;
-                               interrupt-parent = <&pmic>;
-                       };
-
-                       vtt_ddr: ldo3 {
-                               regulator-name = "vtt_ddr";
-                               regulator-min-microvolt = <500000>;
-                               regulator-max-microvolt = <750000>;
-                               regulator-always-on;
-                               regulator-over-current-protection;
-                       };
-
-                       vdd_usb: ldo4 {
-                               regulator-name = "vdd_usb";
-                               regulator-min-microvolt = <3300000>;
-                               regulator-max-microvolt = <3300000>;
-                               interrupts = <IT_CURLIM_LDO4 0>;
-                               interrupt-parent = <&pmic>;
-                       };
-
-                       vdd_sd: ldo5 {
-                               regulator-name = "vdd_sd";
-                               regulator-min-microvolt = <2900000>;
-                               regulator-max-microvolt = <2900000>;
-                               interrupts = <IT_CURLIM_LDO5 0>;
-                               interrupt-parent = <&pmic>;
-                               regulator-boot-on;
-                       };
-
-                       v1v8: ldo6 {
-                               regulator-name = "v1v8";
-                               regulator-min-microvolt = <1800000>;
-                               regulator-max-microvolt = <1800000>;
-                               interrupts = <IT_CURLIM_LDO6 0>;
-                               interrupt-parent = <&pmic>;
-                               regulator-enable-ramp-delay = <300000>;
-                       };
-
-                       vref_ddr: vref_ddr {
-                               regulator-name = "vref_ddr";
-                               regulator-always-on;
-                               regulator-over-current-protection;
-                       };
-
-                       bst_out: boost {
-                               regulator-name = "bst_out";
-                               interrupts = <IT_OCP_BOOST 0>;
-                               interrupt-parent = <&pmic>;
-                       };
-
-                       vbus_otg: pwr_sw1 {
-                               regulator-name = "vbus_otg";
-                               interrupts = <IT_OCP_OTG 0>;
-                               interrupt-parent = <&pmic>;
-                               regulator-active-discharge = <1>;
-                       };
-
-                       vbus_sw: pwr_sw2 {
-                               regulator-name = "vbus_sw";
-                               interrupts = <IT_OCP_SWOUT 0>;
-                               interrupt-parent = <&pmic>;
-                               regulator-active-discharge = <1>;
-                       };
-               };
-
-               onkey {
-                       compatible = "st,stpmic1-onkey";
-                       interrupts = <IT_PONKEY_F 0>, <IT_PONKEY_R 1>;
-                       interrupt-names = "onkey-falling", "onkey-rising";
-                       status = "okay";
-               };
-
-               watchdog {
-                       compatible = "st,stpmic1-wdt";
-                       status = "disabled";
-               };
-       };
-};
-
-&iwdg2 {
-       timeout-sec = <32>;
-       status = "okay";
-};
-
-&pwr_regulators {
-       vdd-supply = <&vdd_io>;
-       vdd_3v3_usbfs-supply = <&vdd_usb>;
-};
-
-&qspi {
-       pinctrl-names = "default", "sleep";
-       pinctrl-0 = <&qspi_clk_pins_a &qspi_bk1_pins_a>;
-       pinctrl-1 = <&qspi_clk_sleep_pins_a &qspi_bk1_sleep_pins_a>;
-       reg = <0x58003000 0x1000>, <0x70000000 0x200000>;
-       #address-cells = <1>;
-       #size-cells = <0>;
-       status = "okay";
-
-       flash0: spi-flash@0 {
-               compatible = "jedec,spi-nor";
-               reg = <0>;
-               spi-rx-bus-width = <4>;
-               spi-max-frequency = <108000000>;
-               #address-cells = <1>;
-               #size-cells = <1>;
-       };
-};
-
-&rng1 {
-       status = "okay";
-};
-
-&rtc {
-       status = "okay";
-};