blob: 3ae8b569edfc416414e1608a5b47e20eeda7efcc [file] [log] [blame]
Robin Getz96f10502009-09-24 14:11:24 +00001/*
Bryan Wub37bde12007-10-02 13:56:05 -07002 * BF5XX - NAND flash controller platfrom_device info
3 *
Robin Getz96f10502009-09-24 14:11:24 +00004 * Copyright 2007-2008 Analog Devices, Inc.
5 *
6 * Licensed under the GPL-2
Bryan Wub37bde12007-10-02 13:56:05 -07007 */
8
9/* struct bf5xx_nand_platform
10 *
11 * define a interface between platfrom board specific code and
12 * bf54x NFC driver.
13 *
14 * nr_partitions = number of partitions pointed to be partitoons (or zero)
15 * partitions = mtd partition list
16 */
17
18#define NFC_PG_SIZE_256 0
19#define NFC_PG_SIZE_512 1
20#define NFC_PG_SIZE_OFFSET 9
21
22#define NFC_NWIDTH_8 0
23#define NFC_NWIDTH_16 1
24#define NFC_NWIDTH_OFFSET 8
25
26#define NFC_RDDLY_OFFSET 4
27#define NFC_WRDLY_OFFSET 0
28
29#define NFC_STAT_NBUSY 1
30
31struct bf5xx_nand_platform {
32 /* NAND chip information */
33 unsigned short page_size;
34 unsigned short data_width;
35
36 /* RD/WR strobe delay timing information, all times in SCLK cycles */
37 unsigned short rd_dly;
38 unsigned short wr_dly;
39
40 /* NAND MTD partition information */
41 int nr_partitions;
42 struct mtd_partition *partitions;
43};