memoryOperation.h 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183
  1. /*
  2. * OMAP44xx CM2 instance offset macros
  3. *
  4. * Copyright (C) 2009-2011 Texas Instruments, Inc.
  5. * Copyright (C) 2009-2010 Nokia Corporation
  6. *
  7. * Paul Walmsley (paul@pwsan.com)
  8. * Rajendra Nayak (rnayak@ti.com)
  9. * Benoit Cousson (b-cousson@ti.com)
  10. *
  11. * This file is automatically generated from the OMAP hardware databases.
  12. * We respectfully ask that any modifications to this file be coordinated
  13. * with the public linux-omap@vger.kernel.org mailing list and the
  14. * authors above to ensure that the autogeneration scripts are kept
  15. * up-to-date with the file contents.
  16. *
  17. * This program is free software; you can redistribute it and/or modify
  18. * it under the terms of the GNU General Public License version 2 as
  19. * published by the Free Software Foundation.
  20. *
  21. * XXX This file needs to be updated to align on one of "OMAP4", "OMAP44XX",
  22. * or "OMAP4430".
  23. */
  24. #ifndef __ARCH_ARM_MACH_OMAP2_CM2_44XX_H
  25. #define __ARCH_ARM_MACH_OMAP2_CM2_44XX_H
  26. /* CM2 base address */
  27. #define OMAP4430_CM2_BASE 0x4a008000
  28. #define OMAP44XX_CM2_REGADDR(inst, reg) \
  29. OMAP2_L4_IO_ADDRESS(OMAP4430_CM2_BASE + (inst) + (reg))
  30. /* CM2 instances */
  31. #define OMAP4430_CM2_OCP_SOCKET_INST 0x0000
  32. #define OMAP4430_CM2_CKGEN_INST 0x0100
  33. #define OMAP4430_CM2_ALWAYS_ON_INST 0x0600
  34. #define OMAP4430_CM2_CORE_INST 0x0700
  35. #define OMAP4430_CM2_IVAHD_INST 0x0f00
  36. #define OMAP4430_CM2_CAM_INST 0x1000
  37. #define OMAP4430_CM2_DSS_INST 0x1100
  38. #define OMAP4430_CM2_GFX_INST 0x1200
  39. #define OMAP4430_CM2_L3INIT_INST 0x1300
  40. #define OMAP4430_CM2_L4PER_INST 0x1400
  41. #define OMAP4430_CM2_CEFUSE_INST 0x1600
  42. #define OMAP4430_CM2_RESTORE_INST 0x1e00
  43. #define OMAP4430_CM2_INSTR_INST 0x1f00
  44. /* CM2 clockdomain register offsets (from instance start) */
  45. #define OMAP4430_CM2_ALWAYS_ON_ALWON_CDOFFS 0x0000
  46. #define OMAP4430_CM2_CORE_L3_1_CDOFFS 0x0000
  47. #define OMAP4430_CM2_CORE_L3_2_CDOFFS 0x0100
  48. #define OMAP4430_CM2_CORE_DUCATI_CDOFFS 0x0200
  49. #define OMAP4430_CM2_CORE_SDMA_CDOFFS 0x0300
  50. #define OMAP4430_CM2_CORE_MEMIF_CDOFFS 0x0400
  51. #define OMAP4430_CM2_CORE_D2D_CDOFFS 0x0500
  52. #define OMAP4430_CM2_CORE_L4CFG_CDOFFS 0x0600
  53. #define OMAP4430_CM2_CORE_L3INSTR_CDOFFS 0x0700
  54. #define OMAP4430_CM2_IVAHD_IVAHD_CDOFFS 0x0000
  55. #define OMAP4430_CM2_CAM_CAM_CDOFFS 0x0000
  56. #define OMAP4430_CM2_DSS_DSS_CDOFFS 0x0000
  57. #define OMAP4430_CM2_GFX_GFX_CDOFFS 0x0000
  58. #define OMAP4430_CM2_L3INIT_L3INIT_CDOFFS 0x0000
  59. #define OMAP4430_CM2_L4PER_L4PER_CDOFFS 0x0000
  60. #define OMAP4430_CM2_L4PER_L4SEC_CDOFFS 0x0180
  61. #define OMAP4430_CM2_CEFUSE_CEFUSE_CDOFFS 0x0000
  62. /* CM2 */
  63. /* CM2.OCP_SOCKET_CM2 register offsets */
  64. #define OMAP4_REVISION_CM2_OFFSET 0x0000
  65. #define OMAP4430_REVISION_CM2 OMAP44XX_CM2_REGADDR(OMAP4430_CM2_OCP_SOCKET_INST, 0x0000)
  66. #define OMAP4_CM_CM2_PROFILING_CLKCTRL_OFFSET 0x0040
  67. #define OMAP4430_CM_CM2_PROFILING_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_OCP_SOCKET_INST, 0x0040)
  68. /* CM2.CKGEN_CM2 register offsets */
  69. #define OMAP4_CM_CLKSEL_DUCATI_ISS_ROOT_OFFSET 0x0000
  70. #define OMAP4430_CM_CLKSEL_DUCATI_ISS_ROOT OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0000)
  71. #define OMAP4_CM_CLKSEL_USB_60MHZ_OFFSET 0x0004
  72. #define OMAP4430_CM_CLKSEL_USB_60MHZ OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0004)
  73. #define OMAP4_CM_SCALE_FCLK_OFFSET 0x0008
  74. #define OMAP4430_CM_SCALE_FCLK OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0008)
  75. #define OMAP4_CM_CORE_DVFS_PERF1_OFFSET 0x0010
  76. #define OMAP4430_CM_CORE_DVFS_PERF1 OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0010)
  77. #define OMAP4_CM_CORE_DVFS_PERF2_OFFSET 0x0014
  78. #define OMAP4430_CM_CORE_DVFS_PERF2 OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0014)
  79. #define OMAP4_CM_CORE_DVFS_PERF3_OFFSET 0x0018
  80. #define OMAP4430_CM_CORE_DVFS_PERF3 OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0018)
  81. #define OMAP4_CM_CORE_DVFS_PERF4_OFFSET 0x001c
  82. #define OMAP4430_CM_CORE_DVFS_PERF4 OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x001c)
  83. #define OMAP4_CM_CORE_DVFS_CURRENT_OFFSET 0x0024
  84. #define OMAP4430_CM_CORE_DVFS_CURRENT OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0024)
  85. #define OMAP4_CM_IVA_DVFS_PERF_TESLA_OFFSET 0x0028
  86. #define OMAP4430_CM_IVA_DVFS_PERF_TESLA OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0028)
  87. #define OMAP4_CM_IVA_DVFS_PERF_IVAHD_OFFSET 0x002c
  88. #define OMAP4430_CM_IVA_DVFS_PERF_IVAHD OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x002c)
  89. #define OMAP4_CM_IVA_DVFS_PERF_ABE_OFFSET 0x0030
  90. #define OMAP4430_CM_IVA_DVFS_PERF_ABE OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0030)
  91. #define OMAP4_CM_IVA_DVFS_CURRENT_OFFSET 0x0038
  92. #define OMAP4430_CM_IVA_DVFS_CURRENT OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0038)
  93. #define OMAP4_CM_CLKMODE_DPLL_PER_OFFSET 0x0040
  94. #define OMAP4430_CM_CLKMODE_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0040)
  95. #define OMAP4_CM_IDLEST_DPLL_PER_OFFSET 0x0044
  96. #define OMAP4430_CM_IDLEST_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0044)
  97. #define OMAP4_CM_AUTOIDLE_DPLL_PER_OFFSET 0x0048
  98. #define OMAP4430_CM_AUTOIDLE_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0048)
  99. #define OMAP4_CM_CLKSEL_DPLL_PER_OFFSET 0x004c
  100. #define OMAP4430_CM_CLKSEL_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x004c)
  101. #define OMAP4_CM_DIV_M2_DPLL_PER_OFFSET 0x0050
  102. #define OMAP4430_CM_DIV_M2_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0050)
  103. #define OMAP4_CM_DIV_M3_DPLL_PER_OFFSET 0x0054
  104. #define OMAP4430_CM_DIV_M3_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0054)
  105. #define OMAP4_CM_DIV_M4_DPLL_PER_OFFSET 0x0058
  106. #define OMAP4430_CM_DIV_M4_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0058)
  107. #define OMAP4_CM_DIV_M5_DPLL_PER_OFFSET 0x005c
  108. #define OMAP4430_CM_DIV_M5_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x005c)
  109. #define OMAP4_CM_DIV_M6_DPLL_PER_OFFSET 0x0060
  110. #define OMAP4430_CM_DIV_M6_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0060)
  111. #define OMAP4_CM_DIV_M7_DPLL_PER_OFFSET 0x0064
  112. #define OMAP4430_CM_DIV_M7_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0064)
  113. #define OMAP4_CM_SSC_DELTAMSTEP_DPLL_PER_OFFSET 0x0068
  114. #define OMAP4430_CM_SSC_DELTAMSTEP_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0068)
  115. #define OMAP4_CM_SSC_MODFREQDIV_DPLL_PER_OFFSET 0x006c
  116. #define OMAP4430_CM_SSC_MODFREQDIV_DPLL_PER OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x006c)
  117. #define OMAP4_CM_CLKMODE_DPLL_USB_OFFSET 0x0080
  118. #define OMAP4430_CM_CLKMODE_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0080)
  119. #define OMAP4_CM_IDLEST_DPLL_USB_OFFSET 0x0084
  120. #define OMAP4430_CM_IDLEST_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0084)
  121. #define OMAP4_CM_AUTOIDLE_DPLL_USB_OFFSET 0x0088
  122. #define OMAP4430_CM_AUTOIDLE_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0088)
  123. #define OMAP4_CM_CLKSEL_DPLL_USB_OFFSET 0x008c
  124. #define OMAP4430_CM_CLKSEL_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x008c)
  125. #define OMAP4_CM_DIV_M2_DPLL_USB_OFFSET 0x0090
  126. #define OMAP4430_CM_DIV_M2_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x0090)
  127. #define OMAP4_CM_SSC_DELTAMSTEP_DPLL_USB_OFFSET 0x00a8
  128. #define OMAP4430_CM_SSC_DELTAMSTEP_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00a8)
  129. #define OMAP4_CM_SSC_MODFREQDIV_DPLL_USB_OFFSET 0x00ac
  130. #define OMAP4430_CM_SSC_MODFREQDIV_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00ac)
  131. #define OMAP4_CM_CLKDCOLDO_DPLL_USB_OFFSET 0x00b4
  132. #define OMAP4430_CM_CLKDCOLDO_DPLL_USB OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00b4)
  133. #define OMAP4_CM_CLKMODE_DPLL_UNIPRO_OFFSET 0x00c0
  134. #define OMAP4430_CM_CLKMODE_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00c0)
  135. #define OMAP4_CM_IDLEST_DPLL_UNIPRO_OFFSET 0x00c4
  136. #define OMAP4430_CM_IDLEST_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00c4)
  137. #define OMAP4_CM_AUTOIDLE_DPLL_UNIPRO_OFFSET 0x00c8
  138. #define OMAP4430_CM_AUTOIDLE_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00c8)
  139. #define OMAP4_CM_CLKSEL_DPLL_UNIPRO_OFFSET 0x00cc
  140. #define OMAP4430_CM_CLKSEL_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00cc)
  141. #define OMAP4_CM_DIV_M2_DPLL_UNIPRO_OFFSET 0x00d0
  142. #define OMAP4430_CM_DIV_M2_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00d0)
  143. #define OMAP4_CM_SSC_DELTAMSTEP_DPLL_UNIPRO_OFFSET 0x00e8
  144. #define OMAP4430_CM_SSC_DELTAMSTEP_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00e8)
  145. #define OMAP4_CM_SSC_MODFREQDIV_DPLL_UNIPRO_OFFSET 0x00ec
  146. #define OMAP4430_CM_SSC_MODFREQDIV_DPLL_UNIPRO OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CKGEN_INST, 0x00ec)
  147. /* CM2.ALWAYS_ON_CM2 register offsets */
  148. #define OMAP4_CM_ALWON_CLKSTCTRL_OFFSET 0x0000
  149. #define OMAP4430_CM_ALWON_CLKSTCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_ALWAYS_ON_INST, 0x0000)
  150. #define OMAP4_CM_ALWON_MDMINTC_CLKCTRL_OFFSET 0x0020
  151. #define OMAP4430_CM_ALWON_MDMINTC_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_ALWAYS_ON_INST, 0x0020)
  152. #define OMAP4_CM_ALWON_SR_MPU_CLKCTRL_OFFSET 0x0028
  153. #define OMAP4430_CM_ALWON_SR_MPU_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_ALWAYS_ON_INST, 0x0028)
  154. #define OMAP4_CM_ALWON_SR_IVA_CLKCTRL_OFFSET 0x0030
  155. #define OMAP4430_CM_ALWON_SR_IVA_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_ALWAYS_ON_INST, 0x0030)
  156. #define OMAP4_CM_ALWON_SR_CORE_CLKCTRL_OFFSET 0x0038
  157. #define OMAP4430_CM_ALWON_SR_CORE_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_ALWAYS_ON_INST, 0x0038)
  158. #define OMAP4_CM_ALWON_USBPHY_CLKCTRL_OFFSET 0x0040
  159. #define OMAP4430_CM_ALWON_USBPHY_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_ALWAYS_ON_INST, 0x0040)
  160. /* CM2.CORE_CM2 register offsets */
  161. #define OMAP4_CM_L3_1_CLKSTCTRL_OFFSET 0x0000
  162. #define OMAP4430_CM_L3_1_CLKSTCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CORE_INST, 0x0000)
  163. #define OMAP4_CM_L3_1_DYNAMICDEP_OFFSET 0x0008
  164. #define OMAP4430_CM_L3_1_DYNAMICDEP OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CORE_INST, 0x0008)
  165. #define OMAP4_CM_L3_1_L3_1_CLKCTRL_OFFSET 0x0020
  166. #define OMAP4430_CM_L3_1_L3_1_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CORE_INST, 0x0020)
  167. #define OMAP4_CM_L3_2_CLKSTCTRL_OFFSET 0x0100
  168. #define OMAP4430_CM_L3_2_CLKSTCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CORE_INST, 0x0100)
  169. #define OMAP4_CM_L3_2_DYNAMICDEP_OFFSET 0x0108
  170. #define OMAP4430_CM_L3_2_DYNAMICDEP OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CORE_INST, 0x0108)
  171. #define OMAP4_CM_L3_2_L3_2_CLKCTRL_OFFSET 0x0120
  172. #define OMAP4430_CM_L3_2_L3_2_CLKCTRL OMAP44XX_CM2_REGADDR(OMAP4430_CM2_CORE_INST, 0x0120)
  173. #define OMAP4_CM_L3_2_GPMC_CLKCTRL_OFFSET 0x0128