This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Linux: uart 1 problem

Other Parts Discussed in Thread: DA8XX

Tool/software: Linux

uart 1 problem

hi,

I use OMAP L138 ( EVM) . As you know, OMAP L 138 has three uarts.
It uses the uart 2 to connect with console window. i have some questions related to other two uarts. I am working with Linux

1) Can i enable uart 1 to talk with my external device ?


I have commented out the below lines in board-da850-evm.c

/*
* shut down uart 0 and 1; they are not used on the board and
* accessing them causes endless "too much work in irq53" messages
* with arago fs
*/
__raw_writel(0, IO_ADDRESS(DA8XX_UART1_BASE) + 0x30);
__raw_writel(0, IO_ADDRESS(DA8XX_UART0_BASE) + 0x30);


Changed the preferred console from ttys2 to ttys1


return add_preferred_console("ttyS", 1, "115200");

Any suggestions on the how to enable uart 1 and use it for console ?

  • Did you modify the device three?

    You have the following entries in:
    1. arch/arm/boot/dts/da850-lcdk.dts:
    aliases {
    serial2 = &serial2;
    ethernet0 = &eth0;
    };

    chosen {
    stdout-path = "serial2:115200n8";
    };

    2. in u-boot you should make sure you change the pinmux settings and enable serial1 (which is uart 1). Also change u-boot configuration in u-boot/include/configs/da850evm.h:
    /*
    * Serial Driver info
    */
    #define CONFIG_SYS_NS16550_SERIAL
    #define CONFIG_SYS_NS16550_REG_SIZE -4 /* NS16550 register size */
    #define CONFIG_SYS_NS16550_COM1 DAVINCI_UART2_BASE /* Base address of UART2 */
    #define CONFIG_SYS_NS16550_CLK clk_get(DAVINCI_UART2_CLKID)
    #define CONFIG_CONS_INDEX 1 /* use UART0 for console */
    #define CONFIG_BAUDRATE 115200 /* Default baud rate */

    Also check the u-boot environment variables passed to kernel (make sure you pass the same uart as serial console, as the one configured in kernel, in your case uart1).

    Best Regards,
    Yordan