nand.h 977 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. /*
  2. * BF5XX - NAND flash controller platfrom_device info
  3. *
  4. * Copyright 2007-2008 Analog Devices, Inc.
  5. *
  6. * Licensed under the GPL-2
  7. */
  8. /* struct bf5xx_nand_platform
  9. *
  10. * define a interface between platfrom board specific code and
  11. * bf54x NFC driver.
  12. *
  13. * nr_partitions = number of partitions pointed to be partitoons (or zero)
  14. * partitions = mtd partition list
  15. */
  16. #define NFC_PG_SIZE_256 0
  17. #define NFC_PG_SIZE_512 1
  18. #define NFC_PG_SIZE_OFFSET 9
  19. #define NFC_NWIDTH_8 0
  20. #define NFC_NWIDTH_16 1
  21. #define NFC_NWIDTH_OFFSET 8
  22. #define NFC_RDDLY_OFFSET 4
  23. #define NFC_WRDLY_OFFSET 0
  24. #define NFC_STAT_NBUSY 1
  25. struct bf5xx_nand_platform {
  26. /* NAND chip information */
  27. unsigned short page_size;
  28. unsigned short data_width;
  29. /* RD/WR strobe delay timing information, all times in SCLK cycles */
  30. unsigned short rd_dly;
  31. unsigned short wr_dly;
  32. /* NAND MTD partition information */
  33. int nr_partitions;
  34. struct mtd_partition *partitions;
  35. };