mcpn765.h 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122
  1. /*
  2. * arch/ppc/platforms/mcpn765.h
  3. *
  4. * Definitions for Motorola MCG MCPN765 cPCI Board.
  5. *
  6. * Author: Mark A. Greer
  7. * mgreer@mvista.com
  8. *
  9. * 2001-2004 (c) MontaVista, Software, Inc. This file is licensed under
  10. * the terms of the GNU General Public License version 2. This program
  11. * is licensed "as is" without any warranty of any kind, whether express
  12. * or implied.
  13. */
  14. /*
  15. * From Processor to PCI:
  16. * PCI Mem Space: 0x80000000 - 0xc0000000 -> 0x80000000 - 0xc0000000 (1 GB)
  17. * PCI I/O Space: 0xfd800000 - 0xfe000000 -> 0x00000000 - 0x00800000 (8 MB)
  18. * Note: Must skip 0xfe000000-0xfe400000 for CONFIG_HIGHMEM/PKMAP area
  19. * MPIC in PCI Mem Space: 0xfe800000 - 0xfe830000 (not all used by MPIC)
  20. *
  21. * From PCI to Processor:
  22. * System Memory: 0x00000000 -> 0x00000000
  23. */
  24. #ifndef __PPC_PLATFORMS_MCPN765_H
  25. #define __PPC_PLATFORMS_MCPN765_H
  26. #include <linux/config.h>
  27. /* PCI Memory space mapping info */
  28. #define MCPN765_PCI_MEM_SIZE 0x40000000U
  29. #define MCPN765_PROC_PCI_MEM_START 0x80000000U
  30. #define MCPN765_PROC_PCI_MEM_END (MCPN765_PROC_PCI_MEM_START + \
  31. MCPN765_PCI_MEM_SIZE - 1)
  32. #define MCPN765_PCI_MEM_START 0x80000000U
  33. #define MCPN765_PCI_MEM_END (MCPN765_PCI_MEM_START + \
  34. MCPN765_PCI_MEM_SIZE - 1)
  35. /* PCI I/O space mapping info */
  36. #define MCPN765_PCI_IO_SIZE 0x00800000U
  37. #define MCPN765_PROC_PCI_IO_START 0xfd800000U
  38. #define MCPN765_PROC_PCI_IO_END (MCPN765_PROC_PCI_IO_START + \
  39. MCPN765_PCI_IO_SIZE - 1)
  40. #define MCPN765_PCI_IO_START 0x00000000U
  41. #define MCPN765_PCI_IO_END (MCPN765_PCI_IO_START + \
  42. MCPN765_PCI_IO_SIZE - 1)
  43. /* System memory mapping info */
  44. #define MCPN765_PCI_DRAM_OFFSET 0x00000000U
  45. #define MCPN765_PCI_PHY_MEM_OFFSET 0x00000000U
  46. #define MCPN765_ISA_MEM_BASE 0x00000000U
  47. #define MCPN765_ISA_IO_BASE MCPN765_PROC_PCI_IO_START
  48. /* Define base addresses for important sets of registers */
  49. #define MCPN765_HAWK_MPIC_BASE 0xfe800000U
  50. #define MCPN765_HAWK_SMC_BASE 0xfef80000U
  51. #define MCPN765_HAWK_PPC_REG_BASE 0xfeff0000U
  52. /* Define MCPN765 board register addresses. */
  53. #define MCPN765_BOARD_STATUS_REG 0xfef88080U
  54. #define MCPN765_BOARD_MODFAIL_REG 0xfef88090U
  55. #define MCPN765_BOARD_MODRST_REG 0xfef880a0U
  56. #define MCPN765_BOARD_TBEN_REG 0xfef880c0U
  57. #define MCPN765_BOARD_GEOGRAPHICAL_REG 0xfef880e8U
  58. #define MCPN765_BOARD_EXT_FEATURE_REG 0xfef880f0U
  59. #define MCPN765_BOARD_LAST_RESET_REG 0xfef880f8U
  60. /* Defines for UART */
  61. /* Define the UART base addresses */
  62. #define MCPN765_SERIAL_1 0xfef88000
  63. #define MCPN765_SERIAL_2 0xfef88200
  64. #define MCPN765_SERIAL_3 0xfef88400
  65. #define MCPN765_SERIAL_4 0xfef88600
  66. #ifdef CONFIG_SERIAL_MANY_PORTS
  67. #define RS_TABLE_SIZE 64
  68. #else
  69. #define RS_TABLE_SIZE 4
  70. #endif
  71. /* Rate for the 1.8432 Mhz clock for the onboard serial chip */
  72. #define BASE_BAUD ( 1843200 / 16 )
  73. #define UART_CLK 1843200
  74. #ifdef CONFIG_SERIAL_DETECT_IRQ
  75. #define STD_COM_FLAGS (ASYNC_BOOT_AUTOCONF|ASYNC_SKIP_TEST|ASYNC_AUTO_IRQ)
  76. #else
  77. #define STD_COM_FLAGS (ASYNC_BOOT_AUTOCONF|ASYNC_SKIP_TEST)
  78. #endif
  79. /* All UART IRQ's are wire-OR'd to IRQ 17 */
  80. #define STD_SERIAL_PORT_DFNS \
  81. { 0, BASE_BAUD, MCPN765_SERIAL_1, 17, STD_COM_FLAGS, /* ttyS0 */\
  82. iomem_base: (u8 *)MCPN765_SERIAL_1, \
  83. iomem_reg_shift: 4, \
  84. io_type: SERIAL_IO_MEM }, \
  85. { 0, BASE_BAUD, MCPN765_SERIAL_2, 17, STD_COM_FLAGS, /* ttyS1 */\
  86. iomem_base: (u8 *)MCPN765_SERIAL_2, \
  87. iomem_reg_shift: 4, \
  88. io_type: SERIAL_IO_MEM }, \
  89. { 0, BASE_BAUD, MCPN765_SERIAL_3, 17, STD_COM_FLAGS, /* ttyS2 */\
  90. iomem_base: (u8 *)MCPN765_SERIAL_3, \
  91. iomem_reg_shift: 4, \
  92. io_type: SERIAL_IO_MEM }, \
  93. { 0, BASE_BAUD, MCPN765_SERIAL_4, 17, STD_COM_FLAGS, /* ttyS3 */\
  94. iomem_base: (u8 *)MCPN765_SERIAL_4, \
  95. iomem_reg_shift: 4, \
  96. io_type: SERIAL_IO_MEM },
  97. #define SERIAL_PORT_DFNS \
  98. STD_SERIAL_PORT_DFNS
  99. /* Define the NVRAM/RTC address strobe & data registers */
  100. #define MCPN765_PHYS_NVRAM_AS0 0xfef880c8U
  101. #define MCPN765_PHYS_NVRAM_AS1 0xfef880d0U
  102. #define MCPN765_PHYS_NVRAM_DATA 0xfef880d8U
  103. extern void mcpn765_find_bridges(void);
  104. #endif /* __PPC_PLATFORMS_MCPN765_H */