nand.h 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  1. /* linux/include/asm-blackfin/nand.h
  2. *
  3. * Copyright (c) 2007 Analog Devices, Inc.
  4. * Bryan Wu <bryan.wu@analog.com>
  5. *
  6. * BF5XX - NAND flash controller platfrom_device info
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License version 2 as
  10. * published by the Free Software Foundation.
  11. */
  12. /* struct bf5xx_nand_platform
  13. *
  14. * define a interface between platfrom board specific code and
  15. * bf54x NFC driver.
  16. *
  17. * nr_partitions = number of partitions pointed to be partitoons (or zero)
  18. * partitions = mtd partition list
  19. */
  20. #define NFC_PG_SIZE_256 0
  21. #define NFC_PG_SIZE_512 1
  22. #define NFC_PG_SIZE_OFFSET 9
  23. #define NFC_NWIDTH_8 0
  24. #define NFC_NWIDTH_16 1
  25. #define NFC_NWIDTH_OFFSET 8
  26. #define NFC_RDDLY_OFFSET 4
  27. #define NFC_WRDLY_OFFSET 0
  28. #define NFC_STAT_NBUSY 1
  29. struct bf5xx_nand_platform {
  30. /* NAND chip information */
  31. unsigned short page_size;
  32. unsigned short data_width;
  33. /* RD/WR strobe delay timing information, all times in SCLK cycles */
  34. unsigned short rd_dly;
  35. unsigned short wr_dly;
  36. /* NAND MTD partition information */
  37. int nr_partitions;
  38. struct mtd_partition *partitions;
  39. };