* [PATCH v2 1/7] arch: arm: dts: ls1043a: sync serial nodes with Linux
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-16 13:18 ` [PATCH v2 2/7] arch: arm: dts: ls1043a: tag serial nodes with bootph-all Camelia Groza
` (6 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
Pick up the serial node descriptions from Linux v6.3 for the ls1043ardb
board and its dependencies. Including the fsl,qoriq-clockgen.h and
arm-gic.h headers forces us to change the include directives to explicitly
go through the C preprocessor for all boards in the ls1043a SoC family.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
V2:
- mention the Linux kernel version the serial nodes are synced with
arch/arm/dts/fsl-ls1043a-qds.dtsi | 2 +-
arch/arm/dts/fsl-ls1043a-rdb.dts | 6 +++++-
arch/arm/dts/fsl-ls1043a.dtsi | 16 +++++++++++-----
3 files changed, 17 insertions(+), 7 deletions(-)
diff --git a/arch/arm/dts/fsl-ls1043a-qds.dtsi b/arch/arm/dts/fsl-ls1043a-qds.dtsi
index 884bdad196b3..5e02cd91d75f 100644
--- a/arch/arm/dts/fsl-ls1043a-qds.dtsi
+++ b/arch/arm/dts/fsl-ls1043a-qds.dtsi
@@ -7,7 +7,7 @@
* Mingkai Hu <Mingkai.hu@freescale.com>
*/
-/include/ "fsl-ls1043a.dtsi"
+#include "fsl-ls1043a.dtsi"
/ {
model = "LS1043A QDS Board";
diff --git a/arch/arm/dts/fsl-ls1043a-rdb.dts b/arch/arm/dts/fsl-ls1043a-rdb.dts
index 9e7c79fd2b98..f5b3bb68b3db 100644
--- a/arch/arm/dts/fsl-ls1043a-rdb.dts
+++ b/arch/arm/dts/fsl-ls1043a-rdb.dts
@@ -9,13 +9,17 @@
*/
/dts-v1/;
-/include/ "fsl-ls1043a.dtsi"
+#include "fsl-ls1043a.dtsi"
/ {
model = "LS1043A RDB Board";
aliases {
spi1 = &dspi0;
+ serial0 = &duart0;
+ serial1 = &duart1;
+ serial2 = &duart2;
+ serial3 = &duart3;
};
};
diff --git a/arch/arm/dts/fsl-ls1043a.dtsi b/arch/arm/dts/fsl-ls1043a.dtsi
index 4960973a6035..21643a1d951f 100644
--- a/arch/arm/dts/fsl-ls1043a.dtsi
+++ b/arch/arm/dts/fsl-ls1043a.dtsi
@@ -8,7 +8,9 @@
* Mingkai Hu <Mingkai.hu@freescale.com>
*/
-/include/ "skeleton64.dtsi"
+#include "skeleton64.dtsi"
+#include <dt-bindings/clock/fsl,qoriq-clockgen.h>
+#include <dt-bindings/interrupt-controller/arm-gic.h>
/ {
compatible = "fsl,ls1043a";
@@ -223,28 +225,32 @@
compatible = "fsl,ns16550", "ns16550a";
reg = <0x00 0x21c0500 0x0 0x100>;
interrupts = <0 54 0x4>;
- clocks = <&clockgen 4 0>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(1)>;
};
duart1: serial@21c0600 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x00 0x21c0600 0x0 0x100>;
interrupts = <0 54 0x4>;
- clocks = <&clockgen 4 0>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(1)>;
};
duart2: serial@21d0500 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x0 0x21d0500 0x0 0x100>;
interrupts = <0 55 0x4>;
- clocks = <&clockgen 4 0>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(1)>;
};
duart3: serial@21d0600 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x0 0x21d0600 0x0 0x100>;
interrupts = <0 55 0x4>;
- clocks = <&clockgen 4 0>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(1)>;
};
lpuart0: serial@2950000 {
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* [PATCH v2 2/7] arch: arm: dts: ls1043a: tag serial nodes with bootph-all
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
2023-06-16 13:18 ` [PATCH v2 1/7] arch: arm: dts: ls1043a: sync serial nodes with Linux Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-16 13:18 ` [PATCH v2 3/7] configs: ls1043ardb: enable DM_SERIAL Camelia Groza
` (5 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
Make sure the serial driver is initialized before relocation by tagging
the serial nodes with "bootph-all".
In order to keep the serial nodes in sync with their representation in
the Linux dts, add these u-boot specific properties to *-u-boot.dtsi
files.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
V2:
- create *-u-boot.dtsi files to store u-boot specific dts properties
instead of adding them to the main board dts
arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi | 5 +++++
arch/arm/dts/fsl-ls1043a-u-boot.dtsi | 19 +++++++++++++++++++
2 files changed, 24 insertions(+)
create mode 100644 arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi
create mode 100644 arch/arm/dts/fsl-ls1043a-u-boot.dtsi
diff --git a/arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi b/arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi
new file mode 100644
index 000000000000..ef31c79fa062
--- /dev/null
+++ b/arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: GPL-2.0+
+/* Copyright 2023 NXP */
+
+#include "fsl-ls1043a-u-boot.dtsi"
+
diff --git a/arch/arm/dts/fsl-ls1043a-u-boot.dtsi b/arch/arm/dts/fsl-ls1043a-u-boot.dtsi
new file mode 100644
index 000000000000..65a870511c12
--- /dev/null
+++ b/arch/arm/dts/fsl-ls1043a-u-boot.dtsi
@@ -0,0 +1,19 @@
+// SPDX-License-Identifier: GPL-2.0+
+/* Copyright 2023 NXP */
+
+&duart0 {
+ bootph-all;
+};
+
+&duart1 {
+ bootph-all;
+};
+
+&duart2 {
+ bootph-all;
+};
+
+&duart3 {
+ bootph-all;
+};
+
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* [PATCH v2 3/7] configs: ls1043ardb: enable DM_SERIAL
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
2023-06-16 13:18 ` [PATCH v2 1/7] arch: arm: dts: ls1043a: sync serial nodes with Linux Camelia Groza
2023-06-16 13:18 ` [PATCH v2 2/7] arch: arm: dts: ls1043a: tag serial nodes with bootph-all Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-16 13:18 ` [PATCH v2 4/7] arch: arm: dts: ls1046a: sync serial nodes with Linux Camelia Groza
` (4 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
As the serial devices are configured in the device tree, enable
DM_SERIAL in the ls1043ardb defconfigs.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
configs/ls1043ardb_SECURE_BOOT_defconfig | 4 +++-
configs/ls1043ardb_defconfig | 4 +++-
configs/ls1043ardb_nand_SECURE_BOOT_defconfig | 4 +++-
configs/ls1043ardb_nand_defconfig | 3 ++-
configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig | 4 +++-
configs/ls1043ardb_sdcard_defconfig | 3 ++-
configs/ls1043ardb_tfa_SECURE_BOOT_defconfig | 4 +++-
configs/ls1043ardb_tfa_defconfig | 4 +++-
8 files changed, 22 insertions(+), 8 deletions(-)
diff --git a/configs/ls1043ardb_SECURE_BOOT_defconfig b/configs/ls1043ardb_SECURE_BOOT_defconfig
index 069a8dc0c3ce..ea195d7c5041 100644
--- a/configs/ls1043ardb_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_SECURE_BOOT_defconfig
@@ -86,7 +86,9 @@ CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FW_ADDR=0x60940000
CONFIG_SYS_QE_FMAN_FW_IN_NOR=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_defconfig b/configs/ls1043ardb_defconfig
index e796c0a9a2e0..ae8600ffd958 100644
--- a/configs/ls1043ardb_defconfig
+++ b/configs/ls1043ardb_defconfig
@@ -89,7 +89,9 @@ CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FW_ADDR=0x60940000
CONFIG_SYS_QE_FMAN_FW_IN_NOR=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_nand_SECURE_BOOT_defconfig b/configs/ls1043ardb_nand_SECURE_BOOT_defconfig
index f5faa02e5920..d9ff0fd16a58 100644
--- a/configs/ls1043ardb_nand_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_nand_SECURE_BOOT_defconfig
@@ -110,7 +110,9 @@ CONFIG_SYS_FMAN_FW_ADDR=0x900000
CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FMAN_FW_IN_NAND=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_nand_defconfig b/configs/ls1043ardb_nand_defconfig
index b75550b2d3ad..ad118187432e 100644
--- a/configs/ls1043ardb_nand_defconfig
+++ b/configs/ls1043ardb_nand_defconfig
@@ -117,7 +117,8 @@ CONFIG_SYS_FMAN_FW_ADDR=0x900000
CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FMAN_FW_IN_NAND=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_DM_SERIAL=y
+CONFIG_SPL_SYS_NS16550_SERIAL=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig b/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig
index 3e0d16430e04..fe0dd04f1f90 100644
--- a/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_sdcard_SECURE_BOOT_defconfig
@@ -110,7 +110,9 @@ CONFIG_SYS_FMAN_FW_ADDR=0x900000
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FW_ADDR=0x940000
CONFIG_SYS_QE_FMAN_FW_IN_MMC=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_sdcard_defconfig b/configs/ls1043ardb_sdcard_defconfig
index 04e66f1e6ca2..aa5404cbb50e 100644
--- a/configs/ls1043ardb_sdcard_defconfig
+++ b/configs/ls1043ardb_sdcard_defconfig
@@ -115,7 +115,8 @@ CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FW_ADDR=0x940000
CONFIG_SYS_QE_FMAN_FW_IN_MMC=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_DM_SERIAL=y
+CONFIG_SPL_SYS_NS16550_SERIAL=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_tfa_SECURE_BOOT_defconfig b/configs/ls1043ardb_tfa_SECURE_BOOT_defconfig
index cf4623eb631d..480e928936a9 100644
--- a/configs/ls1043ardb_tfa_SECURE_BOOT_defconfig
+++ b/configs/ls1043ardb_tfa_SECURE_BOOT_defconfig
@@ -84,7 +84,9 @@ CONFIG_SYS_FMAN_FW_ADDR=0x900000
CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FW_ADDR=0x940000
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
diff --git a/configs/ls1043ardb_tfa_defconfig b/configs/ls1043ardb_tfa_defconfig
index 15e2916538a1..e25904170858 100644
--- a/configs/ls1043ardb_tfa_defconfig
+++ b/configs/ls1043ardb_tfa_defconfig
@@ -90,7 +90,9 @@ CONFIG_SYS_FMAN_FW_ADDR=0x900000
CONFIG_NVME_PCI=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_SYS_QE_FW_ADDR=0x940000
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_USB=y
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* [PATCH v2 4/7] arch: arm: dts: ls1046a: sync serial nodes with Linux
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
` (2 preceding siblings ...)
2023-06-16 13:18 ` [PATCH v2 3/7] configs: ls1043ardb: enable DM_SERIAL Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-16 13:18 ` [PATCH v2 5/7] arch: arm: dts: ls1046a: tag serial nodes with bootph-all Camelia Groza
` (3 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
Pick up the serial node descriptions from Linux v6.3 for the ls1046ardb
and ls1046afrwy boards and their dependencies. Including the
fsl,qoriq-clockgen.h and arm-gic.h headers forces us to change the include
directives to explicitly go through the C preprocessor for all boards in
the ls1046a SoC family.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
V2:
- mention the Linux kernel version the serial nodes are synced with
- also pick up the status properties of the serial nodes from Linux
arch/arm/dts/fsl-ls1046a-frwy.dts | 22 +++++++++++++++++++++-
arch/arm/dts/fsl-ls1046a-qds.dtsi | 2 +-
arch/arm/dts/fsl-ls1046a-rdb.dts | 14 +++++++++++++-
arch/arm/dts/fsl-ls1046a.dtsi | 28 +++++++++++++++++++---------
4 files changed, 54 insertions(+), 12 deletions(-)
diff --git a/arch/arm/dts/fsl-ls1046a-frwy.dts b/arch/arm/dts/fsl-ls1046a-frwy.dts
index cda05411d881..f3ba2acd6d51 100644
--- a/arch/arm/dts/fsl-ls1046a-frwy.dts
+++ b/arch/arm/dts/fsl-ls1046a-frwy.dts
@@ -7,17 +7,37 @@
*/
/dts-v1/;
-/include/ "fsl-ls1046a.dtsi"
+#include "fsl-ls1046a.dtsi"
/ {
model = "LS1046A FRWY Board";
aliases {
spi0 = &qspi;
+ serial0 = &duart0;
+ serial1 = &duart1;
+ serial2 = &duart2;
+ serial3 = &duart3;
};
};
+&duart0 {
+ status = "okay";
+};
+
+&duart1 {
+ status = "okay";
+};
+
+&duart2 {
+ status = "okay";
+};
+
+&duart3 {
+ status = "okay";
+};
+
&qspi {
status = "okay";
diff --git a/arch/arm/dts/fsl-ls1046a-qds.dtsi b/arch/arm/dts/fsl-ls1046a-qds.dtsi
index fec5c8ddb23a..d66824975c5e 100644
--- a/arch/arm/dts/fsl-ls1046a-qds.dtsi
+++ b/arch/arm/dts/fsl-ls1046a-qds.dtsi
@@ -7,7 +7,7 @@
* Mingkai Hu <Mingkai.hu@nxp.com>
*/
-/include/ "fsl-ls1046a.dtsi"
+#include "fsl-ls1046a.dtsi"
/ {
model = "LS1046A QDS Board";
diff --git a/arch/arm/dts/fsl-ls1046a-rdb.dts b/arch/arm/dts/fsl-ls1046a-rdb.dts
index 464129291c91..66d718905c7d 100644
--- a/arch/arm/dts/fsl-ls1046a-rdb.dts
+++ b/arch/arm/dts/fsl-ls1046a-rdb.dts
@@ -9,17 +9,29 @@
*/
/dts-v1/;
-/include/ "fsl-ls1046a.dtsi"
+#include "fsl-ls1046a.dtsi"
/ {
model = "LS1046A RDB Board";
aliases {
spi0 = &qspi;
+ serial0 = &duart0;
+ serial1 = &duart1;
+ serial2 = &duart2;
+ serial3 = &duart3;
};
};
+&duart0 {
+ status = "okay";
+};
+
+&duart1 {
+ status = "okay";
+};
+
&qspi {
status = "okay";
diff --git a/arch/arm/dts/fsl-ls1046a.dtsi b/arch/arm/dts/fsl-ls1046a.dtsi
index 060dc399c2f6..44ee4c5808da 100644
--- a/arch/arm/dts/fsl-ls1046a.dtsi
+++ b/arch/arm/dts/fsl-ls1046a.dtsi
@@ -8,7 +8,9 @@
* Mingkai Hu <mingkai.hu@nxp.com>
*/
-/include/ "skeleton64.dtsi"
+#include "skeleton64.dtsi"
+#include <dt-bindings/clock/fsl,qoriq-clockgen.h>
+#include <dt-bindings/interrupt-controller/arm-gic.h>
/ {
compatible = "fsl,ls1046a";
@@ -222,29 +224,37 @@
duart0: serial@21c0500 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x00 0x21c0500 0x0 0x100>;
- interrupts = <0 54 0x4>;
- clocks = <&clockgen 4 0>;
+ interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(2)>;
+ status = "disabled";
};
duart1: serial@21c0600 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x00 0x21c0600 0x0 0x100>;
- interrupts = <0 54 0x4>;
- clocks = <&clockgen 4 0>;
+ interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(2)>;
+ status = "disabled";
};
duart2: serial@21d0500 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x0 0x21d0500 0x0 0x100>;
- interrupts = <0 55 0x4>;
- clocks = <&clockgen 4 0>;
+ interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(2)>;
+ status = "disabled";
};
duart3: serial@21d0600 {
compatible = "fsl,ns16550", "ns16550a";
reg = <0x0 0x21d0600 0x0 0x100>;
- interrupts = <0 55 0x4>;
- clocks = <&clockgen 4 0>;
+ interrupts = <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>;
+ clocks = <&clockgen QORIQ_CLK_PLATFORM_PLL
+ QORIQ_CLK_PLL_DIV(2)>;
+ status = "disabled";
};
lpuart0: serial@2950000 {
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* [PATCH v2 5/7] arch: arm: dts: ls1046a: tag serial nodes with bootph-all
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
` (3 preceding siblings ...)
2023-06-16 13:18 ` [PATCH v2 4/7] arch: arm: dts: ls1046a: sync serial nodes with Linux Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-16 13:18 ` [PATCH v2 6/7] configs: ls1046ardb: enable DM_SERIAL Camelia Groza
` (2 subsequent siblings)
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
Make sure the serial driver is initialized before relocation by tagging
the serial nodes with "bootph-all".
In order to keep the serial nodes in sync with their representation in
the Linux dts, add these u-boot specific properties to *-u-boot.dtsi
files.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
V2:
- create *-u-boot.dtsi files to store u-boot specific dts properties
instead of adding them to the main board dts
arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi | 5 +++++
arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi | 5 +++++
arch/arm/dts/fsl-ls1046a-u-boot.dtsi | 19 +++++++++++++++++++
3 files changed, 29 insertions(+)
create mode 100644 arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi
create mode 100644 arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi
create mode 100644 arch/arm/dts/fsl-ls1046a-u-boot.dtsi
diff --git a/arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi b/arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi
new file mode 100644
index 000000000000..ce204e675b36
--- /dev/null
+++ b/arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: GPL-2.0+
+/* Copyright 2023 NXP */
+
+#include "fsl-ls1046a-u-boot.dtsi"
+
diff --git a/arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi b/arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi
new file mode 100644
index 000000000000..ce204e675b36
--- /dev/null
+++ b/arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi
@@ -0,0 +1,5 @@
+// SPDX-License-Identifier: GPL-2.0+
+/* Copyright 2023 NXP */
+
+#include "fsl-ls1046a-u-boot.dtsi"
+
diff --git a/arch/arm/dts/fsl-ls1046a-u-boot.dtsi b/arch/arm/dts/fsl-ls1046a-u-boot.dtsi
new file mode 100644
index 000000000000..65a870511c12
--- /dev/null
+++ b/arch/arm/dts/fsl-ls1046a-u-boot.dtsi
@@ -0,0 +1,19 @@
+// SPDX-License-Identifier: GPL-2.0+
+/* Copyright 2023 NXP */
+
+&duart0 {
+ bootph-all;
+};
+
+&duart1 {
+ bootph-all;
+};
+
+&duart2 {
+ bootph-all;
+};
+
+&duart3 {
+ bootph-all;
+};
+
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* [PATCH v2 6/7] configs: ls1046ardb: enable DM_SERIAL
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
` (4 preceding siblings ...)
2023-06-16 13:18 ` [PATCH v2 5/7] arch: arm: dts: ls1046a: tag serial nodes with bootph-all Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-16 13:18 ` [PATCH v2 7/7] configs: ls1046afrwy: " Camelia Groza
2023-06-26 1:04 ` [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Peng Fan
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
As the serial devices are configured in the device tree, enable
DM_SERIAL in the ls1046ardb defconfigs.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
configs/ls1046ardb_emmc_defconfig | 3 ++-
configs/ls1046ardb_qspi_SECURE_BOOT_defconfig | 4 +++-
configs/ls1046ardb_qspi_defconfig | 4 +++-
configs/ls1046ardb_qspi_spl_defconfig | 3 ++-
configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig | 4 +++-
configs/ls1046ardb_sdcard_defconfig | 3 ++-
configs/ls1046ardb_tfa_SECURE_BOOT_defconfig | 4 +++-
configs/ls1046ardb_tfa_defconfig | 4 +++-
8 files changed, 21 insertions(+), 8 deletions(-)
diff --git a/configs/ls1046ardb_emmc_defconfig b/configs/ls1046ardb_emmc_defconfig
index 7be98df566fc..924ff78b4593 100644
--- a/configs/ls1046ardb_emmc_defconfig
+++ b/configs/ls1046ardb_emmc_defconfig
@@ -111,7 +111,8 @@ CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_SYS_QE_FMAN_FW_IN_MMC=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_DM_SERIAL=y
+CONFIG_SPL_SYS_NS16550_SERIAL=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig b/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig
index 3cefae092f34..bb278845e069 100644
--- a/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig
+++ b/configs/ls1046ardb_qspi_SECURE_BOOT_defconfig
@@ -86,7 +86,9 @@ CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_SYS_QE_FMAN_FW_IN_SPIFLASH=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_qspi_defconfig b/configs/ls1046ardb_qspi_defconfig
index 02979dd2ff01..0fb1a6c281e5 100644
--- a/configs/ls1046ardb_qspi_defconfig
+++ b/configs/ls1046ardb_qspi_defconfig
@@ -90,7 +90,9 @@ CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_SYS_QE_FMAN_FW_IN_SPIFLASH=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_qspi_spl_defconfig b/configs/ls1046ardb_qspi_spl_defconfig
index 8f7d05fab976..eb0184c59276 100644
--- a/configs/ls1046ardb_qspi_spl_defconfig
+++ b/configs/ls1046ardb_qspi_spl_defconfig
@@ -118,7 +118,8 @@ CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_SYS_QE_FMAN_FW_IN_SPIFLASH=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_DM_SERIAL=y
+CONFIG_SPL_SYS_NS16550_SERIAL=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig b/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig
index 900e26be3be0..2813c79f5975 100644
--- a/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig
+++ b/configs/ls1046ardb_sdcard_SECURE_BOOT_defconfig
@@ -109,7 +109,9 @@ CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_SYS_QE_FMAN_FW_IN_MMC=y
CONFIG_SCSI_AHCI_PLAT=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_sdcard_defconfig b/configs/ls1046ardb_sdcard_defconfig
index ded6be50a3f6..a621859aa792 100644
--- a/configs/ls1046ardb_sdcard_defconfig
+++ b/configs/ls1046ardb_sdcard_defconfig
@@ -111,7 +111,8 @@ CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_SYS_QE_FMAN_FW_IN_MMC=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_DM_SERIAL=y
+CONFIG_SPL_SYS_NS16550_SERIAL=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_tfa_SECURE_BOOT_defconfig b/configs/ls1046ardb_tfa_SECURE_BOOT_defconfig
index 3eaa985ec79b..fbcf294eb534 100644
--- a/configs/ls1046ardb_tfa_SECURE_BOOT_defconfig
+++ b/configs/ls1046ardb_tfa_SECURE_BOOT_defconfig
@@ -79,7 +79,9 @@ CONFIG_PCIE_LAYERSCAPE_EP=y
CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046ardb_tfa_defconfig b/configs/ls1046ardb_tfa_defconfig
index 7e8d86d03c4c..24a54230f8ee 100644
--- a/configs/ls1046ardb_tfa_defconfig
+++ b/configs/ls1046ardb_tfa_defconfig
@@ -85,7 +85,9 @@ CONFIG_PCIE_LAYERSCAPE_EP=y
CONFIG_POWER_LEGACY=y
CONFIG_POWER_I2C=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* [PATCH v2 7/7] configs: ls1046afrwy: enable DM_SERIAL
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
` (5 preceding siblings ...)
2023-06-16 13:18 ` [PATCH v2 6/7] configs: ls1046ardb: enable DM_SERIAL Camelia Groza
@ 2023-06-16 13:18 ` Camelia Groza
2023-06-26 1:04 ` [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Peng Fan
7 siblings, 0 replies; 9+ messages in thread
From: Camelia Groza @ 2023-06-16 13:18 UTC (permalink / raw)
To: peng.fan, mingkai.hu, pramod.kumar_1, u-boot; +Cc: Camelia Groza
As the serial devices are configured in the device tree, enable
DM_SERIAL in the ls1046afrwy defconfigs.
Signed-off-by: Camelia Groza <camelia.groza@nxp.com>
---
configs/ls1046afrwy_tfa_SECURE_BOOT_defconfig | 4 +++-
configs/ls1046afrwy_tfa_defconfig | 4 +++-
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/configs/ls1046afrwy_tfa_SECURE_BOOT_defconfig b/configs/ls1046afrwy_tfa_SECURE_BOOT_defconfig
index 8d6a1371acb7..e97092f2c9b7 100644
--- a/configs/ls1046afrwy_tfa_SECURE_BOOT_defconfig
+++ b/configs/ls1046afrwy_tfa_SECURE_BOOT_defconfig
@@ -67,7 +67,9 @@ CONFIG_FMAN_ENET=y
CONFIG_SYS_FMAN_FW_ADDR=0x900000
CONFIG_DM_PCI_COMPAT=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
diff --git a/configs/ls1046afrwy_tfa_defconfig b/configs/ls1046afrwy_tfa_defconfig
index e5d2b556f783..fdf08ad3c63c 100644
--- a/configs/ls1046afrwy_tfa_defconfig
+++ b/configs/ls1046afrwy_tfa_defconfig
@@ -76,7 +76,9 @@ CONFIG_DM_PCI_COMPAT=y
CONFIG_PCIE_LAYERSCAPE_RC=y
CONFIG_PCIE_LAYERSCAPE_EP=y
CONFIG_DM_SCSI=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
CONFIG_SPI=y
CONFIG_DM_SPI=y
CONFIG_FSL_QSPI=y
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread* Re: [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards
2023-06-16 13:18 [PATCH v2 0/7] Enable DM_SERIAL for the LS104xA RDB/FRWY boards Camelia Groza
` (6 preceding siblings ...)
2023-06-16 13:18 ` [PATCH v2 7/7] configs: ls1046afrwy: " Camelia Groza
@ 2023-06-26 1:04 ` Peng Fan
7 siblings, 0 replies; 9+ messages in thread
From: Peng Fan @ 2023-06-26 1:04 UTC (permalink / raw)
To: Camelia Groza, mingkai.hu, pramod.kumar_1, u-boot
On 6/16/2023 9:18 PM, Camelia Groza wrote:
> This series enables DM_SERIAL for ls1043ardb, ls1046ardb and
> ls1046afrwy.
>
> First, the device tree serial nodes are synced with their counterpart
> descriptions in Linux v6.3.
>
> Secondly, the serial nodes are tagged with 'bootph-all' to guarantee
> the drivers are initialized before relocation. New board specific
> *-u-boot.dtsi files are created to store these properties. We do this in
> order to keep serial node descriptions in sync with Linux.
>
> Lastly, CONFIG_DM_SERIAL is enabled in the relevant defconfigs.
For the patchset,
Reviewed-by: Peng Fan <peng.fan@nxp.com>
>
> Changes in v2:
> - mention the Linux kernel version the serial nodes are synced with in
> 1/7 and 4/7
> - create *-u-boot.dtsi files to store u-boot specific dts properties in
> 2/7 and 5/7
> - pick up the status properties of the serial nodes from Linux in 4/7
>
> Camelia Groza (7):
> arch: arm: dts: ls1043a: sync serial nodes with Linux
> arch: arm: dts: ls1043a: tag serial nodes with bootph-all
> configs: ls1043ardb: enable DM_SERIAL
> arch: arm: dts: ls1046a: sync serial nodes with Linux
> arch: arm: dts: ls1046a: tag serial nodes with bootph-all
> configs: ls1046ardb: enable DM_SERIAL
> configs: ls1046afrwy: enable DM_SERIAL
>
> arch/arm/dts/fsl-ls1043a-qds.dtsi | 2 +-
> arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi | 5 ++++
> arch/arm/dts/fsl-ls1043a-rdb.dts | 6 +++-
> arch/arm/dts/fsl-ls1043a-u-boot.dtsi | 19 +++++++++++++
> arch/arm/dts/fsl-ls1043a.dtsi | 16 +++++++----
> arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi | 5 ++++
> arch/arm/dts/fsl-ls1046a-frwy.dts | 22 ++++++++++++++-
> arch/arm/dts/fsl-ls1046a-qds.dtsi | 2 +-
> arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi | 5 ++++
> arch/arm/dts/fsl-ls1046a-rdb.dts | 14 +++++++++-
> arch/arm/dts/fsl-ls1046a-u-boot.dtsi | 19 +++++++++++++
> arch/arm/dts/fsl-ls1046a.dtsi | 28 +++++++++++++------
> configs/ls1043ardb_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1043ardb_defconfig | 4 ++-
> configs/ls1043ardb_nand_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1043ardb_nand_defconfig | 3 +-
> .../ls1043ardb_sdcard_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1043ardb_sdcard_defconfig | 3 +-
> configs/ls1043ardb_tfa_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1043ardb_tfa_defconfig | 4 ++-
> configs/ls1046afrwy_tfa_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1046afrwy_tfa_defconfig | 4 ++-
> configs/ls1046ardb_emmc_defconfig | 3 +-
> configs/ls1046ardb_qspi_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1046ardb_qspi_defconfig | 4 ++-
> configs/ls1046ardb_qspi_spl_defconfig | 3 +-
> .../ls1046ardb_sdcard_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1046ardb_sdcard_defconfig | 3 +-
> configs/ls1046ardb_tfa_SECURE_BOOT_defconfig | 4 ++-
> configs/ls1046ardb_tfa_defconfig | 4 ++-
> 30 files changed, 173 insertions(+), 37 deletions(-)
> create mode 100644 arch/arm/dts/fsl-ls1043a-rdb-u-boot.dtsi
> create mode 100644 arch/arm/dts/fsl-ls1043a-u-boot.dtsi
> create mode 100644 arch/arm/dts/fsl-ls1046a-frwy-u-boot.dtsi
> create mode 100644 arch/arm/dts/fsl-ls1046a-rdb-u-boot.dtsi
> create mode 100644 arch/arm/dts/fsl-ls1046a-u-boot.dtsi
>
> --
> 2.17.1
>
^ permalink raw reply [flat|nested] 9+ messages in thread