All of lore.kernel.org
 help / color / mirror / Atom feed
* [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted
@ 2019-06-12 15:34 Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 2/7] mx6: dts: Move dtbs under SoC level Fabio Estevam
                   ` (5 more replies)
  0 siblings, 6 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

Keep dtb entries sorted to help adding new dtbs
in an organized form.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 arch/arm/dts/Makefile | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 3d31966380..39c5491015 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -551,14 +551,14 @@ dtb-$(CONFIG_MX6QDL) += \
 	imx6dl-icore-mipi.dtb \
 	imx6dl-icore-rqs.dtb \
 	imx6dl-mamoj.dtb \
+	imx6dl-sabreauto.dtb \
+	imx6dl-sabresd.dtb \
 	imx6q-cm-fx6.dtb \
 	imx6q-icore.dtb \
 	imx6q-icore-mipi.dtb \
 	imx6q-icore-rqs.dtb \
 	imx6q-sabreauto.dtb \
 	imx6q-sabresd.dtb \
-	imx6dl-sabreauto.dtb \
-	imx6dl-sabresd.dtb \
 	imx6qp-sabreauto.dtb \
 	imx6qp-sabresd.dtb
 
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 2/7] mx6: dts: Move dtbs under SoC level
  2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
@ 2019-06-12 15:34 ` Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 3/7] wandboard: Sync with devicetree files from kernel 5.1.9 Fabio Estevam
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

Place dtbs under SoC level rather than board level.

imx6q-novena.dtb and imx6dl-wandboard-revb1.dtb were
placed under the board config option, so move them
to SoC level.

This also aligns with the kernel dts Makefile format.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 arch/arm/dts/Makefile | 8 ++------
 1 file changed, 2 insertions(+), 6 deletions(-)

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 39c5491015..0fa82f5f2e 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -541,9 +541,7 @@ dtb-$(CONFIG_MX6Q) += \
 	imx6-apalis.dtb \
 	imx6q-display5.dtb \
 	imx6q-logicpd.dtb \
-	imx6q-novena.dtb
-
-dtb-$(CONFIG_TARGET_TBS2910) += \
+	imx6q-novena.dtb \
 	imx6q-tbs2910.dtb
 
 dtb-$(CONFIG_MX6QDL) += \
@@ -553,6 +551,7 @@ dtb-$(CONFIG_MX6QDL) += \
 	imx6dl-mamoj.dtb \
 	imx6dl-sabreauto.dtb \
 	imx6dl-sabresd.dtb \
+	imx6dl-wandboard-revb1.dtb \
 	imx6q-cm-fx6.dtb \
 	imx6q-icore.dtb \
 	imx6q-icore-mipi.dtb \
@@ -562,9 +561,6 @@ dtb-$(CONFIG_MX6QDL) += \
 	imx6qp-sabreauto.dtb \
 	imx6qp-sabresd.dtb
 
-dtb-$(CONFIG_TARGET_WANDBOARD) += \
-	imx6dl-wandboard-revb1.dtb
-
 dtb-$(CONFIG_MX6SL) += imx6sl-evk.dtb
 
 dtb-$(CONFIG_MX6SLL) += imx6sll-evk.dtb
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 3/7] wandboard: Sync with devicetree files from kernel 5.1.9
  2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 2/7] mx6: dts: Move dtbs under SoC level Fabio Estevam
@ 2019-06-12 15:34 ` Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 4/7] wandboard: Import extra wandboard devicetree files Fabio Estevam
                   ` (3 subsequent siblings)
  5 siblings, 0 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

Udate the wandboard devicetree files with the ones
from kernel 5.1.9.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 arch/arm/dts/imx6dl-wandboard-revb1.dts   |   1 +
 arch/arm/dts/imx6qdl-wandboard-revb1.dtsi |  15 +--
 arch/arm/dts/imx6qdl-wandboard.dtsi       | 107 +---------------------
 3 files changed, 11 insertions(+), 112 deletions(-)

