0030-mtd-spi-nor-Bindings-for-Cadence-Quad-SPI-Flash-Cont.patch 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. From 8e8a7168e89cc978ca14ab74ab20193ca09e3f3a Mon Sep 17 00:00:00 2001
  2. From: Graham Moore <grmoore@opensource.altera.com>
  3. Date: Tue, 28 Jul 2015 12:38:02 -0500
  4. Subject: [PATCH 30/33] mtd: spi-nor: Bindings for Cadence Quad SPI Flash
  5. Controller driver.
  6. Add binding document for the Cadence QSPI controller.
  7. Signed-off-by: Graham Moore <grmoore@opensource.altera.com>
  8. Signed-off-by: Marek Vasut <marex@denx.de>
  9. Cc: Alan Tull <atull@opensource.altera.com>
  10. Cc: Brian Norris <computersforpeace@gmail.com>
  11. Cc: David Woodhouse <dwmw2@infradead.org>
  12. Cc: Dinh Nguyen <dinguyen@opensource.altera.com>
  13. Cc: Graham Moore <grmoore@opensource.altera.com>
  14. Cc: Vignesh R <vigneshr@ti.com>
  15. Cc: Yves Vandervennet <yvanderv@opensource.altera.com>
  16. Cc: devicetree@vger.kernel.org
  17. V2: Add cdns prefix to driver-specific bindings.
  18. V3: Use existing property "is-decoded-cs" instead of creating a
  19. duplicate, "ext-decoder". Timing parameters are in nanoseconds,
  20. not master reference clocks. Remove bus-num completely.
  21. V4: Add new properties fifo-width and trigger-address
  22. V7: - Prefix all of the Cadence-specific properties with cdns prefix,
  23. those are in particular "cdns,is-decoded-cs", "cdns,fifo-depth",
  24. "cdns,fifo-width", "cdns,trigger-address".
  25. - Drop bogus properties which were not used and were incorrect.
  26. V8: Align lines to 80 chars.
  27. ---
  28. .../devicetree/bindings/mtd/cadence-quadspi.txt | 56 ++++++++++++++++++++++
  29. 1 file changed, 56 insertions(+)
  30. create mode 100644 Documentation/devicetree/bindings/mtd/cadence-quadspi.txt
  31. diff --git a/Documentation/devicetree/bindings/mtd/cadence-quadspi.txt b/Documentation/devicetree/bindings/mtd/cadence-quadspi.txt
  32. new file mode 100644
  33. index 0000000..f248056
  34. --- /dev/null
  35. +++ b/Documentation/devicetree/bindings/mtd/cadence-quadspi.txt
  36. @@ -0,0 +1,56 @@
  37. +* Cadence Quad SPI controller
  38. +
  39. +Required properties:
  40. +- compatible : Should be "cdns,qspi-nor".
  41. +- reg : Contains two entries, each of which is a tuple consisting of a
  42. + physical address and length. The first entry is the address and
  43. + length of the controller register set. The second entry is the
  44. + address and length of the QSPI Controller data area.
  45. +- interrupts : Unit interrupt specifier for the controller interrupt.
  46. +- clocks : phandle to the Quad SPI clock.
  47. +- cdns,fifo-depth : Size of the data FIFO in words.
  48. +- cdns,fifo-width : Bus width of the data FIFO in bytes.
  49. +- cdns,trigger-address : 32-bit indirect AHB trigger address.
  50. +
  51. +Optional properties:
  52. +- cdns,is-decoded-cs : Flag to indicate whether decoder is used or not.
  53. +
  54. +Optional subnodes:
  55. +Subnodes of the Cadence Quad SPI controller are spi slave nodes with additional
  56. +custom properties:
  57. +- cdns,read-delay : Delay for read capture logic, in clock cycles
  58. +- cdns,tshsl-ns : Delay in nanoseconds for the length that the master
  59. + mode chip select outputs are de-asserted between
  60. + transactions.
  61. +- cdns,tsd2d-ns : Delay in nanoseconds between one chip select being
  62. + de-activated and the activation of another.
  63. +- cdns,tchsh-ns : Delay in nanoseconds between last bit of current
  64. + transaction and deasserting the device chip select
  65. + (qspi_n_ss_out).
  66. +- cdns,tslch-ns : Delay in nanoseconds between setting qspi_n_ss_out low
  67. + and first bit transfer.
  68. +
  69. +Example:
  70. +
  71. + qspi: spi@ff705000 {
  72. + compatible = "cdns,qspi-nor";
  73. + #address-cells = <1>;
  74. + #size-cells = <0>;
  75. + reg = <0xff705000 0x1000>,
  76. + <0xffa00000 0x1000>;
  77. + interrupts = <0 151 4>;
  78. + clocks = <&qspi_clk>;
  79. + cdns,is-decoded-cs;
  80. + cdns,fifo-depth = <128>;
  81. + cdns,fifo-width = <4>;
  82. + cdns,trigger-address = <0x00000000>;
  83. +
  84. + flash0: n25q00@0 {
  85. + ...
  86. + cdns,read-delay = <4>;
  87. + cdns,tshsl-ns = <50>;
  88. + cdns,tsd2d-ns = <50>;
  89. + cdns,tchsh-ns = <4>;
  90. + cdns,tslch-ns = <4>;
  91. + };
  92. + };
  93. --
  94. 2.8.1