PKUnity.h 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108
  1. /*
  2. * linux/arch/unicore32/include/mach/PKUnity.h
  3. *
  4. * Code specific to PKUnity SoC and UniCore ISA
  5. *
  6. * Copyright (C) 2001-2010 GUAN Xue-tao
  7. *
  8. * This program is free software; you can redistribute it and/or modify
  9. * it under the terms of the GNU General Public License version 2 as
  10. * published by the Free Software Foundation.
  11. */
  12. /* Be sure that virtual mapping is defined right */
  13. #ifndef __MACH_PUV3_HARDWARE_H__
  14. #error You must include hardware.h not PKUnity.h
  15. #endif
  16. #include "bitfield.h"
  17. /*
  18. * Memory Definitions
  19. */
  20. #define PKUNITY_SDRAM_BASE 0x00000000 /* 0x00000000 - 0x7FFFFFFF 2GB */
  21. #define PKUNITY_MMIO_BASE 0x80000000 /* 0x80000000 - 0xFFFFFFFF 2GB */
  22. /*
  23. * PKUNITY Memory Map Addresses: 0x0D000000 - 0x0EFFFFFF (32MB)
  24. * 0x0D000000 - 0x0DFFFFFF 16MB: for UVC
  25. * 0x0E000000 - 0x0EFFFFFF 16MB: for UNIGFX
  26. */
  27. #define PKUNITY_UVC_MMAP_BASE 0x0D000000
  28. #define PKUNITY_UVC_MMAP_SIZE 0x01000000 /* 16MB */
  29. #define PKUNITY_UNIGFX_MMAP_BASE 0x0E000000
  30. #define PKUNITY_UNIGFX_MMAP_SIZE 0x01000000 /* 16MB */
  31. /*
  32. * PKUNITY System Bus Addresses (PCI): 0x80000000 - 0xBFFFFFFF (1GB)
  33. * 0x80000000 - 0x8000000B 12B PCI Configuration regs
  34. * 0x80010000 - 0x80010250 592B PCI Bridge Base
  35. * 0x80030000 - 0x8003FFFF 64KB PCI Legacy IO
  36. * 0x90000000 - 0x97FFFFFF 128MB PCI AHB-PCI MEM-mapping
  37. * 0x98000000 - 0x9FFFFFFF 128MB PCI PCI-AHB MEM-mapping
  38. */
  39. #define PKUNITY_PCI_BASE io_p2v(0x80000000) /* 0x80000000 - 0xBFFFFFFF 1GB */
  40. #include "regs-pci.h"
  41. #define PKUNITY_PCICFG_BASE (PKUNITY_PCI_BASE + 0x0)
  42. #define PKUNITY_PCIBRI_BASE (PKUNITY_PCI_BASE + 0x00010000)
  43. #define PKUNITY_PCILIO_BASE (PKUNITY_PCI_BASE + 0x00030000)
  44. #define PKUNITY_PCIMEM_BASE (PKUNITY_PCI_BASE + 0x10000000)
  45. #define PKUNITY_PCIAHB_BASE (PKUNITY_PCI_BASE + 0x18000000)
  46. /*
  47. * PKUNITY System Bus Addresses (AHB): 0xC0000000 - 0xEDFFFFFF (640MB)
  48. */
  49. #define PKUNITY_AHB_BASE io_p2v(0xC0000000)
  50. /* AHB-0 is DDR2 SDRAM */
  51. /* AHB-1 is PCI Space */
  52. #define PKUNITY_ARBITER_BASE (PKUNITY_AHB_BASE + 0x000000) /* AHB-2 */
  53. #define PKUNITY_DDR2CTRL_BASE (PKUNITY_AHB_BASE + 0x100000) /* AHB-3 */
  54. #define PKUNITY_DMAC_BASE (PKUNITY_AHB_BASE + 0x200000) /* AHB-4 */
  55. #include "regs-dmac.h"
  56. #define PKUNITY_UMAL_BASE (PKUNITY_AHB_BASE + 0x300000) /* AHB-5 */
  57. #include "regs-umal.h"
  58. #define PKUNITY_USB_BASE (PKUNITY_AHB_BASE + 0x400000) /* AHB-6 */
  59. #define PKUNITY_SATA_BASE (PKUNITY_AHB_BASE + 0x500000) /* AHB-7 */
  60. #define PKUNITY_SMC_BASE (PKUNITY_AHB_BASE + 0x600000) /* AHB-8 */
  61. /* AHB-9 is for APB bridge */
  62. #define PKUNITY_MME_BASE (PKUNITY_AHB_BASE + 0x700000) /* AHB-10 */
  63. #define PKUNITY_UNIGFX_BASE (PKUNITY_AHB_BASE + 0x800000) /* AHB-11 */
  64. #include "regs-unigfx.h"
  65. #define PKUNITY_NAND_BASE (PKUNITY_AHB_BASE + 0x900000) /* AHB-12 */
  66. #include "regs-nand.h"
  67. #define PKUNITY_H264D_BASE (PKUNITY_AHB_BASE + 0xA00000) /* AHB-13 */
  68. #define PKUNITY_H264E_BASE (PKUNITY_AHB_BASE + 0xB00000) /* AHB-14 */
  69. /*
  70. * PKUNITY Peripheral Bus Addresses (APB): 0xEE000000 - 0xEFFFFFFF (128MB)
  71. */
  72. #define PKUNITY_APB_BASE io_p2v(0xEE000000)
  73. #define PKUNITY_UART0_BASE (PKUNITY_APB_BASE + 0x000000) /* APB-0 */
  74. #define PKUNITY_UART1_BASE (PKUNITY_APB_BASE + 0x100000) /* APB-1 */
  75. #include "regs-uart.h"
  76. #define PKUNITY_I2C_BASE (PKUNITY_APB_BASE + 0x200000) /* APB-2 */
  77. #include "regs-i2c.h"
  78. #define PKUNITY_SPI_BASE (PKUNITY_APB_BASE + 0x300000) /* APB-3 */
  79. #include "regs-spi.h"
  80. #define PKUNITY_AC97_BASE (PKUNITY_APB_BASE + 0x400000) /* APB-4 */
  81. #include "regs-ac97.h"
  82. #define PKUNITY_GPIO_BASE (PKUNITY_APB_BASE + 0x500000) /* APB-5 */
  83. #include "regs-gpio.h"
  84. #define PKUNITY_INTC_BASE (PKUNITY_APB_BASE + 0x600000) /* APB-6 */
  85. #include "regs-intc.h"
  86. #define PKUNITY_RTC_BASE (PKUNITY_APB_BASE + 0x700000) /* APB-7 */
  87. #include "regs-rtc.h"
  88. #define PKUNITY_OST_BASE (PKUNITY_APB_BASE + 0x800000) /* APB-8 */
  89. #include "regs-ost.h"
  90. #define PKUNITY_RESETC_BASE (PKUNITY_APB_BASE + 0x900000) /* APB-9 */
  91. #include "regs-resetc.h"
  92. #define PKUNITY_PM_BASE (PKUNITY_APB_BASE + 0xA00000) /* APB-10 */
  93. #include "regs-pm.h"
  94. #define PKUNITY_PS2_BASE (PKUNITY_APB_BASE + 0xB00000) /* APB-11 */
  95. #include "regs-ps2.h"
  96. #define PKUNITY_SDC_BASE (PKUNITY_APB_BASE + 0xC00000) /* APB-12 */
  97. #include "regs-sdc.h"