diff --git a/arch/arm/dts/imx6dl-wandboard-revb1.dts b/arch/arm/dts/imx6dl-wandboard-revb1.dts
index 738db4fc77..c2946fbaa0 100644
--- a/arch/arm/dts/imx6dl-wandboard-revb1.dts
+++ b/arch/arm/dts/imx6dl-wandboard-revb1.dts
@@ -13,6 +13,7 @@
 	compatible = "wand,imx6dl-wandboard", "fsl,imx6dl";
 
 	memory at 10000000 {
+		device_type = "memory";
 		reg = <0x10000000 0x40000000>;
 	};
 };
diff --git a/arch/arm/dts/imx6qdl-wandboard-revb1.dtsi b/arch/arm/dts/imx6qdl-wandboard-revb1.dtsi
index 855dc6f9df..e781a45785 100644
--- a/arch/arm/dts/imx6qdl-wandboard-revb1.dtsi
+++ b/arch/arm/dts/imx6qdl-wandboard-revb1.dtsi
@@ -1,13 +1,8 @@
-/*
- * Copyright 2013 Freescale Semiconductor, Inc.
- *
- * Author: Fabio Estevam <fabio.estevam@freescale.com>
- *
- * This program is free software; you can redistribute it and/or modify
- * it under the terms of the GNU General Public License version 2 as
- * published by the Free Software Foundation.
- *
- */
+// SPDX-License-Identifier: GPL-2.0
+//
+// Copyright 2013 Freescale Semiconductor, Inc.
+//
+// Author: Fabio Estevam <fabio.estevam@freescale.com>
 
 #include "imx6qdl-wandboard.dtsi"
 
diff --git a/arch/arm/dts/imx6qdl-wandboard.dtsi b/arch/arm/dts/imx6qdl-wandboard.dtsi
index 4d03d49fde..50d9a989e0 100644
--- a/arch/arm/dts/imx6qdl-wandboard.dtsi
+++ b/arch/arm/dts/imx6qdl-wandboard.dtsi
@@ -8,6 +8,10 @@
 #include <dt-bindings/gpio/gpio.h>
 
 / {
+	chosen {
+		stdout-path = &uart1;
+	};
+
 	sound {
 		compatible = "fsl,imx6-wandboard-sgtl5000",
 			     "fsl,imx-audio-sgtl5000";
@@ -90,107 +94,6 @@
 		VDDIO-supply = <&reg_3p3v>;
 		lrclk-strength = <3>;
 	};
-
-	pmic: pfuze100 at 8 {
-		compatible = "fsl,pfuze100";
-		reg = <0x08>;
-
-		regulators {
-			sw1a_reg: sw1ab {
-				regulator-min-microvolt = <300000>;
-				regulator-max-microvolt = <1875000>;
-				regulator-boot-on;
-				regulator-always-on;
-				regulator-ramp-delay = <6250>;
-			};
-
-			sw1c_reg: sw1c {
-				regulator-min-microvolt = <300000>;
-				regulator-max-microvolt = <1875000>;
-				regulator-boot-on;
-				regulator-always-on;
-				regulator-ramp-delay = <6250>;
-			};
-
-			sw2_reg: sw2 {
-				regulator-min-microvolt = <800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-boot-on;
-				regulator-always-on;
-				regulator-ramp-delay = <6250>;
-			};
-
-			sw3a_reg: sw3a {
-				regulator-min-microvolt = <400000>;
-				regulator-max-microvolt = <1975000>;
-				regulator-boot-on;
-				regulator-always-on;
-			};
-
-			sw3b_reg: sw3b {
-				regulator-min-microvolt = <400000>;
-				regulator-max-microvolt = <1975000>;
-				regulator-boot-on;
-				regulator-always-on;
-			};
-
-			sw4_reg: sw4 {
-				regulator-min-microvolt = <800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-always-on;
-			};
-
-			swbst_reg: swbst {
-				regulator-min-microvolt = <5000000>;
-				regulator-max-microvolt = <5150000>;
-			};
-
-			snvs_reg: vsnvs {
-				regulator-min-microvolt = <1000000>;
-				regulator-max-microvolt = <3000000>;
-				regulator-boot-on;
-				regulator-always-on;
-			};
-
-			vref_reg: vrefddr {
-				regulator-boot-on;
-				regulator-always-on;
-			};
-
-			vgen1_reg: vgen1 {
-				regulator-min-microvolt = <800000>;
-				regulator-max-microvolt = <1550000>;
-			};
-
-			vgen2_reg: vgen2 {
-				regulator-min-microvolt = <800000>;
-				regulator-max-microvolt = <1550000>;
-			};
-
-			vgen3_reg: vgen3 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-			};
-
-			vgen4_reg: vgen4 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-always-on;
-			};
-
-			vgen5_reg: vgen5 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-always-on;
-			};
-
-			vgen6_reg: vgen6 {
-				regulator-min-microvolt = <1800000>;
-				regulator-max-microvolt = <3300000>;
-				regulator-always-on;
-			};
-		};
-	};
 };
 
 &iomuxc {
@@ -321,7 +224,7 @@
 &fec {
 	pinctrl-names = "default";
 	pinctrl-0 = <&pinctrl_enet>;
-	phy-mode = "rgmii";
+	phy-mode = "rgmii-id";
 	phy-reset-gpios = <&gpio3 29 GPIO_ACTIVE_LOW>;
 	interrupts-extended = <&gpio1 6 IRQ_TYPE_LEVEL_HIGH>,
 			      <&intc 0 119 IRQ_TYPE_LEVEL_HIGH>;
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 4/7] wandboard: Import extra wandboard devicetree files
  2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 2/7] mx6: dts: Move dtbs under SoC level Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 3/7] wandboard: Sync with devicetree files from kernel 5.1.9 Fabio Estevam
