bf609-ezkit.h 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172
  1. /*
  2. * U-boot - Configuration file for BF609 EZ-Kit board
  3. */
  4. #ifndef __CONFIG_BF609_EZKIT_H__
  5. #define __CONFIG_BF609_EZKIT_H__
  6. #include <asm/config-pre.h>
  7. /*
  8. * Processor Settings
  9. */
  10. #define CONFIG_BFIN_CPU bf609-0.0
  11. #define CONFIG_BFIN_BOOT_MODE BFIN_BOOT_PARA
  12. /* For ez-board version 1.0, else undef this */
  13. #define CONFIG_BFIN_BOARD_VERSION_1_0
  14. /*
  15. * Clock Settings
  16. * CCLK = (CLKIN * VCO_MULT) / CCLK_DIV
  17. * SCLK = (CLKIN * VCO_MULT) / SYSCLK_DIV
  18. * SCLK0 = SCLK / SCLK0_DIV
  19. * SCLK1 = SCLK / SCLK1_DIV
  20. */
  21. /* CONFIG_CLKIN_HZ is any value in Hz */
  22. #define CONFIG_CLKIN_HZ (25000000)
  23. /* CLKIN_HALF controls the DF bit in PLL_CTL 0 = CLKIN */
  24. /* 1 = CLKIN / 2 */
  25. #define CONFIG_CLKIN_HALF (0)
  26. /* VCO_MULT controls the MSEL (multiplier) bits in PLL_CTL */
  27. /* Values can range from 0-127 (where 0 means 128) */
  28. #define CONFIG_VCO_MULT (20)
  29. /* CCLK_DIV controls the core clock divider */
  30. /* Values can range from 0-31 (where 0 means 32) */
  31. #define CONFIG_CCLK_DIV (1)
  32. /* SCLK_DIV controls the system clock divider */
  33. /* Values can range from 0-31 (where 0 means 32) */
  34. #define CONFIG_SCLK_DIV (4)
  35. /* Values can range from 0-7 (where 0 means 8) */
  36. #define CONFIG_SCLK0_DIV (1)
  37. #define CONFIG_SCLK1_DIV (1)
  38. /* DCLK_DIV controls the DDR clock divider */
  39. /* Values can range from 0-31 (where 0 means 32) */
  40. #define CONFIG_DCLK_DIV (2)
  41. /* OCLK_DIV controls the output clock divider */
  42. /* Values can range from 0-127 (where 0 means 128) */
  43. #define CONFIG_OCLK_DIV (16)
  44. /*
  45. * Memory Settings
  46. */
  47. #define CONFIG_MEM_SIZE 128
  48. #define CONFIG_SMC_GCTL_VAL 0x00000010
  49. #define CONFIG_SMC_B0CTL_VAL 0x01007011
  50. #define CONFIG_SMC_B0TIM_VAL 0x08170977
  51. #define CONFIG_SMC_B0ETIM_VAL 0x00092231
  52. #define CONFIG_SYS_MONITOR_LEN (768 * 1024)
  53. #define CONFIG_SYS_MALLOC_LEN (512 * 1024)
  54. #define CONFIG_HW_WATCHDOG
  55. /*
  56. * Network Settings
  57. */
  58. #define ADI_CMDS_NETWORK
  59. #define CONFIG_NETCONSOLE
  60. #define CONFIG_NET_MULTI
  61. #define CONFIG_HOSTNAME "bf609-ezkit"
  62. #define CONFIG_DESIGNWARE_ETH
  63. #define CONFIG_DW_PORTS 1
  64. #define CONFIG_DW_AUTONEG
  65. #define CONFIG_DW_ALTDESCRIPTOR
  66. #define CONFIG_CMD_NET
  67. #define CONFIG_CMD_MII
  68. #define CONFIG_MII
  69. /* i2c Settings */
  70. #define CONFIG_BFIN_TWI_I2C
  71. #define CONFIG_HARD_I2C
  72. /*
  73. * Flash Settings
  74. */
  75. #undef CONFIG_CMD_IMLS
  76. #undef CONFIG_CMD_JFFS2
  77. #define CONFIG_SYS_FLASH_CFI_WIDTH 2
  78. #define CONFIG_FLASH_CFI_DRIVER
  79. #define CONFIG_SYS_FLASH_BASE 0xb0000000
  80. #define CONFIG_SYS_FLASH_CFI
  81. #define CONFIG_SYS_FLASH_PROTECTION
  82. #define CONFIG_SYS_MAX_FLASH_BANKS 1
  83. #define CONFIG_SYS_MAX_FLASH_SECT 131
  84. #define CONFIG_CFI_FLASH_USE_WEAK_ACCESSORS
  85. /*
  86. * SPI Settings
  87. */
  88. #define CONFIG_BFIN_SPI6XX
  89. #define CONFIG_ENV_SPI_MAX_HZ 25000000
  90. #define CONFIG_SF_DEFAULT_SPEED 25000000
  91. #define CONFIG_SPI_FLASH
  92. #define CONFIG_SPI_FLASH_ALL
  93. /*
  94. * Env Storage Settings
  95. */
  96. #if (CONFIG_BFIN_BOOT_MODE == BFIN_BOOT_SPI_MASTER)
  97. #define CONFIG_ENV_IS_IN_SPI_FLASH
  98. #define CONFIG_ENV_OFFSET 0x10000
  99. #define CONFIG_ENV_SIZE 0x2000
  100. #define CONFIG_ENV_SECT_SIZE 0x10000
  101. #define CONFIG_ENV_IS_EMBEDDED_IN_LDR
  102. #elif (CONFIG_BFIN_BOOT_MODE == BFIN_BOOT_NAND)
  103. #define CONFIG_ENV_IS_IN_NAND
  104. #define CONFIG_ENV_OFFSET 0x60000
  105. #define CONFIG_ENV_SIZE 0x20000
  106. #else
  107. #define CONFIG_ENV_IS_IN_FLASH
  108. #define CONFIG_ENV_ADDR (CONFIG_SYS_FLASH_BASE + CONFIG_ENV_OFFSET)
  109. #define CONFIG_ENV_OFFSET 0x8000
  110. #define CONFIG_ENV_SIZE 0x8000
  111. #define CONFIG_ENV_SECT_SIZE 0x8000
  112. #define CONFIG_ENV_IS_EMBEDDED_IN_LDR
  113. #endif
  114. #define FLASHBOOT_ENV_SETTINGS "flashboot=bootm 0xB0100000\0"
  115. /*
  116. * SDH Settings
  117. */
  118. #define CONFIG_GENERIC_MMC
  119. #define CONFIG_MMC
  120. #define CONFIG_BFIN_SDH
  121. /*
  122. * Misc Settings
  123. */
  124. #define CONFIG_BOARD_EARLY_INIT_F
  125. #define CONFIG_UART_CONSOLE 0
  126. #define CONFIG_CMD_MEMORY
  127. #define CONFIG_CMD_SOFTSWITCH
  128. #define CONFIG_SYS_MEMTEST_END (CONFIG_STACKBASE - 20*1024*1024 + 4)
  129. #define CONFIG_BFIN_SOFT_SWITCH
  130. #define CONFIG_ADI_GPIO2
  131. #if 0
  132. #define CONFIG_UART_MEM 1024
  133. #undef CONFIG_UART_CONSOLE
  134. #undef CONFIG_JTAG_CONSOLE
  135. #undef CONFIG_UART_CONSOLE_IS_JTAG
  136. #endif
  137. #define CONFIG_BOARD_SIZE_LIMIT $$((512 * 1024))
  138. /*
  139. * Run core 1 from L1 SRAM start address when init uboot on core 0
  140. */
  141. /* #define CONFIG_CORE1_RUN 1 */
  142. /*
  143. * Pull in common ADI header for remaining command/environment setup
  144. */
  145. #include <configs/bfin_adi_common.h>
  146. #endif