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