@ 2019-06-12 15:34 ` Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias Fabio Estevam
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

Import wandboard devicetree files so that the mx6q and mx6qp
variants can be properly supported.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 arch/arm/dts/imx6q-wandboard-revb1.dts    |  23 +++
 arch/arm/dts/imx6qdl-wandboard-revd1.dtsi | 195 ++++++++++++++++++++++
 arch/arm/dts/imx6qp-wandboard-revd1.dts   |  23 +++
 3 files changed, 241 insertions(+)
 create mode 100644 arch/arm/dts/imx6q-wandboard-revb1.dts
 create mode 100644 arch/arm/dts/imx6qdl-wandboard-revd1.dtsi
 create mode 100644 arch/arm/dts/imx6qp-wandboard-revd1.dts

diff --git a/arch/arm/dts/imx6q-wandboard-revb1.dts b/arch/arm/dts/imx6q-wandboard-revb1.dts
new file mode 100644
index 0000000000..f6ccbecff9
--- /dev/null
+++ b/arch/arm/dts/imx6q-wandboard-revb1.dts
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright 2013 Freescale Semiconductor, Inc.
+ *
+ * Author: Fabio Estevam <fabio.estevam@freescale.com>
+ */
+/dts-v1/;
+#include "imx6q.dtsi"
+#include "imx6qdl-wandboard-revb1.dtsi"
+
+/ {
+	model = "Wandboard i.MX6 Quad Board rev B1";
+	compatible = "wand,imx6q-wandboard", "fsl,imx6q";
+
+	memory at 10000000 {
+		device_type = "memory";
+		reg = <0x10000000 0x80000000>;
+	};
+};
+
+&sata {
+	status = "okay";
+};
diff --git a/arch/arm/dts/imx6qdl-wandboard-revd1.dtsi b/arch/arm/dts/imx6qdl-wandboard-revd1.dtsi
new file mode 100644
index 0000000000..9390979688
--- /dev/null
+++ b/arch/arm/dts/imx6qdl-wandboard-revd1.dtsi
@@ -0,0 +1,195 @@
+// SPDX-License-Identifier: GPL-2.0
+//
+// Copyright 2013 Freescale Semiconductor, Inc.
+//
+// Author: Fabio Estevam <fabio.estevam@freescale.com>
+
+#include "imx6qdl-wandboard.dtsi"
+
+/ {
+	reg_eth_phy: regulator-eth-phy {
+		compatible = "regulator-fixed";
+		regulator-name = "ETH_PHY";
+		regulator-min-microvolt = <3300000>;
+		regulator-max-microvolt = <3300000>;
+		gpio = <&gpio7 13 GPIO_ACTIVE_LOW>;
+	};
+};
+
+&hdmi {
+	ddc-i2c-bus = <&i2c2>;
+	status = "okay";
+};
+
+&i2c3 {
+	clock-frequency = <100000>;
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_i2c3>;
+	status = "okay";
+
+	pmic: pfuze100 at 8 {
+		compatible = "fsl,pfuze100";
+		reg = <0x08>;
+
+		regulators {
+			sw1a_reg: sw1ab {
+				regulator-min-microvolt = <300000>;
+				regulator-max-microvolt = <1875000>;
+				regulator-boot-on;
+				regulator-always-on;
+				regulator-ramp-delay = <6250>;
+			};
+
+			sw1c_reg: sw1c {
+				regulator-min-microvolt = <300000>;
+				regulator-max-microvolt = <1875000>;
+				regulator-boot-on;
+				regulator-always-on;
+				regulator-ramp-delay = <6250>;
+			};
+
+			sw2_reg: sw2 {
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-boot-on;
+				regulator-always-on;
+				regulator-ramp-delay = <6250>;
+			};
+
+			sw3a_reg: sw3a {
+				regulator-min-microvolt = <400000>;
+				regulator-max-microvolt = <1975000>;
+				regulator-boot-on;
+				regulator-always-on;
+			};
+
+			sw3b_reg: sw3b {
+				regulator-min-microvolt = <400000>;
+				regulator-max-microvolt = <1975000>;
+				regulator-boot-on;
+				regulator-always-on;
+			};
+
+			sw4_reg: sw4 {
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <3300000>;
+			};
+
+			swbst_reg: swbst {
+				regulator-min-microvolt = <5000000>;
+				regulator-max-microvolt = <5150000>;
+			};
+
+			snvs_reg: vsnvs {
+				regulator-min-microvolt = <1000000>;
+				regulator-max-microvolt = <3000000>;
+				regulator-boot-on;
+				regulator-always-on;
+			};
+
+			vref_reg: vrefddr {
+				regulator-boot-on;
+				regulator-always-on;
+			};
+
+			vgen1_reg: vgen1 {
+				regulator-min-microvolt = <800000>;
+				regulator-max-microvolt = <1550000>;
+			};
+
+			vgen2_reg: vgen2 {
+				regulator-min-microvolt = <1500000>;
+				regulator-max-microvolt = <1500000>;
+				regulator-boot-on;
+				regulator-always-on;
+			};
+
+			vgen3_reg: vgen3 {
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			vgen4_reg: vgen4 {
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			vgen5_reg: vgen5 {
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+
+			vgen6_reg: vgen6 {
+				regulator-min-microvolt = <1800000>;
+				regulator-max-microvolt = <3300000>;
+				regulator-always-on;
+			};
+		};
+	};
+};
+
+&fec {
+	phy-supply = <&reg_eth_phy>;
+	status = "okay";
+};
+
+&iomuxc {
+	pinctrl-0 = <&pinctrl_hog>;
+
+	imx6qdl-wandboard {
+		pinctrl_hog: hoggrp {
+			fsl,pins = <
+				MX6QDL_PAD_EIM_D22__USB_OTG_PWR		0x80000000	/* USB Power Enable */
+				MX6QDL_PAD_GPIO_2__GPIO1_IO02		0x80000000	/* USDHC1 CD */
+				MX6QDL_PAD_EIM_DA9__GPIO3_IO09		0x80000000	/* uSDHC3 CD */
+				MX6QDL_PAD_EIM_D29__GPIO3_IO29   	0x1f0b1		/* RGMII PHY reset */
+			>;
+		};
+
+		pinctrl_enet: enetgrp {
+			fsl,pins = <
+				MX6QDL_PAD_ENET_MDIO__ENET_MDIO		0x1b0b0
+				MX6QDL_PAD_ENET_MDC__ENET_MDC		0x1b0b0
+				MX6QDL_PAD_RGMII_TXC__RGMII_TXC		0x1b030
+				MX6QDL_PAD_RGMII_TD0__RGMII_TD0		0x1b030
+				MX6QDL_PAD_RGMII_TD1__RGMII_TD1		0x1b030
+				MX6QDL_PAD_RGMII_TD2__RGMII_TD2		0x1b030
+				MX6QDL_PAD_RGMII_TD3__RGMII_TD3		0x1b030
+				MX6QDL_PAD_RGMII_TX_CTL__RGMII_TX_CTL	0x1b030
+				MX6QDL_PAD_ENET_REF_CLK__ENET_TX_CLK	0x1b0b0
+				MX6QDL_PAD_RGMII_RXC__RGMII_RXC		0x1b030
+				MX6QDL_PAD_RGMII_RD0__RGMII_RD0		0x1b030
+				MX6QDL_PAD_RGMII_RD1__RGMII_RD1		0x1b030
+				MX6QDL_PAD_RGMII_RD2__RGMII_RD2		0x1b030
+				MX6QDL_PAD_RGMII_RD3__RGMII_RD3		0x1b030
+				MX6QDL_PAD_RGMII_RX_CTL__RGMII_RX_CTL	0x1b030
+				MX6QDL_PAD_GPIO_6__ENET_IRQ		0x000b1
+			>;
+		};
+
+		pinctrl_i2c3: i2c3grp {
+			fsl,pins = <
+				MX6QDL_PAD_GPIO_5__I2C3_SCL		0x4001b8b1
+				MX6QDL_PAD_GPIO_16__I2C3_SDA		0x4001b8b1
+			>;
+		};
+
+		pinctrl_spdif: spdifgrp {
+			fsl,pins = <
+				MX6QDL_PAD_GPIO_19__SPDIF_OUT		0x1b0b0
+			>;
+		};
+	};
+};
+
+&usdhc2 {
+	pinctrl-names = "default";
+	pinctrl-0 = <&pinctrl_usdhc2>;
+	bus-width = <4>;
+	no-1-8-v;
+	non-removable;
+	status = "okay";
+};
diff --git a/arch/arm/dts/imx6qp-wandboard-revd1.dts b/arch/arm/dts/imx6qp-wandboard-revd1.dts
new file mode 100644
index 0000000000..08d8b78a20
--- /dev/null
+++ b/arch/arm/dts/imx6qp-wandboard-revd1.dts
@@ -0,0 +1,23 @@
+// SPDX-License-Identifier: GPL-2.0
+/*
+ * Copyright 2013 Freescale Semiconductor, Inc.
+ *
+ * Author: Fabio Estevam <fabio.estevam@freescale.com>
+ */
+/dts-v1/;
+#include "imx6qp.dtsi"
+#include "imx6qdl-wandboard-revd1.dtsi"
+
+/ {
+	model = "Wandboard i.MX6 QuadPlus Board revD1";
+	compatible = "wand,imx6qp-wandboard", "fsl,imx6qp";
+
+	memory at 10000000 {
+		device_type = "memory";
+		reg = <0x10000000 0x80000000>;
+	};
+};
+
+&sata {
+	status = "okay";
+};
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias
  2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
                   ` (2 preceding siblings ...)
  2019-06-12 15:34 ` [U-Boot] [PATCH 4/7] wandboard: Import extra wandboard devicetree files Fabio Estevam
@ 2019-06-12 15:34 ` Fabio Estevam
  2019-06-12 15:42   ` Peter Robinson
  2019-06-12 15:34 ` [U-Boot] [PATCH 6/7] wandboard: Add FIT image support Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name Fabio Estevam
  5 siblings, 1 reply; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

