pamu.txt 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. Freescale Peripheral Management Access Unit (PAMU) Device Tree Binding
  2. DESCRIPTION
  3. The PAMU is an I/O MMU that provides device-to-memory access control and
  4. address translation capabilities.
  5. Required properties:
  6. - compatible : <string>
  7. First entry is a version-specific string, such as
  8. "fsl,pamu-v1.0". The second is "fsl,pamu".
  9. - ranges : <prop-encoded-array>
  10. A standard property. Utilized to describe the memory mapped
  11. I/O space utilized by the controller. The size should
  12. be set to the total size of the register space of all
  13. physically present PAMU controllers. For example, for
  14. PAMU v1.0, on an SOC that has five PAMU devices, the size
  15. is 0x5000.
  16. - interrupts : <prop-encoded-array>
  17. Interrupt mappings. The first tuple is the normal PAMU
  18. interrupt, used for reporting access violations. The second
  19. is for PAMU hardware errors, such as PAMU operation errors
  20. and ECC errors.
  21. - #address-cells: <u32>
  22. A standard property.
  23. - #size-cells : <u32>
  24. A standard property.
  25. Optional properties:
  26. - reg : <prop-encoded-array>
  27. A standard property. It represents the CCSR registers of
  28. all child PAMUs combined. Include it to provide support
  29. for legacy drivers.
  30. - interrupt-parent : <phandle>
  31. Phandle to interrupt controller
  32. - fsl,portid-mapping : <u32>
  33. The Coherency Subdomain ID Port Mapping Registers and
  34. Snoop ID Port Mapping registers, which are part of the
  35. CoreNet Coherency fabric (CCF), provide a CoreNet
  36. Coherency Subdomain ID/CoreNet Snoop ID to pamu mapping
  37. functions. Certain bits from these registers should be
  38. set if PAMUs should be snooped. This property defines
  39. a bitmask which selects the bits that should be set if
  40. PAMUs should be snooped.
  41. Child nodes:
  42. Each child node represents one PAMU controller. Each SOC device that is
  43. connected to a specific PAMU device should have a "fsl,pamu-phandle" property
  44. that links to the corresponding specific child PAMU controller.
  45. - reg : <prop-encoded-array>
  46. A standard property. Specifies the physical address and
  47. length (relative to the parent 'ranges' property) of this
  48. PAMU controller's configuration registers. The size should
  49. be set to the size of this PAMU controllers's register space.
  50. For PAMU v1.0, this size is 0x1000.
  51. - fsl,primary-cache-geometry
  52. : <prop-encoded-array>
  53. Two cells that specify the geometry of the primary PAMU
  54. cache. The first is the number of cache lines, and the
  55. second is the number of "ways". For direct-mapped caches,
  56. specify a value of 1.
  57. - fsl,secondary-cache-geometry
  58. : <prop-encoded-array>
  59. Two cells that specify the geometry of the secondary PAMU
  60. cache. The first is the number of cache lines, and the
  61. second is the number of "ways". For direct-mapped caches,
  62. specify a value of 1.
  63. Device nodes:
  64. Devices that have LIODNs need to specify links to the parent PAMU controller
  65. (the actual PAMU controller that this device is connected to) and a pointer to
  66. the LIODN register, if applicable.
  67. - fsl,iommu-parent
  68. : <phandle>
  69. Phandle to the single, specific PAMU controller node to which
  70. this device is connect. The PAMU topology is represented in
  71. the device tree to assist code that dynamically determines the
  72. best LIODN values to minimize PAMU cache thrashing.
  73. - fsl,liodn-reg : <prop-encoded-array>
  74. Two cells that specify the location of the LIODN register
  75. for this device. Required for devices that have a single
  76. LIODN. The first cell is a phandle to a node that contains
  77. the registers where the LIODN is to be set. The second is
  78. the offset from the first "reg" resource of the node where
  79. the specific LIODN register is located.
  80. Example:
  81. iommu@20000 {
  82. compatible = "fsl,pamu-v1.0", "fsl,pamu";
  83. reg = <0x20000 0x5000>;
  84. ranges = <0 0x20000 0x5000>;
  85. fsl,portid-mapping = <0xf80000>;
  86. #address-cells = <1>;
  87. #size-cells = <1>;
  88. interrupts = <
  89. 24 2 0 0
  90. 16 2 1 30>;
  91. pamu0: pamu@0 {
  92. reg = <0 0x1000>;
  93. fsl,primary-cache-geometry = <32 1>;
  94. fsl,secondary-cache-geometry = <128 2>;
  95. };
  96. pamu1: pamu@1000 {
  97. reg = <0x1000 0x1000>;
  98. fsl,primary-cache-geometry = <32 1>;
  99. fsl,secondary-cache-geometry = <128 2>;
  100. };
  101. pamu2: pamu@2000 {
  102. reg = <0x2000 0x1000>;
  103. fsl,primary-cache-geometry = <32 1>;
  104. fsl,secondary-cache-geometry = <128 2>;
  105. };
  106. pamu3: pamu@3000 {
  107. reg = <0x3000 0x1000>;
  108. fsl,primary-cache-geometry = <32 1>;
  109. fsl,secondary-cache-geometry = <128 2>;
  110. };
  111. pamu4: pamu@4000 {
  112. reg = <0x4000 0x1000>;
  113. fsl,primary-cache-geometry = <32 1>;
  114. fsl,secondary-cache-geometry = <128 2>;
  115. };
  116. };
  117. guts: global-utilities@e0000 {
  118. compatible = "fsl,qoriq-device-config-1.0";
  119. reg = <0xe0000 0xe00>;
  120. fsl,has-rstcr;
  121. #sleep-cells = <1>;
  122. fsl,liodn-bits = <12>;
  123. };
  124. /include/ "qoriq-dma-0.dtsi"
  125. dma@100300 {
  126. fsl,iommu-parent = <&pamu0>;
  127. fsl,liodn-reg = <&guts 0x584>; /* DMA2LIODNR */
  128. };