|
@@ -593,9 +593,6 @@ static inline void configure_ssc1_pins(unsigned pins)
|
|
}
|
|
}
|
|
|
|
|
|
/*
|
|
/*
|
|
- * Return the device node so that board init code can use it as the
|
|
|
|
- * parent for the device node reflecting how it's used on this board.
|
|
|
|
- *
|
|
|
|
* SSC controllers are accessed through library code, instead of any
|
|
* SSC controllers are accessed through library code, instead of any
|
|
* kind of all-singing/all-dancing driver. For example one could be
|
|
* kind of all-singing/all-dancing driver. For example one could be
|
|
* used by a particular I2S audio codec's driver, while another one
|
|
* used by a particular I2S audio codec's driver, while another one
|
|
@@ -856,54 +853,9 @@ static inline void configure_usart3_pins(unsigned pins)
|
|
at91_set_B_periph(AT91_PIN_PD3, 0); /* CTS3 */
|
|
at91_set_B_periph(AT91_PIN_PD3, 0); /* CTS3 */
|
|
}
|
|
}
|
|
|
|
|
|
-static struct platform_device *at91_uarts[ATMEL_MAX_UART]; /* the UARTs to use */
|
|
|
|
|
|
+static struct platform_device *__initdata at91_uarts[ATMEL_MAX_UART]; /* the UARTs to use */
|
|
struct platform_device *atmel_default_console_device; /* the serial console device */
|
|
struct platform_device *atmel_default_console_device; /* the serial console device */
|
|
|
|
|
|
-void __init __deprecated at91_init_serial(struct at91_uart_config *config)
|
|
|
|
-{
|
|
|
|
- int i;
|
|
|
|
-
|
|
|
|
- /* Fill in list of supported UARTs */
|
|
|
|
- for (i = 0; i < config->nr_tty; i++) {
|
|
|
|
- switch (config->tty_map[i]) {
|
|
|
|
- case 0:
|
|
|
|
- configure_usart0_pins(ATMEL_UART_CTS | ATMEL_UART_RTS);
|
|
|
|
- at91_uarts[i] = &at91sam9rl_uart0_device;
|
|
|
|
- at91_clock_associate("usart0_clk", &at91sam9rl_uart0_device.dev, "usart");
|
|
|
|
- break;
|
|
|
|
- case 1:
|
|
|
|
- configure_usart1_pins(0);
|
|
|
|
- at91_uarts[i] = &at91sam9rl_uart1_device;
|
|
|
|
- at91_clock_associate("usart1_clk", &at91sam9rl_uart1_device.dev, "usart");
|
|
|
|
- break;
|
|
|
|
- case 2:
|
|
|
|
- configure_usart2_pins(0);
|
|
|
|
- at91_uarts[i] = &at91sam9rl_uart2_device;
|
|
|
|
- at91_clock_associate("usart2_clk", &at91sam9rl_uart2_device.dev, "usart");
|
|
|
|
- break;
|
|
|
|
- case 3:
|
|
|
|
- configure_usart3_pins(0);
|
|
|
|
- at91_uarts[i] = &at91sam9rl_uart3_device;
|
|
|
|
- at91_clock_associate("usart3_clk", &at91sam9rl_uart3_device.dev, "usart");
|
|
|
|
- break;
|
|
|
|
- case 4:
|
|
|
|
- configure_dbgu_pins();
|
|
|
|
- at91_uarts[i] = &at91sam9rl_dbgu_device;
|
|
|
|
- at91_clock_associate("mck", &at91sam9rl_dbgu_device.dev, "usart");
|
|
|
|
- break;
|
|
|
|
- default:
|
|
|
|
- continue;
|
|
|
|
- }
|
|
|
|
- at91_uarts[i]->id = i; /* update ID number to mapped ID */
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- /* Set serial console device */
|
|
|
|
- if (config->console_tty < ATMEL_MAX_UART)
|
|
|
|
- atmel_default_console_device = at91_uarts[config->console_tty];
|
|
|
|
- if (!atmel_default_console_device)
|
|
|
|
- printk(KERN_INFO "AT91: No default serial console defined.\n");
|
|
|
|
-}
|
|
|
|
-
|
|
|
|
void __init at91_register_uart(unsigned id, unsigned portnr, unsigned pins)
|
|
void __init at91_register_uart(unsigned id, unsigned portnr, unsigned pins)
|
|
{
|
|
{
|
|
struct platform_device *pdev;
|
|
struct platform_device *pdev;
|
|
@@ -947,8 +899,6 @@ void __init at91_set_serial_console(unsigned portnr)
|
|
{
|
|
{
|
|
if (portnr < ATMEL_MAX_UART)
|
|
if (portnr < ATMEL_MAX_UART)
|
|
atmel_default_console_device = at91_uarts[portnr];
|
|
atmel_default_console_device = at91_uarts[portnr];
|
|
- if (!atmel_default_console_device)
|
|
|
|
- printk(KERN_INFO "AT91: No default serial console defined.\n");
|
|
|
|
}
|
|
}
|
|
|
|
|
|
void __init at91_add_device_serial(void)
|
|
void __init at91_add_device_serial(void)
|
|
@@ -959,9 +909,11 @@ void __init at91_add_device_serial(void)
|
|
if (at91_uarts[i])
|
|
if (at91_uarts[i])
|
|
platform_device_register(at91_uarts[i]);
|
|
platform_device_register(at91_uarts[i]);
|
|
}
|
|
}
|
|
|
|
+
|
|
|
|
+ if (!atmel_default_console_device)
|
|
|
|
+ printk(KERN_INFO "AT91: No default serial console defined.\n");
|
|
}
|
|
}
|
|
#else
|
|
#else
|
|
-void __init __deprecated at91_init_serial(struct at91_uart_config *config) {}
|
|
|
|
void __init at91_register_uart(unsigned id, unsigned portnr, unsigned pins) {}
|
|
void __init at91_register_uart(unsigned id, unsigned portnr, unsigned pins) {}
|
|
void __init at91_set_serial_console(unsigned portnr) {}
|
|
void __init at91_set_serial_console(unsigned portnr) {}
|
|
void __init at91_add_device_serial(void) {}
|
|
void __init at91_add_device_serial(void) {}
|