Merge branch 'master' of git://git.denx.de/u-boot-spi
[platform/kernel/u-boot.git] / include / configs / mx6_common.h
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * Copyright (c) 2013, NVIDIA CORPORATION.  All rights reserved.
4  */
5
6 #ifndef __MX6_COMMON_H
7 #define __MX6_COMMON_H
8
9 #if (defined(CONFIG_MX6UL) || defined(CONFIG_MX6ULL))
10 #define CONFIG_SC_TIMER_CLK 8000000 /* 8Mhz */
11 #define COUNTER_FREQUENCY CONFIG_SC_TIMER_CLK
12 #else
13 #ifndef CONFIG_SYS_L2CACHE_OFF
14 #define CONFIG_SYS_L2_PL310
15 #define CONFIG_SYS_PL310_BASE   L2_PL310_BASE
16 #endif
17
18 #endif
19 #define CONFIG_BOARD_POSTCLK_INIT
20 #define CONFIG_MXC_GPT_HCLK
21
22 #define CONFIG_SYS_BOOTM_LEN    0x1000000
23
24 #include <linux/sizes.h>
25 #include <asm/arch/imx-regs.h>
26 #include <asm/mach-imx/gpio.h>
27
28 #ifndef CONFIG_MX6
29 #define CONFIG_MX6
30 #endif
31
32 #define CONFIG_SYS_FSL_CLK
33
34 /* ATAGs */
35 #define CONFIG_CMDLINE_TAG
36 #define CONFIG_SETUP_MEMORY_TAGS
37 #define CONFIG_INITRD_TAG
38 #define CONFIG_REVISION_TAG
39
40 /* Boot options */
41 #if defined(CONFIG_MX6SL) || defined(CONFIG_MX6SLL) || \
42         defined(CONFIG_MX6SX) || \
43         defined(CONFIG_MX6UL) || defined(CONFIG_MX6ULL)
44 #define CONFIG_LOADADDR         0x82000000
45 #else
46 #define CONFIG_LOADADDR         0x12000000
47 #endif
48 #define CONFIG_SYS_LOAD_ADDR    CONFIG_LOADADDR
49
50 /* allow to overwrite serial and ethaddr */
51 #define CONFIG_ENV_OVERWRITE
52
53 /* Miscellaneous configurable options */
54 #define CONFIG_SYS_CBSIZE       512
55 #define CONFIG_SYS_MAXARGS      32
56
57 /* MMC */
58 #define CONFIG_FSL_USDHC
59
60 /* Secure boot (HAB) support */
61 #ifdef CONFIG_SECURE_BOOT
62 #define CONFIG_CSF_SIZE                 0x4000
63 #ifdef CONFIG_SPL_BUILD
64 #define CONFIG_SPL_DRIVERS_MISC_SUPPORT
65 #endif
66 #endif
67
68 #endif