mx6_common.h 1.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. /*
  3. * Copyright (c) 2013, NVIDIA CORPORATION. All rights reserved.
  4. */
  5. #ifndef __MX6_COMMON_H
  6. #define __MX6_COMMON_H
  7. #include <linux/stringify.h>
  8. #if (defined(CONFIG_MX6UL) || defined(CONFIG_MX6ULL))
  9. #define CONFIG_SC_TIMER_CLK 8000000 /* 8Mhz */
  10. #define COUNTER_FREQUENCY CONFIG_SC_TIMER_CLK
  11. #else
  12. #ifndef CONFIG_SYS_L2CACHE_OFF
  13. #define CONFIG_SYS_L2_PL310
  14. #define CONFIG_SYS_PL310_BASE L2_PL310_BASE
  15. #endif
  16. #endif
  17. #define CONFIG_BOARD_POSTCLK_INIT
  18. #define CONFIG_MXC_GPT_HCLK
  19. #define CONFIG_SYS_BOOTM_LEN 0x1000000
  20. #include <linux/sizes.h>
  21. #include <asm/arch/imx-regs.h>
  22. #include <asm/mach-imx/gpio.h>
  23. #ifndef CONFIG_MX6
  24. #define CONFIG_MX6
  25. #endif
  26. #define CONFIG_SYS_FSL_CLK
  27. /* ATAGs */
  28. #define CONFIG_CMDLINE_TAG
  29. #define CONFIG_SETUP_MEMORY_TAGS
  30. #define CONFIG_INITRD_TAG
  31. #define CONFIG_REVISION_TAG
  32. /* Boot options */
  33. #if defined(CONFIG_MX6SL) || defined(CONFIG_MX6SLL) || \
  34. defined(CONFIG_MX6SX) || \
  35. defined(CONFIG_MX6UL) || defined(CONFIG_MX6ULL)
  36. #define CONFIG_LOADADDR 0x82000000
  37. #else
  38. #define CONFIG_LOADADDR 0x12000000
  39. #endif
  40. #define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
  41. /* Miscellaneous configurable options */
  42. #define CONFIG_SYS_CBSIZE 512
  43. #define CONFIG_SYS_MAXARGS 32
  44. /* MMC */
  45. #ifdef CONFIG_SPL_BUILD
  46. #define CONFIG_SPL_DRIVERS_MISC_SUPPORT
  47. #endif
  48. #endif