diff options
Diffstat (limited to 'arch/arm/mach-at91rm9200/board-csb637.c')
| -rw-r--r-- | arch/arm/mach-at91rm9200/board-csb637.c | 30 |
1 files changed, 14 insertions, 16 deletions
diff --git a/arch/arm/mach-at91rm9200/board-csb637.c b/arch/arm/mach-at91rm9200/board-csb637.c index f2c2d6e79bc6..2c4470d110da 100644 --- a/arch/arm/mach-at91rm9200/board-csb637.c +++ b/arch/arm/mach-at91rm9200/board-csb637.c | |||
| @@ -35,8 +35,8 @@ | |||
| 35 | #include <asm/mach/irq.h> | 35 | #include <asm/mach/irq.h> |
| 36 | 36 | ||
| 37 | #include <asm/arch/hardware.h> | 37 | #include <asm/arch/hardware.h> |
| 38 | #include <asm/mach/serial_at91rm9200.h> | ||
| 39 | #include <asm/arch/board.h> | 38 | #include <asm/arch/board.h> |
| 39 | #include <asm/arch/gpio.h> | ||
| 40 | 40 | ||
| 41 | #include "generic.h" | 41 | #include "generic.h" |
| 42 | 42 | ||
| @@ -54,14 +54,14 @@ static void __init csb637_init_irq(void) | |||
| 54 | * 0 .. 3 = USART0 .. USART3 | 54 | * 0 .. 3 = USART0 .. USART3 |
| 55 | * 4 = DBGU | 55 | * 4 = DBGU |
| 56 | */ | 56 | */ |
| 57 | #define CSB637_UART_MAP { 4, 1, -1, -1, -1 } /* ttyS0, ..., ttyS4 */ | 57 | static struct at91_uart_config __initdata csb637_uart_config = { |
| 58 | #define CSB637_SERIAL_CONSOLE 0 /* ttyS0 */ | 58 | .console_tty = 0, /* ttyS0 */ |
| 59 | .nr_tty = 2, | ||
| 60 | .tty_map = { 4, 1, -1, -1, -1 } /* ttyS0, ..., ttyS4 */ | ||
| 61 | }; | ||
| 59 | 62 | ||
| 60 | static void __init csb637_map_io(void) | 63 | static void __init csb637_map_io(void) |
| 61 | { | 64 | { |
| 62 | int serial[AT91_NR_UART] = CSB637_UART_MAP; | ||
| 63 | int i; | ||
| 64 | |||
| 65 | at91rm9200_map_io(); | 65 | at91rm9200_map_io(); |
| 66 | 66 | ||
| 67 | /* Initialize clocks: 3.6864 MHz crystal */ | 67 | /* Initialize clocks: 3.6864 MHz crystal */ |
| @@ -70,16 +70,8 @@ static void __init csb637_map_io(void) | |||
| 70 | /* Setup the LEDs */ | 70 | /* Setup the LEDs */ |
| 71 | at91_init_leds(AT91_PIN_PB2, AT91_PIN_PB2); | 71 | at91_init_leds(AT91_PIN_PB2, AT91_PIN_PB2); |
| 72 | 72 | ||
| 73 | #ifdef CONFIG_SERIAL_AT91 | 73 | /* Setup the serial ports and console */ |
| 74 | at91_console_port = CSB637_SERIAL_CONSOLE; | 74 | at91_init_serial(&csb637_uart_config); |
| 75 | memcpy(at91_serial_map, serial, sizeof(serial)); | ||
| 76 | |||
| 77 | /* Register UARTs */ | ||
| 78 | for (i = 0; i < AT91_NR_UART; i++) { | ||
| 79 | if (serial[i] >= 0) | ||
| 80 | at91_register_uart(i, serial[i]); | ||
| 81 | } | ||
| 82 | #endif | ||
| 83 | } | 75 | } |
| 84 | 76 | ||
| 85 | static struct at91_eth_data __initdata csb637_eth_data = { | 77 | static struct at91_eth_data __initdata csb637_eth_data = { |
| @@ -98,12 +90,18 @@ static struct at91_udc_data __initdata csb637_udc_data = { | |||
| 98 | 90 | ||
| 99 | static void __init csb637_board_init(void) | 91 | static void __init csb637_board_init(void) |
| 100 | { | 92 | { |
| 93 | /* Serial */ | ||
| 94 | at91_add_device_serial(); | ||
| 101 | /* Ethernet */ | 95 | /* Ethernet */ |
| 102 | at91_add_device_eth(&csb637_eth_data); | 96 | at91_add_device_eth(&csb637_eth_data); |
| 103 | /* USB Host */ | 97 | /* USB Host */ |
| 104 | at91_add_device_usbh(&csb637_usbh_data); | 98 | at91_add_device_usbh(&csb637_usbh_data); |
| 105 | /* USB Device */ | 99 | /* USB Device */ |
| 106 | at91_add_device_udc(&csb637_udc_data); | 100 | at91_add_device_udc(&csb637_udc_data); |
| 101 | /* I2C */ | ||
| 102 | at91_add_device_i2c(); | ||
| 103 | /* SPI */ | ||
| 104 | at91_add_device_spi(NULL, 0); | ||
| 107 | } | 105 | } |
| 108 | 106 | ||
| 109 | MACHINE_START(CSB637, "Cogent CSB637") | 107 | MACHINE_START(CSB637, "Cogent CSB637") |