Add a mmc0 alias so that U-Boot proper can associate mmc0
with the boot SD card.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 arch/arm/dts/imx6qdl-wandboard.dtsi | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/arch/arm/dts/imx6qdl-wandboard.dtsi b/arch/arm/dts/imx6qdl-wandboard.dtsi
index 50d9a989e0..90aa43d21b 100644
--- a/arch/arm/dts/imx6qdl-wandboard.dtsi
+++ b/arch/arm/dts/imx6qdl-wandboard.dtsi
@@ -8,6 +8,10 @@
 #include <dt-bindings/gpio/gpio.h>
 
 / {
+	aliases {
+		mmc0 = &usdhc3;
+	};
+
 	chosen {
 		stdout-path = &uart1;
 	};
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 6/7] wandboard: Add FIT image support
  2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
                   ` (3 preceding siblings ...)
  2019-06-12 15:34 ` [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias Fabio Estevam
@ 2019-06-12 15:34 ` Fabio Estevam
  2019-06-12 15:34 ` [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name Fabio Estevam
  5 siblings, 0 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

After the transition to DM, only the mx6dl/solo wandboard
is supported.

Add FIT image support so that all the wandboard variants
can be supported, like it was prior to the DM conversion.

Successfully booted Linux on mx6q/solo/qp wandboards.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 arch/arm/dts/Makefile       |  4 +++-
 board/wandboard/wandboard.c | 18 ++++++++++++++++++
 configs/wandboard_defconfig |  7 +++++++
 3 files changed, 28 insertions(+), 1 deletion(-)

diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile
index 0fa82f5f2e..3b8b4f430c 100644
--- a/arch/arm/dts/Makefile
+++ b/arch/arm/dts/Makefile
@@ -558,8 +558,10 @@ dtb-$(CONFIG_MX6QDL) += \
 	imx6q-icore-rqs.dtb \
 	imx6q-sabreauto.dtb \
 	imx6q-sabresd.dtb \
+	imx6q-wandboard-revb1.dtb \
 	imx6qp-sabreauto.dtb \
-	imx6qp-sabresd.dtb
+	imx6qp-sabresd.dtb \
+	imx6qp-wandboard-revd1.dtb
 
 dtb-$(CONFIG_MX6SL) += imx6sl-evk.dtb
 
diff --git a/board/wandboard/wandboard.c b/board/wandboard/wandboard.c
index 9d7a94ff9d..74d7a17028 100644
--- a/board/wandboard/wandboard.c
+++ b/board/wandboard/wandboard.c
@@ -500,3 +500,21 @@ int checkboard(void)
 
 	return 0;
 }
+
+#ifdef CONFIG_SPL_LOAD_FIT
+int board_fit_config_name_match(const char *name)
+{
+	if (is_mx6dq()) {
+		if (!strcmp(name, "imx6q-wandboard-revb1"))
+			return 0;
+	} else if (is_mx6dqp()) {
+		if (!strcmp(name, "imx6qp-wandboard-revd1"))
+			return 0;
+	} else if (is_mx6dl() || is_mx6solo()) {
+		if (!strcmp(name, "imx6dl-wandboard-revb1"))
+			return 0;
+	}
+
+	return -EINVAL;
+}
+#endif
diff --git a/configs/wandboard_defconfig b/configs/wandboard_defconfig
index ee81e1aa1c..f1d6cc56b0 100644
--- a/configs/wandboard_defconfig
+++ b/configs/wandboard_defconfig
@@ -13,6 +13,9 @@ CONFIG_SPL_LIBDISK_SUPPORT=y
 CONFIG_CMD_HDMIDETECT=y
 CONFIG_AHCI=y
 CONFIG_DISTRO_DEFAULTS=y
+CONFIG_FIT=y
+CONFIG_SPL_FIT_PRINT=y
+CONFIG_SPL_LOAD_FIT=y
 CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/mach-imx/spl_sd.cfg"
 CONFIG_BOOTCOMMAND="run findfdt; run finduuid; run distro_bootcmd"
 # CONFIG_CONSOLE_MUX is not set
@@ -23,6 +26,8 @@ CONFIG_DISPLAY_BOARDINFO_LATE=y
 CONFIG_BOUNCE_BUFFER=y
 CONFIG_BOARD_EARLY_INIT_F=y
 CONFIG_SPL_TEXT_BASE=0x00908000
+CONFIG_SPL_SEPARATE_BSS=y
+CONFIG_SPL_FIT_IMAGE_TINY=y
 CONFIG_SPL_FS_EXT4=y
 CONFIG_SPL_I2C_SUPPORT=y
 CONFIG_SPL_WATCHDOG_SUPPORT=y
@@ -36,6 +41,8 @@ CONFIG_CMD_CACHE=y
 CONFIG_CMD_EXT4_WRITE=y
 CONFIG_OF_CONTROL=y
 CONFIG_DEFAULT_DEVICE_TREE="imx6dl-wandboard-revb1"
+CONFIG_OF_LIST="imx6q-wandboard-revb1 imx6qp-wandboard-revd1 imx6dl-wandboard-revb1"
+CONFIG_MULTI_DTB_FIT=y
 CONFIG_ENV_IS_IN_MMC=y
 CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
 CONFIG_DM=y
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name
  2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
                   ` (4 preceding siblings ...)
  2019-06-12 15:34 ` [U-Boot] [PATCH 6/7] wandboard: Add FIT image support Fabio Estevam
@ 2019-06-12 15:34 ` Fabio Estevam
  2019-06-23 14:04   ` Heinrich Schuchardt
  5 siblings, 1 reply; 11+ messages in thread
From: Fabio Estevam @ 2019-06-12 15:34 UTC (permalink / raw)
  To: u-boot

After the conversion to DM the U-Boot proper binary name
is 'u-boot-dtb.img', so adjust it accordingly.

Signed-off-by: Fabio Estevam <festevam@gmail.com>
---
 board/wandboard/README | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/board/wandboard/README b/board/wandboard/README
index e5170bcc81..f84f205337 100644
--- a/board/wandboard/README
+++ b/board/wandboard/README
@@ -29,7 +29,7 @@ $ sudo dd if=SPL of=/dev/mmcblk0 bs=1k seek=1; sync
 
 - Flash the u-boot.img image into the SD card:
 
-sudo dd if=u-boot.img of=/dev/mmcblk0 bs=1k seek=69; sync
+sudo dd if=u-boot-dtb.img of=/dev/mmcblk0 bs=1k seek=69; sync
 
 - Insert the SD card into the slot located in the bottom of the board (same side
 as the mx6 processor)
-- 
2.17.1

^ permalink raw reply related	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias
  2019-06-12 15:34 ` [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias Fabio Estevam
@ 2019-06-12 15:42   ` Peter Robinson
  2019-06-14 12:31     ` Fabio Estevam
  0 siblings, 1 reply; 11+ messages in thread
From: Peter Robinson @ 2019-06-12 15:42 UTC (permalink / raw)
  To: u-boot

On Wed, Jun 12, 2019 at 4:38 PM Fabio Estevam <festevam@gmail.com> wrote:
>
> Add a mmc0 alias so that U-Boot proper can associate mmc0
> with the boot SD card.

Shouldn't this go in a -u-boot.dtsi if it's diverging from the linux dtsi?

> Signed-off-by: Fabio Estevam <festevam@gmail.com>
> ---
>  arch/arm/dts/imx6qdl-wandboard.dtsi | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/arch/arm/dts/imx6qdl-wandboard.dtsi b/arch/arm/dts/imx6qdl-wandboard.dtsi
> index 50d9a989e0..90aa43d21b 100644
> --- a/arch/arm/dts/imx6qdl-wandboard.dtsi
> +++ b/arch/arm/dts/imx6qdl-wandboard.dtsi
> @@ -8,6 +8,10 @@
>  #include <dt-bindings/gpio/gpio.h>
>
>  / {
> +       aliases {
> +               mmc0 = &usdhc3;
> +       };
> +
>         chosen {
>                 stdout-path = &uart1;
>         };
> --
> 2.17.1
>
> _______________________________________________
> U-Boot mailing list
> U-Boot at lists.denx.de
> https://lists.denx.de/listinfo/u-boot

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias
  2019-06-12 15:42   ` Peter Robinson
@ 2019-06-14 12:31     ` Fabio Estevam
  0 siblings, 0 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-14 12:31 UTC (permalink / raw)
  To: u-boot

Hi Peter,

On Wed, Jun 12, 2019 at 12:42 PM Peter Robinson <pbrobinson@gmail.com> wrote:
>
> On Wed, Jun 12, 2019 at 4:38 PM Fabio Estevam <festevam@gmail.com> wrote:
> >
> > Add a mmc0 alias so that U-Boot proper can associate mmc0
> > with the boot SD card.
>
> Shouldn't this go in a -u-boot.dtsi if it's diverging from the linux dtsi?

I have also originally thought about doing this, but then decided to
put it in the main dtsi as I plan to submit a patch adding the mmc
alias for the upstream dtsi in the kernel.

Thanks for the feedback.

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name
  2019-06-12 15:34 ` [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name Fabio Estevam
@ 2019-06-23 14:04   ` Heinrich Schuchardt
  2019-06-24 19:21     ` Fabio Estevam
  0 siblings, 1 reply; 11+ messages in thread
From: Heinrich Schuchardt @ 2019-06-23 14:04 UTC (permalink / raw)
  To: u-boot

On 6/12/19 5:34 PM, Fabio Estevam wrote:
> After the conversion to DM the U-Boot proper binary name
> is 'u-boot-dtb.img', so adjust it accordingly.
>
> Signed-off-by: Fabio Estevam <festevam@gmail.com>
> ---
>   board/wandboard/README | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/board/wandboard/README b/board/wandboard/README
> index e5170bcc81..f84f205337 100644
> --- a/board/wandboard/README
> +++ b/board/wandboard/README > @@ -29,7 +29,7 @@ $ sudo dd if=SPL of=/dev/mmcblk0 bs=1k seek=1; sync
>
>   - Flash the u-boot.img image into the SD card:
>
> -sudo dd if=u-boot.img of=/dev/mmcblk0 bs=1k seek=69; sync
> +sudo dd if=u-boot-dtb.img of=/dev/mmcblk0 bs=1k seek=69; sync

With U-Boot HEAD I cannot see any difference between the files:
$ md5sum u-boot*.bin
56a64c916b79c012759ad430a52fb2c1  u-boot.bin
56a64c916b79c012759ad430a52fb2c1  u-boot-dtb.bin
ed69f924f0cb4b9415d0bed27f896be3  u-boot-nodtb.bin

So is this just a formal change?

Best regards

Heinrich

>
>   - Insert the SD card into the slot located in the bottom of the board (same side
>   as the mx6 processor)
>

^ permalink raw reply	[flat|nested] 11+ messages in thread

* [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name
  2019-06-23 14:04   ` Heinrich Schuchardt
@ 2019-06-24 19:21     ` Fabio Estevam
  0 siblings, 0 replies; 11+ messages in thread
From: Fabio Estevam @ 2019-06-24 19:21 UTC (permalink / raw)
  To: u-boot

Hi Heinrich,

On Sun, Jun 23, 2019 at 11:04 AM Heinrich Schuchardt <xypron.glpk@gmx.de> wrote:

> With U-Boot HEAD I cannot see any difference between the files:
> $ md5sum u-boot*.bin
> 56a64c916b79c012759ad430a52fb2c1  u-boot.bin
> 56a64c916b79c012759ad430a52fb2c1  u-boot-dtb.bin
> ed69f924f0cb4b9415d0bed27f896be3  u-boot-nodtb.bin

Actually we are talking about .img in this patch :-)

You are right: u-boot.img and u-boot-dtb.img are the same.

> So is this just a formal change?

Yes, just to point out that the board has been converted to DM and
since *dtb.img has been generated, we can explicitly use it.

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2019-06-24 19:21 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-06-12 15:34 [U-Boot] [PATCH 1/7] mx6: dts: Keep dtb entries sorted Fabio Estevam
2019-06-12 15:34 ` [U-Boot] [PATCH 2/7] mx6: dts: Move dtbs under SoC level Fabio Estevam
2019-06-12 15:34 ` [U-Boot] [PATCH 3/7] wandboard: Sync with devicetree files from kernel 5.1.9 Fabio Estevam
2019-06-12 15:34 ` [U-Boot] [PATCH 4/7] wandboard: Import extra wandboard devicetree files Fabio Estevam
2019-06-12 15:34 ` [U-Boot] [PATCH 5/7] wandboard: Add mmc0 alias Fabio Estevam
2019-06-12 15:42   ` Peter Robinson
2019-06-14 12:31     ` Fabio Estevam
2019-06-12 15:34 ` [U-Boot] [PATCH 6/7] wandboard: Add FIT image support Fabio Estevam
2019-06-12 15:34 ` [U-Boot] [PATCH 7/7] wandboard: README: Adjust the U-Boot proper binary name Fabio Estevam
2019-06-23 14:04   ` Heinrich Schuchardt
2019-06-24 19:21     ` Fabio Estevam

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.