gpmc-nand.txt 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. Device tree bindings for GPMC connected NANDs
  2. GPMC connected NAND (found on OMAP boards) are represented as child nodes of
  3. the GPMC controller with a name of "nand".
  4. All timing relevant properties as well as generic gpmc child properties are
  5. explained in a separate documents - please refer to
  6. Documentation/devicetree/bindings/bus/ti-gpmc.txt
  7. For NAND specific properties such as ECC modes or bus width, please refer to
  8. Documentation/devicetree/bindings/mtd/nand.txt
  9. Required properties:
  10. - reg: The CS line the peripheral is connected to
  11. Optional properties:
  12. - nand-bus-width: Set this numeric value to 16 if the hardware
  13. is wired that way. If not specified, a bus
  14. width of 8 is assumed.
  15. - ti,nand-ecc-opt: A string setting the ECC layout to use. One of:
  16. "sw" Software method (default)
  17. "hw" Hardware method
  18. "hw-romcode" gpmc hamming mode method & romcode layout
  19. "bch4" 4-bit BCH ecc code
  20. "bch8" 8-bit BCH ecc code
  21. - ti,nand-xfer-type: A string setting the data transfer type. One of:
  22. "prefetch-polled" Prefetch polled mode (default)
  23. "polled" Polled mode, without prefetch
  24. "prefetch-dma" Prefetch enabled sDMA mode
  25. "prefetch-irq" Prefetch enabled irq mode
  26. - elm_id: Specifies elm device node. This is required to support BCH
  27. error correction using ELM module.
  28. For inline partiton table parsing (optional):
  29. - #address-cells: should be set to 1
  30. - #size-cells: should be set to 1
  31. Example for an AM33xx board:
  32. gpmc: gpmc@50000000 {
  33. compatible = "ti,am3352-gpmc";
  34. ti,hwmods = "gpmc";
  35. reg = <0x50000000 0x1000000>;
  36. interrupts = <100>;
  37. gpmc,num-cs = <8>;
  38. gpmc,num-waitpins = <2>;
  39. #address-cells = <2>;
  40. #size-cells = <1>;
  41. ranges = <0 0 0x08000000 0x2000>; /* CS0: NAND */
  42. elm_id = <&elm>;
  43. nand@0,0 {
  44. reg = <0 0 0>; /* CS0, offset 0 */
  45. nand-bus-width = <16>;
  46. ti,nand-ecc-opt = "bch8";
  47. ti,nand-xfer-type = "polled";
  48. gpmc,sync-clk-ps = <0>;
  49. gpmc,cs-on-ns = <0>;
  50. gpmc,cs-rd-off-ns = <44>;
  51. gpmc,cs-wr-off-ns = <44>;
  52. gpmc,adv-on-ns = <6>;
  53. gpmc,adv-rd-off-ns = <34>;
  54. gpmc,adv-wr-off-ns = <44>;
  55. gpmc,we-off-ns = <40>;
  56. gpmc,oe-off-ns = <54>;
  57. gpmc,access-ns = <64>;
  58. gpmc,rd-cycle-ns = <82>;
  59. gpmc,wr-cycle-ns = <82>;
  60. gpmc,wr-access-ns = <40>;
  61. gpmc,wr-data-mux-bus-ns = <0>;
  62. #address-cells = <1>;
  63. #size-cells = <1>;
  64. /* partitions go here */
  65. };
  66. };