]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
mpc8379erdb: Convert to using DM_SERIAL
authorSinan Akman <sinan@writeme.com>
Fri, 7 Apr 2023 22:03:44 +0000 (18:03 -0400)
committerTom Rini <trini@konsulko.com>
Tue, 25 Apr 2023 19:31:28 +0000 (15:31 -0400)
  Convert to DM_SERIAL for mpc8379erdb.

Signed-off-by: Sinan Akman <sinan@writeme.com>
arch/powerpc/dts/mpc8379erdb.dts
configs/MPC837XERDB_defconfig
include/configs/MPC837XERDB.h

index 2e7c8f103c33b8c7faba01560611d5489f242f7f..3db5ececaecf5be95820b1999421187eef7c4502 100644 (file)
        #address-cells = <1>;
        #size-cells = <1>;
 
+       aliases {
+               serial0 = &serial0;
+               serial1 = &serial1;
+       };
+
        cpus {
                #address-cells = <1>;
                #size-cells = <0>;
                        clock-frequency = <0>;
                };
 
+               serial0: serial@4500 {
+                       cell-index = <0>;
+                       device_type = "serial";
+                       compatible = "fsl,ns16550", "ns16550";
+                       reg = <0x4500 0x100>;
+                       clock-frequency = <333333000>;
+                       interrupts = <9 0x8>;
+                       interrupt-parent = <&ipic>;
+                       bootph-all;
+               };
+
+               serial1: serial@4600 {
+                       cell-index = <1>;
+                       device_type = "serial";
+                       compatible = "fsl,ns16550", "ns16550";
+                       reg = <0x4600 0x100>;
+                       clock-frequency = <333333000>;
+                       interrupts = <10 0x8>;
+                       interrupt-parent = <&ipic>;
+                       bootph-all;
+               };
+
                ipic: interrupt-controller@700 {
                        compatible = "fsl,ipic";
                        interrupt-controller;
index 8f3f54cb4f2e7deec9998b365c1371792a9bd626..7bb878f369714ae6f6bdfdeb7eb4a138ae0bf647 100644 (file)
@@ -4,6 +4,8 @@ CONFIG_SYS_MALLOC_LEN=0x80000
 CONFIG_ENV_SIZE=0x4000
 CONFIG_ENV_SECT_SIZE=0x10000
 CONFIG_DEFAULT_DEVICE_TREE="mpc8379erdb"
+CONFIG_DEBUG_UART_BASE=0xe0004500
+CONFIG_DEBUG_UART_CLOCK=333333000
 CONFIG_SYS_CLK_FREQ=66666667
 CONFIG_ENV_ADDR=0xFE080000
 # CONFIG_SYS_PCI_64BIT is not set
@@ -118,6 +120,7 @@ CONFIG_LCRR_DBYP_PLL_BYPASSED=y
 CONFIG_LCRR_CLKDIV_8=y
 CONFIG_FSL_SERDES=y
 CONFIG_USE_UBOOTPATH=y
+CONFIG_DEBUG_UART=y
 CONFIG_SYS_MONITOR_LEN=524288
 CONFIG_OF_BOARD_SETUP=y
 CONFIG_OF_STDOUT_VIA_ALIAS=y
@@ -185,7 +188,9 @@ CONFIG_MII=y
 CONFIG_VSC7385_ENET=y
 CONFIG_TSEC_ENET=y
 CONFIG_RTC_DS1374=y
-CONFIG_SYS_NS16550_SERIAL=y
+CONFIG_SPECIFY_CONSOLE_INDEX=y
+CONFIG_DM_SERIAL=y
+CONFIG_SYS_NS16550=y
 CONFIG_USB=y
 CONFIG_USB_EHCI_HCD=y
 CONFIG_USB_EHCI_FSL=y
index 70b1c399241edf89ff19e45fd09132209b5faa49..3967cc283631c7f2745d5f122ae83871c4463dc3 100644 (file)
 /*
  * Serial Port
  */
+#if !CONFIG_IS_ENABLED(DM_SERIAL) && !CONFIG_IS_ENABLED(DM_CLK)
 #define CFG_SYS_NS16550_CLK            get_bus_freq(0)
+#endif
 
 #define CFG_SYS_BAUDRATE_TABLE \
                {300, 600, 1200, 2400, 4800, 9600, 19200, 38400, 115200}