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.

Calculating 115200 baud rate for a DM368

Guys,

 

I am using a DM368 and I am trying to ensure uartclk value is correct for a 115200 baud rate on UART 1.My clock is 24Mhz: The number I came up with was 133470000, it seems corect, but I am dropping bytes and I am not sure if the setup below is correct.

 

static struct plat_serial8250_port serial_platform_data[] = {
    {
        .membase = (char *) IO_ADDRESS(DAVINCI_UART0_BASE),
        .mapbase = (unsigned long) DAVINCI_UART0_BASE,
        .irq = IRQ_UARTINT0,
        .flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST,
        .iotype = UPIO_MEM,
        .regshift = 2,
        .uartclk = 24000000,
    },
    {
        .membase = (char *) IO_ADDRESS(DM365_UART1_BASE),
        .mapbase = (unsigned long) DM365_UART1_BASE,
        .irq = IRQ_UARTINT1,
        .flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST,
        .iotype = UPIO_MEM,
        .regshift = 2,
        .uartclk = 133470000,
    },
    {
        .flags = 0
    },
};