aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-at91/board-usb-a9260.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-at91/board-usb-a9260.c')
-rw-r--r--arch/arm/mach-at91/board-usb-a9260.c35
1 files changed, 29 insertions, 6 deletions
diff --git a/arch/arm/mach-at91/board-usb-a9260.c b/arch/arm/mach-at91/board-usb-a9260.c
index 7c350357333a..d13304c0bc45 100644
--- a/arch/arm/mach-at91/board-usb-a9260.c
+++ b/arch/arm/mach-at91/board-usb-a9260.c
@@ -41,8 +41,10 @@
41#include <mach/hardware.h> 41#include <mach/hardware.h>
42#include <mach/board.h> 42#include <mach/board.h>
43#include <mach/gpio.h> 43#include <mach/gpio.h>
44#include <mach/at91sam9_smc.h>
44#include <mach/at91_shdwc.h> 45#include <mach/at91_shdwc.h>
45 46
47#include "sam9_smc.h"
46#include "generic.h" 48#include "generic.h"
47 49
48 50
@@ -121,13 +123,34 @@ static struct atmel_nand_data __initdata ek_nand_data = {
121 .rdy_pin = AT91_PIN_PC13, 123 .rdy_pin = AT91_PIN_PC13,
122 .enable_pin = AT91_PIN_PC14, 124 .enable_pin = AT91_PIN_PC14,
123 .partition_info = nand_partitions, 125 .partition_info = nand_partitions,
124#if defined(CONFIG_MTD_NAND_ATMEL_BUSWIDTH_16)
125 .bus_width_16 = 1,
126#else
127 .bus_width_16 = 0,
128#endif
129}; 126};
130 127
128static struct sam9_smc_config __initdata ek_nand_smc_config = {
129 .ncs_read_setup = 0,
130 .nrd_setup = 1,
131 .ncs_write_setup = 0,
132 .nwe_setup = 1,
133
134 .ncs_read_pulse = 3,
135 .nrd_pulse = 3,
136 .ncs_write_pulse = 3,
137 .nwe_pulse = 3,
138
139 .read_cycle = 5,
140 .write_cycle = 5,
141
142 .mode = AT91_SMC_READMODE | AT91_SMC_WRITEMODE | AT91_SMC_EXNWMODE_DISABLE | AT91_SMC_DBW_8,
143 .tdf_cycles = 2,
144};
145
146static void __init ek_add_device_nand(void)
147{
148 /* configure chip-select 3 (NAND) */
149 sam9_smc_configure(3, &ek_nand_smc_config);
150
151 at91_add_device_nand(&ek_nand_data);
152}
153
131/* 154/*
132 * GPIO Buttons 155 * GPIO Buttons
133 */ 156 */
@@ -189,7 +212,7 @@ static void __init ek_board_init(void)
189 /* USB Device */ 212 /* USB Device */
190 at91_add_device_udc(&ek_udc_data); 213 at91_add_device_udc(&ek_udc_data);
191 /* NAND */ 214 /* NAND */
192 at91_add_device_nand(&ek_nand_data); 215 ek_add_device_nand();
193 /* I2C */ 216 /* I2C */
194 at91_add_device_i2c(NULL, 0); 217 at91_add_device_i2c(NULL, 0);
195 /* Ethernet */ 218 /* Ethernet */