omap3_igep00x0.h 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160
  1. /*
  2. * Common configuration settings for IGEP technology based boards
  3. *
  4. * (C) Copyright 2012
  5. * ISEE 2007 SL, <www.iseebcn.com>
  6. *
  7. * SPDX-License-Identifier: GPL-2.0+
  8. */
  9. #ifndef __IGEP00X0_H
  10. #define __IGEP00X0_H
  11. #define CONFIG_NR_DRAM_BANKS 2
  12. #define CONFIG_NAND
  13. #include <configs/ti_omap3_common.h>
  14. #include <asm/mach-types.h>
  15. /*
  16. * We are only ever GP parts and will utilize all of the "downloaded image"
  17. * area in SRAM which starts at 0x40200000 and ends at 0x4020FFFF (64KB).
  18. */
  19. #undef CONFIG_SPL_TEXT_BASE
  20. #define CONFIG_SPL_TEXT_BASE 0x40200000
  21. #define CONFIG_MISC_INIT_R
  22. #define CONFIG_REVISION_TAG 1
  23. /* Status LED available for IGEP0020 and IGEP0030 but not IGEP0032 */
  24. #if (CONFIG_MACH_TYPE != MACH_TYPE_IGEP0032)
  25. #define CONFIG_STATUS_LED
  26. #define CONFIG_BOARD_SPECIFIC_LED
  27. #define CONFIG_GPIO_LED
  28. #if (CONFIG_MACH_TYPE == MACH_TYPE_IGEP0020)
  29. #define RED_LED_GPIO 27
  30. #elif (CONFIG_MACH_TYPE == MACH_TYPE_IGEP0030)
  31. #define RED_LED_GPIO 16
  32. #else
  33. #error "status LED not defined for this machine."
  34. #endif
  35. #define RED_LED_DEV 0
  36. #define STATUS_LED_BIT RED_LED_GPIO
  37. #define STATUS_LED_STATE STATUS_LED_ON
  38. #define STATUS_LED_PERIOD (CONFIG_SYS_HZ / 2)
  39. #define STATUS_LED_BOOT RED_LED_DEV
  40. #endif
  41. /* GPIO banks */
  42. #define CONFIG_OMAP3_GPIO_3 /* GPIO64 .. 95 is in GPIO bank 3 */
  43. #define CONFIG_OMAP3_GPIO_5 /* GPIO128..159 is in GPIO bank 5 */
  44. #define CONFIG_OMAP3_GPIO_6 /* GPIO160..191 is in GPIO bank 6 */
  45. /* USB */
  46. #define CONFIG_USB_MUSB_UDC 1
  47. #define CONFIG_USB_OMAP3 1
  48. #define CONFIG_TWL4030_USB 1
  49. /* USB device configuration */
  50. #define CONFIG_USB_DEVICE 1
  51. #define CONFIG_USB_TTY 1
  52. /* Change these to suit your needs */
  53. #define CONFIG_USBD_VENDORID 0x0451
  54. #define CONFIG_USBD_PRODUCTID 0x5678
  55. #define CONFIG_USBD_MANUFACTURER "Texas Instruments"
  56. #define CONFIG_USBD_PRODUCT_NAME "IGEP"
  57. #define CONFIG_CMD_MTDPARTS
  58. #define CONFIG_CMD_ONENAND
  59. #ifndef CONFIG_SPL_BUILD
  60. /* Environment */
  61. #define ENV_DEVICE_SETTINGS \
  62. "stdin=serial\0" \
  63. "stdout=serial\0" \
  64. "stderr=serial\0"
  65. #define MEM_LAYOUT_SETTINGS \
  66. DEFAULT_LINUX_BOOT_ENV \
  67. "scriptaddr=0x87E00000\0" \
  68. "pxefile_addr_r=0x87F00000\0"
  69. #define BOOT_TARGET_DEVICES(func) \
  70. func(MMC, mmc, 0)
  71. #include <config_distro_bootcmd.h>
  72. #define CONFIG_EXTRA_ENV_SETTINGS \
  73. ENV_DEVICE_SETTINGS \
  74. MEM_LAYOUT_SETTINGS \
  75. BOOTENV
  76. #endif
  77. /*
  78. * SMSC911x Ethernet
  79. */
  80. #if defined(CONFIG_CMD_NET)
  81. #define CONFIG_SMC911X
  82. #define CONFIG_SMC911X_32_BIT
  83. #define CONFIG_SMC911X_BASE 0x2C000000
  84. #endif /* (CONFIG_CMD_NET) */
  85. #define CONFIG_RBTREE
  86. #define CONFIG_MTD_PARTITIONS
  87. #define CONFIG_SYS_MTDPARTS_RUNTIME
  88. /* OneNAND config */
  89. #define CONFIG_USE_ONENAND_BOARD_INIT
  90. #define CONFIG_SYS_ONENAND_BASE ONENAND_MAP
  91. #define CONFIG_SYS_ONENAND_BLOCK_SIZE (128*1024)
  92. /* NAND config */
  93. #define CONFIG_SPL_OMAP3_ID_NAND
  94. #define CONFIG_SYS_NAND_BUSWIDTH_16BIT
  95. #define CONFIG_SYS_NAND_5_ADDR_CYCLE
  96. #define CONFIG_SYS_NAND_PAGE_COUNT 64
  97. #define CONFIG_SYS_NAND_PAGE_SIZE 2048
  98. #define CONFIG_SYS_NAND_OOBSIZE 64
  99. #define CONFIG_SYS_NAND_BLOCK_SIZE (128*1024)
  100. #define CONFIG_SYS_NAND_BAD_BLOCK_POS NAND_LARGE_BADBLOCK_POS
  101. #define CONFIG_SYS_NAND_ECCPOS { 2, 3, 4, 5, 6, 7, 8, 9, \
  102. 10, 11, 12, 13, 14, 15, 16, 17, \
  103. 18, 19, 20, 21, 22, 23, 24, 25, \
  104. 26, 27, 28, 29, 30, 31, 32, 33, \
  105. 34, 35, 36, 37, 38, 39, 40, 41, \
  106. 42, 43, 44, 45, 46, 47, 48, 49, \
  107. 50, 51, 52, 53, 54, 55, 56, 57, }
  108. #define CONFIG_SYS_NAND_ECCSIZE 512
  109. #define CONFIG_SYS_NAND_ECCBYTES 14
  110. #define CONFIG_NAND_OMAP_ECCSCHEME OMAP_ECC_BCH8_CODE_HW_DETECTION_SW
  111. #define CONFIG_NAND_OMAP_GPMC
  112. #define CONFIG_BCH
  113. /* UBI configuration */
  114. #define CONFIG_SPL_UBI 1
  115. #define CONFIG_SPL_UBI_MAX_VOL_LEBS 256
  116. #define CONFIG_SPL_UBI_MAX_PEB_SIZE (256*1024)
  117. #define CONFIG_SPL_UBI_MAX_PEBS 4096
  118. #define CONFIG_SPL_UBI_VOL_IDS 8
  119. #define CONFIG_SPL_UBI_LOAD_MONITOR_ID 0
  120. #define CONFIG_SPL_UBI_LOAD_KERNEL_ID 3
  121. #define CONFIG_SPL_UBI_LOAD_ARGS_ID 4
  122. #define CONFIG_SPL_UBI_PEB_OFFSET 4
  123. #define CONFIG_SPL_UBI_VID_OFFSET 512
  124. #define CONFIG_SPL_UBI_LEB_START 2048
  125. #define CONFIG_SPL_UBI_INFO_ADDR 0x88080000
  126. /* environment organization */
  127. #define CONFIG_ENV_IS_IN_UBI 1
  128. #define CONFIG_ENV_UBI_PART "UBI"
  129. #define CONFIG_ENV_UBI_VOLUME "config"
  130. #define CONFIG_ENV_UBI_VOLUME_REDUND "config_r"
  131. #define CONFIG_UBI_SILENCE_MSG 1
  132. #define CONFIG_UBIFS_SILENCE_MSG 1
  133. #define CONFIG_ENV_SIZE (32*1024)
  134. #endif /* __IGEP00X0_H */