origen.h 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Copyright (C) 2011 Samsung Electronics
  4. *
  5. * Configuration settings for the SAMSUNG ORIGEN (EXYNOS4210) board.
  6. */
  7. #ifndef __CONFIG_ORIGEN_H
  8. #define __CONFIG_ORIGEN_H
  9. #include <configs/exynos4-common.h>
  10. /* High Level Configuration Options */
  11. #define CONFIG_EXYNOS4210 1 /* which is a EXYNOS4210 SoC */
  12. #define CONFIG_ORIGEN 1 /* working with ORIGEN*/
  13. /* ORIGEN has 4 bank of DRAM */
  14. #define CONFIG_SYS_SDRAM_BASE 0x40000000
  15. #define PHYS_SDRAM_1 CONFIG_SYS_SDRAM_BASE
  16. #define SDRAM_BANK_SIZE (256 << 20) /* 256 MB */
  17. /* memtest works on */
  18. #define CONFIG_SYS_LOAD_ADDR (CONFIG_SYS_SDRAM_BASE + 0x3E00000)
  19. #define CONFIG_MACH_TYPE MACH_TYPE_ORIGEN
  20. /* select serial console configuration */
  21. /* Console configuration */
  22. #define CONFIG_DEFAULT_CONSOLE "console=ttySAC1,115200n8\0"
  23. #define CONFIG_SYS_MEM_TOP_HIDE (1 << 20) /* ram console */
  24. #define CONFIG_SYS_MONITOR_BASE 0x00000000
  25. /* Power Down Modes */
  26. #define S5P_CHECK_SLEEP 0x00000BAD
  27. #define S5P_CHECK_DIDLE 0xBAD00000
  28. #define S5P_CHECK_LPA 0xABAD0000
  29. /* MMC SPL */
  30. #define COPY_BL2_FNPTR_ADDR 0x02020030
  31. #define CONFIG_EXTRA_ENV_SETTINGS \
  32. "loadaddr=0x40007000\0" \
  33. "rdaddr=0x48000000\0" \
  34. "kerneladdr=0x40007000\0" \
  35. "ramdiskaddr=0x48000000\0" \
  36. "console=ttySAC2,115200n8\0" \
  37. "mmcdev=0\0" \
  38. "bootenv=uEnv.txt\0" \
  39. "loadbootenv=load mmc ${mmcdev} ${loadaddr} ${bootenv}\0" \
  40. "importbootenv=echo Importing environment from mmc ...; " \
  41. "env import -t $loadaddr $filesize\0" \
  42. "loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \
  43. "bootscript=echo Running bootscript from mmc${mmcdev} ...; " \
  44. "source ${loadaddr}\0"
  45. #define CONFIG_BOOTCOMMAND \
  46. "if mmc rescan; then " \
  47. "echo SD/MMC found on device ${mmcdev};" \
  48. "if run loadbootenv; then " \
  49. "echo Loaded environment from ${bootenv};" \
  50. "run importbootenv;" \
  51. "fi;" \
  52. "if test -n $uenvcmd; then " \
  53. "echo Running uenvcmd ...;" \
  54. "run uenvcmd;" \
  55. "fi;" \
  56. "if run loadbootscript; then " \
  57. "run bootscript; " \
  58. "fi; " \
  59. "fi;" \
  60. "load mmc ${mmcdev} ${loadaddr} uImage; bootm ${loadaddr} "
  61. #define CONFIG_CLK_1000_400_200
  62. /* MIU (Memory Interleaving Unit) */
  63. #define CONFIG_MIU_2BIT_21_7_INTERLEAVED
  64. #define CONFIG_SYS_MMC_ENV_DEV 0
  65. #define RESERVE_BLOCK_SIZE (512)
  66. #define BL1_SIZE (16 << 10) /*16 K reserved for BL1*/
  67. #define CONFIG_SPL_MAX_FOOTPRINT (14 * 1024)
  68. #define CONFIG_SYS_INIT_SP_ADDR 0x02040000
  69. /* U-Boot copy size from boot Media to DRAM.*/
  70. #define COPY_BL2_SIZE 0x80000
  71. #define BL2_START_OFFSET ((CONFIG_ENV_OFFSET + CONFIG_ENV_SIZE)/512)
  72. #define BL2_SIZE_BLOC_COUNT (COPY_BL2_SIZE/512)
  73. #endif /* __CONFIG_H */