dataPreprocessingThread.h 6.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197
  1. /*
  2. * Copyright 2008 Cavium Networks
  3. *
  4. * This file is free software; you can redistribute it and/or modify
  5. * it under the terms of the GNU General Public License, Version 2, as
  6. * published by the Free Software Foundation.
  7. */
  8. #ifndef __MACH_BOARD_CNS3XXXH
  9. #define __MACH_BOARD_CNS3XXXH
  10. /*
  11. * Memory map
  12. */
  13. #define CNS3XXX_FLASH_BASE 0x10000000 /* Flash/SRAM Memory Bank 0 */
  14. #define CNS3XXX_FLASH_SIZE SZ_256M
  15. #define CNS3XXX_DDR2SDRAM_BASE 0x20000000 /* DDR2 SDRAM Memory */
  16. #define CNS3XXX_SPI_FLASH_BASE 0x60000000 /* SPI Serial Flash Memory */
  17. #define CNS3XXX_SWITCH_BASE 0x70000000 /* Switch and HNAT Control */
  18. #define CNS3XXX_SWITCH_BASE_VIRT 0xFFF00000
  19. #define CNS3XXX_PPE_BASE 0x70001000 /* HANT */
  20. #define CNS3XXX_PPE_BASE_VIRT 0xFFF50000
  21. #define CNS3XXX_EMBEDDED_SRAM_BASE 0x70002000 /* HANT Embedded SRAM */
  22. #define CNS3XXX_EMBEDDED_SRAM_BASE_VIRT 0xFFF60000
  23. #define CNS3XXX_SSP_BASE 0x71000000 /* Synchronous Serial Port - SPI/PCM/I2C */
  24. #define CNS3XXX_SSP_BASE_VIRT 0xFFF01000
  25. #define CNS3XXX_DMC_BASE 0x72000000 /* DMC Control (DDR2 SDRAM) */
  26. #define CNS3XXX_DMC_BASE_VIRT 0xFFF02000
  27. #define CNS3XXX_SMC_BASE 0x73000000 /* SMC Control */
  28. #define CNS3XXX_SMC_BASE_VIRT 0xFFF03000
  29. #define SMC_MEMC_STATUS_OFFSET 0x000
  30. #define SMC_MEMIF_CFG_OFFSET 0x004
  31. #define SMC_MEMC_CFG_SET_OFFSET 0x008
  32. #define SMC_MEMC_CFG_CLR_OFFSET 0x00C
  33. #define SMC_DIRECT_CMD_OFFSET 0x010
  34. #define SMC_SET_CYCLES_OFFSET 0x014
  35. #define SMC_SET_OPMODE_OFFSET 0x018
  36. #define SMC_REFRESH_PERIOD_0_OFFSET 0x020
  37. #define SMC_REFRESH_PERIOD_1_OFFSET 0x024
  38. #define SMC_SRAM_CYCLES0_0_OFFSET 0x100
  39. #define SMC_NAND_CYCLES0_0_OFFSET 0x100
  40. #define SMC_OPMODE0_0_OFFSET 0x104
  41. #define SMC_SRAM_CYCLES0_1_OFFSET 0x120
  42. #define SMC_NAND_CYCLES0_1_OFFSET 0x120
  43. #define SMC_OPMODE0_1_OFFSET 0x124
  44. #define SMC_USER_STATUS_OFFSET 0x200
  45. #define SMC_USER_CONFIG_OFFSET 0x204
  46. #define SMC_ECC_STATUS_OFFSET 0x300
  47. #define SMC_ECC_MEMCFG_OFFSET 0x304
  48. #define SMC_ECC_MEMCOMMAND1_OFFSET 0x308
  49. #define SMC_ECC_MEMCOMMAND2_OFFSET 0x30C
  50. #define SMC_ECC_ADDR0_OFFSET 0x310
  51. #define SMC_ECC_ADDR1_OFFSET 0x314
  52. #define SMC_ECC_VALUE0_OFFSET 0x318
  53. #define SMC_ECC_VALUE1_OFFSET 0x31C
  54. #define SMC_ECC_VALUE2_OFFSET 0x320
  55. #define SMC_ECC_VALUE3_OFFSET 0x324
  56. #define SMC_PERIPH_ID_0_OFFSET 0xFE0
  57. #define SMC_PERIPH_ID_1_OFFSET 0xFE4
  58. #define SMC_PERIPH_ID_2_OFFSET 0xFE8
  59. #define SMC_PERIPH_ID_3_OFFSET 0xFEC
  60. #define SMC_PCELL_ID_0_OFFSET 0xFF0
  61. #define SMC_PCELL_ID_1_OFFSET 0xFF4
  62. #define SMC_PCELL_ID_2_OFFSET 0xFF8
  63. #define SMC_PCELL_ID_3_OFFSET 0xFFC
  64. #define CNS3XXX_GPIOA_BASE 0x74000000 /* GPIO port A */
  65. #define CNS3XXX_GPIOA_BASE_VIRT 0xFFF04000
  66. #define CNS3XXX_GPIOB_BASE 0x74800000 /* GPIO port B */
  67. #define CNS3XXX_GPIOB_BASE_VIRT 0xFFF05000
  68. #define CNS3XXX_RTC_BASE 0x75000000 /* Real Time Clock */
  69. #define CNS3XXX_RTC_BASE_VIRT 0xFFF06000
  70. #define RTC_SEC_OFFSET 0x00
  71. #define RTC_MIN_OFFSET 0x04
  72. #define RTC_HOUR_OFFSET 0x08
  73. #define RTC_DAY_OFFSET 0x0C
  74. #define RTC_SEC_ALM_OFFSET 0x10
  75. #define RTC_MIN_ALM_OFFSET 0x14
  76. #define RTC_HOUR_ALM_OFFSET 0x18
  77. #define RTC_REC_OFFSET 0x1C
  78. #define RTC_CTRL_OFFSET 0x20
  79. #define RTC_INTR_STS_OFFSET 0x34
  80. #define CNS3XXX_MISC_BASE 0x76000000 /* Misc Control */
  81. #define CNS3XXX_MISC_BASE_VIRT 0xFB000000 /* Misc Control */
  82. #define CNS3XXX_PM_BASE 0x77000000 /* Power Management Control */
  83. #define CNS3XXX_PM_BASE_VIRT 0xFB001000
  84. #define PM_CLK_GATE_OFFSET 0x00
  85. #define PM_SOFT_RST_OFFSET 0x04
  86. #define PM_HS_CFG_OFFSET 0x08
  87. #define PM_CACTIVE_STA_OFFSET 0x0C
  88. #define PM_PWR_STA_OFFSET 0x10
  89. #define PM_SYS_CLK_CTRL_OFFSET 0x14
  90. #define PM_PLL_LCD_I2S_CTRL_OFFSET 0x18
  91. #define PM_PLL_HM_PD_OFFSET 0x1C
  92. #define CNS3XXX_UART0_BASE 0x78000000 /* UART 0 */
  93. #define CNS3XXX_UART0_BASE_VIRT 0xFB002000
  94. #define CNS3XXX_UART1_BASE 0x78400000 /* UART 1 */
  95. #define CNS3XXX_UART1_BASE_VIRT 0xFFF0A000
  96. #define CNS3XXX_UART2_BASE 0x78800000 /* UART 2 */
  97. #define CNS3XXX_UART2_BASE_VIRT 0xFFF0B000
  98. #define CNS3XXX_DMAC_BASE 0x79000000 /* Generic DMA Control */
  99. #define CNS3XXX_DMAC_BASE_VIRT 0xFFF0D000
  100. #define CNS3XXX_CORESIGHT_BASE 0x7A000000 /* CoreSight */
  101. #define CNS3XXX_CORESIGHT_BASE_VIRT 0xFFF0E000
  102. #define CNS3XXX_CRYPTO_BASE 0x7B000000 /* Crypto */
  103. #define CNS3XXX_CRYPTO_BASE_VIRT 0xFFF0F000
  104. #define CNS3XXX_I2S_BASE 0x7C000000 /* I2S */
  105. #define CNS3XXX_I2S_BASE_VIRT 0xFFF10000
  106. #define CNS3XXX_TIMER1_2_3_BASE 0x7C800000 /* Timer */
  107. #define CNS3XXX_TIMER1_2_3_BASE_VIRT 0xFB003000
  108. #define TIMER1_COUNTER_OFFSET 0x00
  109. #define TIMER1_AUTO_RELOAD_OFFSET 0x04
  110. #define TIMER1_MATCH_V1_OFFSET 0x08
  111. #define TIMER1_MATCH_V2_OFFSET 0x0C
  112. #define TIMER2_COUNTER_OFFSET 0x10
  113. #define TIMER2_AUTO_RELOAD_OFFSET 0x14
  114. #define TIMER2_MATCH_V1_OFFSET 0x18
  115. #define TIMER2_MATCH_V2_OFFSET 0x1C
  116. #define TIMER1_2_CONTROL_OFFSET 0x30
  117. #define TIMER1_2_INTERRUPT_STATUS_OFFSET 0x34
  118. #define TIMER1_2_INTERRUPT_MASK_OFFSET 0x38
  119. #define TIMER_FREERUN_OFFSET 0x40
  120. #define TIMER_FREERUN_CONTROL_OFFSET 0x44
  121. #define CNS3XXX_HCIE_BASE 0x7D000000 /* HCIE Control */
  122. #define CNS3XXX_HCIE_BASE_VIRT 0xFFF30000
  123. #define CNS3XXX_RAID_BASE 0x7E000000 /* RAID Control */
  124. #define CNS3XXX_RAID_BASE_VIRT 0xFFF12000
  125. #define CNS3XXX_AXI_IXC_BASE 0x7F000000 /* AXI IXC */
  126. #define CNS3XXX_AXI_IXC_BASE_VIRT 0xFFF13000
  127. #define CNS3XXX_CLCD_BASE 0x80000000 /* LCD Control */
  128. #define CNS3XXX_CLCD_BASE_VIRT 0xFFF14000
  129. #define CNS3XXX_USBOTG_BASE 0x81000000 /* USB OTG Control */
  130. #define CNS3XXX_USBOTG_BASE_VIRT 0xFFF15000
  131. #define CNS3XXX_USB_BASE 0x82000000 /* USB Host Control */
  132. #define CNS3XXX_SATA2_BASE 0x83000000 /* SATA */
  133. #define CNS3XXX_SATA2_SIZE SZ_16M
  134. #define CNS3XXX_SATA2_BASE_VIRT 0xFFF17000
  135. #define CNS3XXX_CAMERA_BASE 0x84000000 /* Camera Interface */
  136. #define CNS3XXX_CAMERA_BASE_VIRT 0xFFF18000
  137. #define CNS3XXX_SDIO_BASE 0x85000000 /* SDIO */
  138. #define CNS3XXX_SDIO_BASE_VIRT 0xFFF19000
  139. #define CNS3XXX_I2S_TDM_BASE 0x86000000 /* I2S TDM */
  140. #define CNS3XXX_I2S_TDM_BASE_VIRT 0xFFF1A000
  141. #define CNS3XXX_2DG_BASE 0x87000000 /* 2D Graphic Control */
  142. #define CNS3XXX_2DG_BASE_VIRT 0xFFF1B000
  143. #define CNS3XXX_USB_OHCI_BASE 0x88000000 /* USB OHCI */
  144. #define CNS3XXX_L2C_BASE 0x92000000 /* L2 Cache Control */
  145. #define CNS3XXX_L2C_BASE_VIRT 0xFFF27000
  146. #define CNS3XXX_PCIE0_MEM_BASE 0xA0000000 /* PCIe Port 0 IO/Memory Space */
  147. #define CNS3XXX_PCIE0_MEM_BASE_VIRT 0xE0000000
  148. #define CNS3XXX_PCIE0_HOST_BASE 0xAB000000 /* PCIe Port 0 RC Base */
  149. #define CNS3XXX_PCIE0_HOST_BASE_VIRT 0xE1000000
  150. #define CNS3XXX_PCIE0_IO_BASE 0xAC000000 /* PCIe Port 0 */
  151. #define CNS3XXX_PCIE0_IO_BASE_VIRT 0xE2000000