am33xx-usb.txt 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197
  1. AM33xx MUSB
  2. ~~~~~~~~~~~~~~~
  3. - compatible: ti,am33xx-usb
  4. - reg: offset and length of the usbss register sets
  5. - ti,hwmods : must be "usb_otg_hs"
  6. The glue layer contains multiple child nodes. It is required the have
  7. at least a control module node, USB node and a PHY node. The second USB
  8. node and its PHY node is optional. The DMA node is also optional.
  9. Reset module
  10. ~~~~~~~~~~~~
  11. - compatible: ti,am335x-usb-ctrl-module
  12. - reg: offset and length of the "USB control registers" in the "Control
  13. Module" block. A second offset and length for the USB wake up control
  14. in the same memory block.
  15. - reg-names: "phy_ctrl" for the "USB control registers" and "wakeup" for
  16. the USB wake up control register.
  17. USB PHY
  18. ~~~~~~~
  19. compatible: ti,am335x-usb-phy
  20. reg: offset and length of the "USB PHY" register space
  21. ti,ctrl_mod: reference to the "reset module" node
  22. reg-names: phy
  23. The PHY should have a "phy" alias numbered properly in the alias
  24. node.
  25. USB
  26. ~~~
  27. - compatible: ti,musb-am33xx
  28. - reg: offset and length of "USB Controller Registers", and offset and
  29. length of "USB Core" register space.
  30. - reg-names: control for the ""USB Controller Registers" and "mc" for
  31. "USB Core" register space
  32. - interrupts: USB interrupt number
  33. - interrupt-names: mc
  34. - dr_mode: Should be one of "host", "peripheral" or "otg".
  35. - mentor,multipoint: Should be "1" indicating the musb controller supports
  36. multipoint. This is a MUSB configuration-specific setting.
  37. - mentor,num-eps: Specifies the number of endpoints. This is also a
  38. MUSB configuration-specific setting. Should be set to "16"
  39. - mentor,ram-bits: Specifies the ram address size. Should be set to "12"
  40. - mentor,power: Should be "500". This signifies the controller can supply up to
  41. 500mA when operating in host mode.
  42. - phys: reference to the USB phy
  43. - dmas: specifies the dma channels
  44. - dma-names: specifies the names of the channels. Use "rxN" for receive
  45. and "txN" for transmit endpoints. N specifies the endpoint number.
  46. The controller should have an "usb" alias numbered properly in the alias
  47. node.
  48. DMA
  49. ~~~
  50. - compatible: ti,am3359-cppi41
  51. - reg: offset and length of the following register spaces: USBSS, USB
  52. CPPI DMA Controller, USB CPPI DMA Scheduler, USB Queue Manager
  53. - reg-names: glue, controller, scheduler, queuemgr
  54. - #dma-cells: should be set to 2. The first number represents the
  55. endpoint number (0 … 14 for endpoints 1 … 15 on instance 0 and 15 … 29
  56. for endpoints 1 … 15 on instance 1). The second number is 0 for RX and
  57. 1 for TX transfers.
  58. - #dma-channels: should be set to 30 representing the 15 endpoints for
  59. each USB instance.
  60. Example:
  61. ~~~~~~~~
  62. The following example contains all the nodes as used on am335x-evm:
  63. aliases {
  64. usb0 = &usb0;
  65. usb1 = &usb1;
  66. phy0 = &usb0_phy;
  67. phy1 = &usb1_phy;
  68. };
  69. usb: usb@47400000 {
  70. compatible = "ti,am33xx-usb";
  71. reg = <0x47400000 0x1000>;
  72. ranges;
  73. #address-cells = <1>;
  74. #size-cells = <1>;
  75. ti,hwmods = "usb_otg_hs";
  76. ctrl_mod: control@44e10000 {
  77. compatible = "ti,am335x-usb-ctrl-module";
  78. reg = <0x44e10620 0x10
  79. 0x44e10648 0x4>;
  80. reg-names = "phy_ctrl", "wakeup";
  81. };
  82. usb0_phy: usb-phy@47401300 {
  83. compatible = "ti,am335x-usb-phy";
  84. reg = <0x47401300 0x100>;
  85. reg-names = "phy";
  86. ti,ctrl_mod = <&ctrl_mod>;
  87. };
  88. usb0: usb@47401000 {
  89. compatible = "ti,musb-am33xx";
  90. reg = <0x47401400 0x400
  91. 0x47401000 0x200>;
  92. reg-names = "mc", "control";
  93. interrupts = <18>;
  94. interrupt-names = "mc";
  95. dr_mode = "otg"
  96. mentor,multipoint = <1>;
  97. mentor,num-eps = <16>;
  98. mentor,ram-bits = <12>;
  99. mentor,power = <500>;
  100. phys = <&usb0_phy>;
  101. dmas = <&cppi41dma 0 0 &cppi41dma 1 0
  102. &cppi41dma 2 0 &cppi41dma 3 0
  103. &cppi41dma 4 0 &cppi41dma 5 0
  104. &cppi41dma 6 0 &cppi41dma 7 0
  105. &cppi41dma 8 0 &cppi41dma 9 0
  106. &cppi41dma 10 0 &cppi41dma 11 0
  107. &cppi41dma 12 0 &cppi41dma 13 0
  108. &cppi41dma 14 0 &cppi41dma 0 1
  109. &cppi41dma 1 1 &cppi41dma 2 1
  110. &cppi41dma 3 1 &cppi41dma 4 1
  111. &cppi41dma 5 1 &cppi41dma 6 1
  112. &cppi41dma 7 1 &cppi41dma 8 1
  113. &cppi41dma 9 1 &cppi41dma 10 1
  114. &cppi41dma 11 1 &cppi41dma 12 1
  115. &cppi41dma 13 1 &cppi41dma 14 1>;
  116. dma-names =
  117. "rx1", "rx2", "rx3", "rx4", "rx5", "rx6", "rx7",
  118. "rx8", "rx9", "rx10", "rx11", "rx12", "rx13",
  119. "rx14", "rx15",
  120. "tx1", "tx2", "tx3", "tx4", "tx5", "tx6", "tx7",
  121. "tx8", "tx9", "tx10", "tx11", "tx12", "tx13",
  122. "tx14", "tx15";
  123. };
  124. usb1_phy: usb-phy@47401b00 {
  125. compatible = "ti,am335x-usb-phy";
  126. reg = <0x47401b00 0x100>;
  127. reg-names = "phy";
  128. ti,ctrl_mod = <&ctrl_mod>;
  129. };
  130. usb1: usb@47401800 {
  131. compatible = "ti,musb-am33xx";
  132. reg = <0x47401c00 0x400
  133. 0x47401800 0x200>;
  134. reg-names = "mc", "control";
  135. interrupts = <19>;
  136. interrupt-names = "mc";
  137. dr_mode = "host"
  138. mentor,multipoint = <1>;
  139. mentor,num-eps = <16>;
  140. mentor,ram-bits = <12>;
  141. mentor,power = <500>;
  142. phys = <&usb1_phy>;
  143. dmas = <&cppi41dma 15 0 &cppi41dma 16 0
  144. &cppi41dma 17 0 &cppi41dma 18 0
  145. &cppi41dma 19 0 &cppi41dma 20 0
  146. &cppi41dma 21 0 &cppi41dma 22 0
  147. &cppi41dma 23 0 &cppi41dma 24 0
  148. &cppi41dma 25 0 &cppi41dma 26 0
  149. &cppi41dma 27 0 &cppi41dma 28 0
  150. &cppi41dma 29 0 &cppi41dma 15 1
  151. &cppi41dma 16 1 &cppi41dma 17 1
  152. &cppi41dma 18 1 &cppi41dma 19 1
  153. &cppi41dma 20 1 &cppi41dma 21 1
  154. &cppi41dma 22 1 &cppi41dma 23 1
  155. &cppi41dma 24 1 &cppi41dma 25 1
  156. &cppi41dma 26 1 &cppi41dma 27 1
  157. &cppi41dma 28 1 &cppi41dma 29 1>;
  158. dma-names =
  159. "rx1", "rx2", "rx3", "rx4", "rx5", "rx6", "rx7",
  160. "rx8", "rx9", "rx10", "rx11", "rx12", "rx13",
  161. "rx14", "rx15",
  162. "tx1", "tx2", "tx3", "tx4", "tx5", "tx6", "tx7",
  163. "tx8", "tx9", "tx10", "tx11", "tx12", "tx13",
  164. "tx14", "tx15";
  165. };
  166. cppi41dma: dma-controller@07402000 {
  167. compatible = "ti,am3359-cppi41";
  168. reg = <0x47400000 0x1000
  169. 0x47402000 0x1000
  170. 0x47403000 0x1000
  171. 0x47404000 0x4000>;
  172. reg-names = "glue", "controller", "scheduler", "queuemgr";
  173. interrupts = <17>;
  174. interrupt-names = "glue";
  175. #dma-cells = <2>;
  176. #dma-channels = <30>;
  177. #dma-requests = <256>;
  178. };
  179. };