gpmc-nand.txt 2.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  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" <deprecated> use "ham1" instead
  17. "hw" <deprecated> use "ham1" instead
  18. "hw-romcode" <deprecated> use "ham1" instead
  19. "ham1" 1-bit Hamming ecc code
  20. "bch4" 4-bit BCH ecc code
  21. "bch8" 8-bit BCH ecc code
  22. - ti,nand-xfer-type: A string setting the data transfer type. One of:
  23. "prefetch-polled" Prefetch polled mode (default)
  24. "polled" Polled mode, without prefetch
  25. "prefetch-dma" Prefetch enabled sDMA mode
  26. "prefetch-irq" Prefetch enabled irq mode
  27. - elm_id: <deprecated> use "ti,elm-id" instead
  28. - ti,elm-id: Specifies phandle of the ELM devicetree node.
  29. ELM is an on-chip hardware engine on TI SoC which is used for
  30. locating ECC errors for BCHx algorithms. SoC devices which have
  31. ELM hardware engines should specify this device node in .dtsi
  32. Using ELM for ECC error correction frees some CPU cycles.
  33. For inline partiton table parsing (optional):
  34. - #address-cells: should be set to 1
  35. - #size-cells: should be set to 1
  36. Example for an AM33xx board:
  37. gpmc: gpmc@50000000 {
  38. compatible = "ti,am3352-gpmc";
  39. ti,hwmods = "gpmc";
  40. reg = <0x50000000 0x1000000>;
  41. interrupts = <100>;
  42. gpmc,num-cs = <8>;
  43. gpmc,num-waitpins = <2>;
  44. #address-cells = <2>;
  45. #size-cells = <1>;
  46. ranges = <0 0 0x08000000 0x2000>; /* CS0: NAND */
  47. elm_id = <&elm>;
  48. nand@0,0 {
  49. reg = <0 0 0>; /* CS0, offset 0 */
  50. nand-bus-width = <16>;
  51. ti,nand-ecc-opt = "bch8";
  52. ti,nand-xfer-type = "polled";
  53. gpmc,sync-clk-ps = <0>;
  54. gpmc,cs-on-ns = <0>;
  55. gpmc,cs-rd-off-ns = <44>;
  56. gpmc,cs-wr-off-ns = <44>;
  57. gpmc,adv-on-ns = <6>;
  58. gpmc,adv-rd-off-ns = <34>;
  59. gpmc,adv-wr-off-ns = <44>;
  60. gpmc,we-off-ns = <40>;
  61. gpmc,oe-off-ns = <54>;
  62. gpmc,access-ns = <64>;
  63. gpmc,rd-cycle-ns = <82>;
  64. gpmc,wr-cycle-ns = <82>;
  65. gpmc,wr-access-ns = <40>;
  66. gpmc,wr-data-mux-bus-ns = <0>;
  67. #address-cells = <1>;
  68. #size-cells = <1>;
  69. /* partitions go here */
  70. };
  71. };