aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-at91/at91rm9200_devices.c
diff options
context:
space:
mode:
authorAndrew Victor <linux@maxim.org.za>2008-04-15 16:16:38 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2008-04-17 10:55:52 -0400
commit11aadac4f6adc032cfd1e41c348a7a568819ed94 (patch)
treed9e5523c4ea62cd82f25325a1cd387d538daf26c /arch/arm/mach-at91/at91rm9200_devices.c
parent2f036ac63ebfa3fc618a1f22324ef9297c5b7d05 (diff)
[ARM] 4982/1: [AT91] Drop old-style UART initialization (Part 1)
All the SAM9 boards supported by mainline and the AT91 patches have been converted to the new-style UART initialization. Therefore drop support for the old at91_init_serial() interface for SAM9. at91_uarts[] array can also be marked as __initdata. The warning that no serial-console is defined moved from at91_set_serial_console() to at91_add_device_serial() since the whole point is the board-specific file is not calling at91_set_serial_console(). Signed-off-by: Andrew Victor <linux@maxim.org.za> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
Diffstat (limited to 'arch/arm/mach-at91/at91rm9200_devices.c')
-rw-r--r--arch/arm/mach-at91/at91rm9200_devices.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/arch/arm/mach-at91/at91rm9200_devices.c b/arch/arm/mach-at91/at91rm9200_devices.c
index 70d3a0018530..de19bee83f75 100644
--- a/arch/arm/mach-at91/at91rm9200_devices.c
+++ b/arch/arm/mach-at91/at91rm9200_devices.c
@@ -1103,7 +1103,7 @@ static inline void configure_usart3_pins(unsigned pins)
1103 at91_set_B_periph(AT91_PIN_PB0, 0); /* RTS3 */ 1103 at91_set_B_periph(AT91_PIN_PB0, 0); /* RTS3 */
1104} 1104}
1105 1105
1106static struct platform_device *at91_uarts[ATMEL_MAX_UART]; /* the UARTs to use */ 1106static struct platform_device *__initdata at91_uarts[ATMEL_MAX_UART]; /* the UARTs to use */
1107struct platform_device *atmel_default_console_device; /* the serial console device */ 1107struct platform_device *atmel_default_console_device; /* the serial console device */
1108 1108
1109void __init __deprecated at91_init_serial(struct at91_uart_config *config) 1109void __init __deprecated at91_init_serial(struct at91_uart_config *config)
@@ -1194,8 +1194,6 @@ void __init at91_set_serial_console(unsigned portnr)
1194{ 1194{
1195 if (portnr < ATMEL_MAX_UART) 1195 if (portnr < ATMEL_MAX_UART)
1196 atmel_default_console_device = at91_uarts[portnr]; 1196 atmel_default_console_device = at91_uarts[portnr];
1197 if (!atmel_default_console_device)
1198 printk(KERN_INFO "AT91: No default serial console defined.\n");
1199} 1197}
1200 1198
1201void __init at91_add_device_serial(void) 1199void __init at91_add_device_serial(void)
@@ -1206,6 +1204,9 @@ void __init at91_add_device_serial(void)
1206 if (at91_uarts[i]) 1204 if (at91_uarts[i])
1207 platform_device_register(at91_uarts[i]); 1205 platform_device_register(at91_uarts[i]);
1208 } 1206 }
1207
1208 if (!atmel_default_console_device)
1209 printk(KERN_INFO "AT91: No default serial console defined.\n");
1209} 1210}
1210#else 1211#else
1211void __init __deprecated at91_init_serial(struct at91_uart_config *config) {} 1212void __init __deprecated at91_init_serial(struct at91_uart_config *config) {}