Forum Discussion
UART 16550 compatible Linux device
Hi Shoval,
You will need to add it in the device tree accordingly. By default it is only referring to the HPS UART0 and UART1.
Thanks.
Regards,
Aik Eu
- Shoval2 years ago
New Contributor
Hello Aik,
If I understand correctly the 16550 compatible soft IP is not the same as the synopsys-16550 compatible that is used in the HPS UART 0/1.
The HPS UART node :
##########################
hps_0_uart0: serial@0xffc02000 {compatible = "snps,dw-apb-uart-18.1", "snps,dw-apb-uart";reg = <0xffc02000 0x00000100>;interrupt-parent = <&hps_0_arm_gic_0>;interrupts = <0 162 4>;clocks = <&l4_sp_clk>;reg-io-width = <4>; /* embeddedsw.dts.params.reg-io-width type NUMBER */reg-shift = <2>; /* embeddedsw.dts.params.reg-shift type NUMBER */status = "okay"; /* embeddedsw.dts.params.status type STRING */}; //end serial@0xffc02000 (hps_0_uart0)##########################
The soft core 16550 UART IP node :
##########################
a_16550_uart_0: serial@0x000000000 {compatible = "altr,altera_16550_uart-18.1", "altr,16550-FIFO128", "ns16550a";reg = <0x00000000 0x00000000 0x00000200>;interrupt-parent = <&hps_0_arm_gic_0>;interrupts = <0 40 4>;clock-frequency = <100000000>; /* embeddedsw.dts.params.clock-frequency type NUMBER */fifo-size = <128>; /* embeddedsw.dts.params.fifo-size type NUMBER */reg-io-width = <4>; /* embeddedsw.dts.params.reg-io-width type NUMBER */reg-shift = <2>; /* embeddedsw.dts.params.reg-shift type NUMBER */}; //end serial@0x000000000 (a_16550_uart_0)##########################
the UART soft core IP is added under the hps_0_bridges: bridge@0xc0000000, and have an appropriate device driver (drivers/tty/serial/8250) in the yocto kernel-source directory.
The Linux does compile, and the node is visible via /proc/device-tree/sopc@0/bridge@0xc0000000/serial@0x0000000, no errors are visible on Linux boot, but I cant find the device.