sama5d27_som1_ek.h 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. /* SPDX-License-Identifier: GPL-2.0+ */
  2. /*
  3. * Configuration file for the SAMA5D27 SOM1 EK Board.
  4. *
  5. * Copyright (C) 2017 Microchip Corporation
  6. * Wenyou Yang <wenyou.yang@microchip.com>
  7. */
  8. #ifndef __CONFIG_H
  9. #define __CONFIG_H
  10. #include "at91-sama5_common.h"
  11. #undef CONFIG_SYS_AT91_MAIN_CLOCK
  12. #define CONFIG_SYS_AT91_MAIN_CLOCK 24000000 /* from 24 MHz crystal */
  13. /* SDRAM */
  14. #define CONFIG_SYS_SDRAM_BASE 0x20000000
  15. #define CONFIG_SYS_SDRAM_SIZE 0x8000000
  16. #ifdef CONFIG_SPL_BUILD
  17. #define CONFIG_SYS_INIT_SP_ADDR 0x218000
  18. #else
  19. #define CONFIG_SYS_INIT_SP_ADDR \
  20. (CONFIG_SYS_SDRAM_BASE + 16 * 1024 - GENERATED_GBL_DATA_SIZE)
  21. #endif
  22. #define CONFIG_SYS_LOAD_ADDR 0x22000000 /* load address */
  23. /* NAND flash */
  24. #undef CONFIG_CMD_NAND
  25. /* SPI flash */
  26. #undef CONFIG_BOOTCOMMAND
  27. #ifdef CONFIG_SD_BOOT
  28. /* bootstrap + u-boot + env in sd card */
  29. #define CONFIG_BOOTCOMMAND "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x21000000 at91-sama5d27_som1_ek.dtb; " \
  30. "fatload mmc " CONFIG_ENV_FAT_DEVICE_AND_PART " 0x22000000 zImage; " \
  31. "bootz 0x22000000 - 0x21000000"
  32. #endif
  33. #ifdef CONFIG_QSPI_BOOT
  34. #undef CONFIG_BOOTARGS
  35. #define CONFIG_BOOTARGS \
  36. "console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rw rootwait"
  37. #endif
  38. /* SPL */
  39. #define CONFIG_SPL_MAX_SIZE 0x10000
  40. #define CONFIG_SPL_BSS_START_ADDR 0x20000000
  41. #define CONFIG_SPL_BSS_MAX_SIZE 0x80000
  42. #define CONFIG_SYS_SPL_MALLOC_START 0x20080000
  43. #define CONFIG_SYS_SPL_MALLOC_SIZE 0x80000
  44. #define CONFIG_SYS_MONITOR_LEN (512 << 10)
  45. #ifdef CONFIG_SD_BOOT
  46. #define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1
  47. #define CONFIG_SPL_FS_LOAD_PAYLOAD_NAME "u-boot.img"
  48. #endif
  49. #endif