Esempio n. 1
0
/*
 * Internal UARTs need to be initialized for the 8250 autoconfig to work
 * properly. Note that the TX watermark initialization may not be needed
 * once the 8250.c watermark handling code is merged.
 */
static void __init omap_serial_reset(struct plat_serial8250_port *p)
{
	omap_serial_outp(p, UART_OMAP_MDR1, 0x07);	/* disable UART */
	omap_serial_outp(p, UART_OMAP_SCR, 0x08);	/* TX watermark */
	omap_serial_outp(p, UART_OMAP_MDR1, 0x00);	/* enable UART */

	if (!cpu_is_omap1510()) {
		omap_serial_outp(p, UART_OMAP_SYSC, 0x01);
		while (!(omap_serial_in(p, UART_OMAP_SYSC) & 0x01));
	}
}
static void __init omap_serial_reset(struct plat_serial8250_port *p)
{
    omap_serial_outp(p, UART_OMAP_MDR1,
                     UART_OMAP_MDR1_DISABLE);
    omap_serial_outp(p, UART_OMAP_SCR, 0x08);
    omap_serial_outp(p, UART_OMAP_MDR1,
                     UART_OMAP_MDR1_16X_MODE);

    if (!cpu_is_omap15xx()) {
        omap_serial_outp(p, UART_OMAP_SYSC, 0x01);
        while (!(omap_serial_in(p, UART_OMAP_SYSC) & 0x01));
    }
}