blob: ab02aa072ffb76508468557fc7d346d9b343f265 [file] [log] [blame]
Tom Rini83d290c2018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +00002/*
3 * Copyright (C) 2010 Freescale Semiconductor, Inc.
4 *
5 * Configuration settings for the MX53-EVK Freescale board.
Liu Hui-R6434394391fb2011-01-03 22:27:42 +00006 */
7
8#ifndef __CONFIG_H
9#define __CONFIG_H
10
Fabio Estevam00e11a42011-09-22 08:07:22 +000011#define CONFIG_MACH_TYPE MACH_TYPE_MX53_EVK
12
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000013#include <asm/arch/imx-regs.h>
14
Fabio Estevama7abca02011-10-27 01:32:43 +000015#define CONFIG_CMDLINE_TAG /* enable passing of ATAGs */
Fabio Estevama7abca02011-10-27 01:32:43 +000016#define CONFIG_SETUP_MEMORY_TAGS
17#define CONFIG_INITRD_TAG
Fabio Estevamfd622f22013-04-24 14:44:26 +000018#define CONFIG_REVISION_TAG
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000019
Gong Qianyu18fb0e32015-10-26 19:47:42 +080020#define CONFIG_SYS_FSL_CLK
Fabio Estevam851f5562014-04-22 15:34:58 -030021
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000022/* Size of malloc() pool */
23#define CONFIG_SYS_MALLOC_LEN (CONFIG_ENV_SIZE + 2 * 1024 * 1024)
24
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000025#define CONFIG_MXC_UART
Stefano Babic40f6fff2011-11-22 15:22:39 +010026#define CONFIG_MXC_UART_BASE UART1_BASE
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000027
28/* I2C Configs */
tremb089d032013-09-21 18:13:36 +020029#define CONFIG_SYS_I2C
30#define CONFIG_SYS_I2C_MXC
Albert ARIBAUD \\(3ADEV\\)03544c62015-09-21 22:43:38 +020031#define CONFIG_SYS_I2C_MXC_I2C1 /* enable I2C bus 1 */
32#define CONFIG_SYS_I2C_MXC_I2C2 /* enable I2C bus 2 */
York Sunf8cb1012015-03-20 10:20:40 -070033#define CONFIG_SYS_I2C_MXC_I2C3 /* enable I2C bus 3 */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000034
35/* PMIC Configs */
Ɓukasz Majewskibe3b51a2012-11-13 03:22:14 +000036#define CONFIG_POWER
37#define CONFIG_POWER_I2C
38#define CONFIG_POWER_FSL
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000039#define CONFIG_SYS_FSL_PMIC_I2C_ADDR 8
Simon Glass913702c2014-05-20 06:01:34 -060040#define CONFIG_POWER_FSL_MC13892
Fabio Estevam4f97c882011-10-25 01:44:19 +000041#define CONFIG_RTC_MC13XXX
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000042
43/* MMC Configs */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000044#define CONFIG_SYS_FSL_ESDHC_ADDR 0
45#define CONFIG_SYS_FSL_ESDHC_NUM 2
46
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000047/* Eth Configs */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000048
49#define CONFIG_FEC_MXC
50#define IMX_FEC_BASE FEC_BASE_ADDR
51#define CONFIG_FEC_MXC_PHYADDR 0x1F
52
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000053/* allow to overwrite serial and ethaddr */
54#define CONFIG_ENV_OVERWRITE
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000055
56/* Command definition */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000057
Wolfgang Grandegger28b119e2011-10-17 08:21:56 +000058#define CONFIG_ETHPRIME "FEC0"
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000059
60#define CONFIG_LOADADDR 0x70800000 /* loadaddr env var */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000061
62#define CONFIG_EXTRA_ENV_SETTINGS \
63 "script=boot.scr\0" \
64 "uimage=uImage\0" \
65 "mmcdev=0\0" \
66 "mmcpart=2\0" \
67 "mmcroot=/dev/mmcblk0p3 rw\0" \
68 "mmcrootfstype=ext3 rootwait\0" \
69 "mmcargs=setenv bootargs console=ttymxc0,${baudrate} " \
70 "root=${mmcroot} " \
71 "rootfstype=${mmcrootfstype}\0" \
72 "loadbootscript=" \
73 "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
74 "bootscript=echo Running bootscript from mmc ...; " \
75 "source\0" \
76 "loaduimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${uimage}\0" \
77 "mmcboot=echo Booting from mmc ...; " \
78 "run mmcargs; " \
79 "bootm\0" \
80 "netargs=setenv bootargs console=ttymxc0,${baudrate} " \
81 "root=/dev/nfs " \
82 "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
83 "netboot=echo Booting from net ...; " \
84 "run netargs; " \
85 "dhcp ${uimage}; bootm\0" \
86
87#define CONFIG_BOOTCOMMAND \
Andrew Bradford66968112012-10-01 05:06:52 +000088 "mmc dev ${mmcdev}; if mmc rescan; then " \
Liu Hui-R6434394391fb2011-01-03 22:27:42 +000089 "if run loadbootscript; then " \
90 "run bootscript; " \
91 "else " \
92 "if run loaduimage; then " \
93 "run mmcboot; " \
94 "else run netboot; " \
95 "fi; " \
96 "fi; " \
97 "else run netboot; fi"
98
99#define CONFIG_ARP_TIMEOUT 200UL
100
101/* Miscellaneous configurable options */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +0000102
Liu Hui-R6434394391fb2011-01-03 22:27:42 +0000103#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
104
Liu Hui-R6434394391fb2011-01-03 22:27:42 +0000105/* Physical Memory Map */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +0000106#define PHYS_SDRAM_1 CSD0_BASE_ADDR
107#define PHYS_SDRAM_1_SIZE (512 * 1024 * 1024)
108
109#define CONFIG_SYS_SDRAM_BASE (PHYS_SDRAM_1)
110#define CONFIG_SYS_INIT_RAM_ADDR (IRAM_BASE_ADDR)
111#define CONFIG_SYS_INIT_RAM_SIZE (IRAM_SIZE)
112
113#define CONFIG_SYS_INIT_SP_OFFSET \
114 (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
115#define CONFIG_SYS_INIT_SP_ADDR \
116 (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
117
Masahiro Yamadae856bdc2017-02-11 22:43:54 +0900118/* environment organization */
Liu Hui-R6434394391fb2011-01-03 22:27:42 +0000119#define CONFIG_SYS_MMC_ENV_DEV 0
120
Liu Hui-R6434394391fb2011-01-03 22:27:42 +0000121#endif /* __CONFIG_H */