km-mpc83xx.h 3.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. /*
  2. * Internal Definitions
  3. */
  4. #include <linux/stringify.h>
  5. #define BOOTFLASH_START 0xF0000000
  6. /*
  7. * DDR Setup
  8. */
  9. #define CONFIG_SYS_SDRAM_BASE 0x00000000 /* DDR is system memory */
  10. #define CONFIG_SYS_SDRAM_BASE2 (CONFIG_SYS_SDRAM_BASE + 0x10000000) /* +256M */
  11. #define CONFIG_SYS_DDR_SDRAM_CLK_CNTL (DDR_SDRAM_CLK_CNTL_SS_EN | \
  12. DDR_SDRAM_CLK_CNTL_CLK_ADJUST_05)
  13. #define CFG_83XX_DDR_USES_CS0
  14. /*
  15. * Manually set up DDR parameters
  16. */
  17. #define CONFIG_DDR_II
  18. #define CONFIG_SYS_DDR_SIZE 2048 /* MB */
  19. /*
  20. * The reserved memory
  21. */
  22. #define CONFIG_SYS_MONITOR_BASE CONFIG_SYS_TEXT_BASE /* start of monitor */
  23. #define CONFIG_SYS_FLASH_BASE 0xF0000000
  24. #if (CONFIG_SYS_MONITOR_BASE < CONFIG_SYS_FLASH_BASE)
  25. #define CONFIG_SYS_RAMBOOT
  26. #endif
  27. /* Reserve 768 kB for Mon */
  28. #define CONFIG_SYS_MONITOR_LEN (768 * 1024)
  29. /*
  30. * Initial RAM Base Address Setup
  31. */
  32. #define CONFIG_SYS_INIT_RAM_LOCK
  33. #define CONFIG_SYS_INIT_RAM_ADDR 0xE6000000 /* Initial RAM address */
  34. #define CONFIG_SYS_INIT_RAM_SIZE 0x1000 /* End of used area in RAM */
  35. #define CONFIG_SYS_GBL_DATA_OFFSET (CONFIG_SYS_INIT_RAM_SIZE - \
  36. GENERATED_GBL_DATA_SIZE)
  37. /*
  38. * Init Local Bus Memory Controller:
  39. *
  40. * Bank Bus Machine PortSz Size Device
  41. * ---- --- ------- ------ ----- ------
  42. * 0 Local GPCM 16 bit 256MB FLASH
  43. * 1 Local GPCM 8 bit 128MB GPIO/PIGGY
  44. *
  45. */
  46. /*
  47. * FLASH on the Local Bus
  48. */
  49. #define CONFIG_SYS_FLASH_SIZE 256 /* max FLASH size is 256M */
  50. #define CONFIG_SYS_MAX_FLASH_BANKS 1 /* max num of flash banks */
  51. #define CONFIG_SYS_MAX_FLASH_SECT 512 /* max num of sects on one chip */
  52. #define CONFIG_SYS_FLASH_BANKS_LIST { CONFIG_SYS_FLASH_BASE }
  53. /* I2C */
  54. #define CONFIG_SYS_I2C
  55. #define CONFIG_SYS_NUM_I2C_BUSES 4
  56. #define CONFIG_SYS_I2C_MAX_HOPS 1
  57. #define CONFIG_SYS_I2C_FSL
  58. #define CONFIG_SYS_FSL_I2C_SPEED 200000
  59. #define CONFIG_SYS_FSL_I2C_SLAVE 0x7F
  60. #define CONFIG_SYS_FSL_I2C_OFFSET 0x3000
  61. #define CONFIG_SYS_I2C_OFFSET 0x3000
  62. #define CONFIG_SYS_FSL_I2C2_SPEED 200000
  63. #define CONFIG_SYS_FSL_I2C2_SLAVE 0x7F
  64. #define CONFIG_SYS_FSL_I2C2_OFFSET 0x3100
  65. #define CONFIG_SYS_I2C_BUSES {{0, {I2C_NULL_HOP} }, \
  66. {0, {{I2C_MUX_PCA9547, 0x70, 2} } }, \
  67. {0, {{I2C_MUX_PCA9547, 0x70, 1} } }, \
  68. {1, {I2C_NULL_HOP} } }
  69. #if defined(CONFIG_CMD_NAND)
  70. #define CONFIG_NAND_KMETER1
  71. #define CONFIG_SYS_MAX_NAND_DEVICE 1
  72. #define CONFIG_SYS_NAND_BASE CONFIG_SYS_KMBEC_FPGA_BASE
  73. #endif
  74. /*
  75. * For booting Linux, the board info and command line data
  76. * have to be in the first 8 MB of memory, since this is
  77. * the maximum mapped by the Linux kernel during initialization.
  78. */
  79. #define CONFIG_SYS_BOOTMAPSZ (8 << 20)
  80. /*
  81. * Environment
  82. */
  83. #ifndef CONFIG_SYS_RAMBOOT
  84. /* Address and size of Redundant Environment Sector */
  85. #endif /* CFG_SYS_RAMBOOT */
  86. /*
  87. * Environment Configuration
  88. */
  89. #ifndef CONFIG_KM_DEF_ENV /* if not set by keymile-common.h */
  90. #define CONFIG_KM_DEF_ENV "km-common=empty\0"
  91. #endif
  92. #ifndef CONFIG_KM_DEF_ARCH
  93. #define CONFIG_KM_DEF_ARCH "arch=ppc_82xx\0"
  94. #endif
  95. #define CONFIG_EXTRA_ENV_SETTINGS \
  96. CONFIG_KM_DEF_ENV \
  97. CONFIG_KM_DEF_ARCH \
  98. "newenv=" \
  99. "prot off " __stringify(CONFIG_ENV_ADDR) " +0x40000 && " \
  100. "era " __stringify(CONFIG_ENV_ADDR) " +0x40000\0" \
  101. "unlock=yes\0" \
  102. ""
  103. #if defined(CONFIG_UEC_ETH)
  104. #define CONFIG_HAS_ETH0
  105. #endif
  106. /*
  107. * QE UEC ethernet configuration
  108. */
  109. #define CONFIG_UEC_ETH
  110. #define CONFIG_ETHPRIME "UEC0"