dreamplug.h 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151
  1. /*
  2. * (C) Copyright 2011
  3. * Jason Cooper <u-boot@lakedaemon.net>
  4. *
  5. * Based on work by:
  6. * Marvell Semiconductor <www.marvell.com>
  7. * Written-by: Siddarth Gore <gores@marvell.com>
  8. *
  9. * See file CREDITS for list of people who contributed to this
  10. * project.
  11. *
  12. * This program is free software; you can redistribute it and/or
  13. * modify it under the terms of the GNU General Public License as
  14. * published by the Free Software Foundation; either version 2 of
  15. * the License, or (at your option) any later version.
  16. *
  17. * This program is distributed in the hope that it will be useful,
  18. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  19. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  20. * GNU General Public License for more details.
  21. *
  22. * You should have received a copy of the GNU General Public License
  23. * along with this program; if not, write to the Free Software
  24. * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
  25. * MA 02110-1301 USA
  26. */
  27. #ifndef _CONFIG_DREAMPLUG_H
  28. #define _CONFIG_DREAMPLUG_H
  29. /*
  30. * FIXME: This belongs in mach-types.h. However, we only pull mach-types
  31. * from Linus' kernel.org tree. This hasn't been updated primarily due to
  32. * the recent arch/arm reshuffling. So, in the meantime, we'll place it
  33. * here.
  34. */
  35. #include <asm/mach-types.h>
  36. #ifdef MACH_TYPE_DREAMPLUG
  37. #error "MACH_TYPE_DREAMPLUG has been defined properly, please remove this."
  38. #else
  39. #define MACH_TYPE_DREAMPLUG 3550
  40. #endif
  41. /*
  42. * Version number information
  43. */
  44. #define CONFIG_IDENT_STRING "\nMarvell-DreamPlug"
  45. /*
  46. * High Level Configuration Options (easy to change)
  47. */
  48. #define CONFIG_SHEEVA_88SV131 1 /* CPU Core subversion */
  49. #define CONFIG_KIRKWOOD 1 /* SOC Family Name */
  50. #define CONFIG_KW88F6281 1 /* SOC Name */
  51. #define CONFIG_MACH_TYPE MACH_TYPE_DREAMPLUG
  52. #define CONFIG_SKIP_LOWLEVEL_INIT /* disable board lowlevel_init */
  53. /*
  54. * Commands configuration
  55. */
  56. #define CONFIG_SYS_NO_FLASH /* Declare no flash (NOR/SPI) */
  57. #include <config_cmd_default.h>
  58. #define CONFIG_CMD_DHCP
  59. #define CONFIG_CMD_ENV
  60. #define CONFIG_CMD_FAT
  61. #define CONFIG_CMD_SF
  62. #define CONFIG_CMD_PING
  63. #define CONFIG_CMD_USB
  64. #define CONFIG_CMD_IDE
  65. #define CONFIG_CMD_DATE
  66. /*
  67. * mv-common.h should be defined after CMD configs since it used them
  68. * to enable certain macros
  69. */
  70. #include "mv-common.h"
  71. /*
  72. * Environment variables configurations
  73. */
  74. #ifdef CONFIG_SPI_FLASH
  75. #define CONFIG_ENV_IS_IN_SPI_FLASH 1
  76. #define CONFIG_ENV_SECT_SIZE 0x10000 /* 64k */
  77. #else
  78. #define CONFIG_ENV_IS_NOWHERE 1 /* if env in SDRAM */
  79. #endif
  80. #ifdef CONFIG_CMD_SF
  81. #define CONFIG_SPI_FLASH 1
  82. #define CONFIG_HARD_SPI 1
  83. #define CONFIG_KIRKWOOD_SPI 1
  84. #define CONFIG_SPI_FLASH_MACRONIX 1
  85. #define CONFIG_ENV_SPI_BUS 0
  86. #define CONFIG_ENV_SPI_CS 0
  87. #define CONFIG_ENV_SPI_MAX_HZ 50000000 /* 50 MHz */
  88. #endif
  89. /*
  90. * max 4k env size is enough, but in case of nand
  91. * it has to be rounded to sector size
  92. */
  93. #define CONFIG_ENV_SIZE 0x1000 /* 4k */
  94. #define CONFIG_ENV_ADDR 0x100000
  95. #define CONFIG_ENV_OFFSET 0x100000 /* env starts here */
  96. /*
  97. * Default environment variables
  98. */
  99. #define CONFIG_BOOTCOMMAND "setenv ethact egiga0; " \
  100. "${x_bootcmd_ethernet}; setenv ethact egiga1; " \
  101. "${x_bootcmd_ethernet}; ${x_bootcmd_usb}; ${x_bootcmd_kernel}; "\
  102. "setenv bootargs ${x_bootargs} ${x_bootargs_root}; " \
  103. "bootm 0x6400000;"
  104. #define CONFIG_EXTRA_ENV_SETTINGS \
  105. "x_bootcmd_ethernet=ping 192.168.2.1\0" \
  106. "x_bootcmd_usb=usb start\0" \
  107. "x_bootcmd_kernel=fatload usb 0 0x6400000 uImage\0" \
  108. "x_bootargs=console=ttyS0,115200\0" \
  109. "x_bootargs_root=root=/dev/sda2 rootdelay=10\0"
  110. /*
  111. * Ethernet Driver configuration
  112. */
  113. #ifdef CONFIG_CMD_NET
  114. #define CONFIG_MVGBE_PORTS {1, 1} /* enable both ports */
  115. #define CONFIG_PHY_BASE_ADR 0
  116. #endif /* CONFIG_CMD_NET */
  117. /*
  118. * SATA Driver configuration
  119. */
  120. #ifdef CONFIG_MVSATA_IDE
  121. #define CONFIG_SYS_ATA_IDE0_OFFSET MV_SATA_PORT0_OFFSET
  122. #endif /*CONFIG_MVSATA_IDE*/
  123. /*
  124. * RTC driver configuration
  125. */
  126. #ifdef CONFIG_CMD_DATE
  127. #define CONFIG_RTC_MV
  128. #endif /* CONFIG_CMD_DATE */
  129. #define CONFIG_SYS_ALT_MEMTEST
  130. /*
  131. * display enhanced info about the cpu at boot.
  132. */
  133. #define CONFIG_DISPLAY_CPUINFO
  134. #endif /* _CONFIG_DREAMPLUG_H */