blob: 39c8ef060c7fac8db9957d2be3f0b38f096b97cb [file] [log] [blame]
Tom Rini10e47792018-05-06 17:58:06 -04001/* SPDX-License-Identifier: GPL-2.0+ */
Fabio Estevam26e9c972013-04-10 09:32:58 +00002/*
3 * Copyright 2013 Freescale Semiconductor, Inc.
4 *
5 * Configuration settings for the Freescale i.MX6SL EVK board.
Fabio Estevam26e9c972013-04-10 09:32:58 +00006 */
7
8#ifndef __CONFIG_H
9#define __CONFIG_H
10
Fabio Estevam881c2712014-01-09 08:57:12 -020011#include "mx6_common.h"
Fabio Estevam26e9c972013-04-10 09:32:58 +000012
Tom Rinia17aa192022-12-04 10:04:55 -050013#define CFG_MXC_UART_BASE UART1_IPS_BASE_ADDR
Fabio Estevam26e9c972013-04-10 09:32:58 +000014
15/* MMC Configs */
Tom Rini376b88a2022-10-28 20:27:13 -040016#define CFG_SYS_FSL_ESDHC_ADDR USDHC2_BASE_ADDR
Fabio Estevam26e9c972013-04-10 09:32:58 +000017
Tom Rinic9edebe2022-12-04 10:03:50 -050018#define CFG_EXTRA_ENV_SETTINGS \
Fabio Estevam26e9c972013-04-10 09:32:58 +000019 "script=boot.scr\0" \
Otavio Salvador01064b12014-01-16 19:58:04 -020020 "image=zImage\0" \
Fabio Estevam26e9c972013-04-10 09:32:58 +000021 "console=ttymxc0\0" \
22 "fdt_high=0xffffffff\0" \
23 "initrd_high=0xffffffff\0" \
24 "fdt_file=imx6sl-evk.dtb\0" \
Fabio Estevama5c5b6e2014-01-22 12:23:32 -020025 "fdt_addr=0x88000000\0" \
Fabio Estevam26e9c972013-04-10 09:32:58 +000026 "boot_fdt=try\0" \
27 "ip_dyn=yes\0" \
Ye.Li9a81b1d2014-11-04 15:26:04 +080028 "mmcdev=1\0" \
Otavio Salvadorc36bd3f2013-06-28 18:52:41 -030029 "mmcpart=1\0" \
Fabio Estevam1da27ab2017-10-02 10:11:37 -030030 "finduuid=part uuid mmc 1:2 uuid\0" \
Fabio Estevam26e9c972013-04-10 09:32:58 +000031 "mmcargs=setenv bootargs console=${console},${baudrate} " \
Fabio Estevam1da27ab2017-10-02 10:11:37 -030032 "root=PARTUUID=${uuid} rootwait rw\0" \
Fabio Estevam26e9c972013-04-10 09:32:58 +000033 "loadbootscript=" \
34 "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
35 "bootscript=echo Running bootscript from mmc ...; " \
36 "source\0" \
Otavio Salvador01064b12014-01-16 19:58:04 -020037 "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
Fabio Estevam26e9c972013-04-10 09:32:58 +000038 "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
39 "mmcboot=echo Booting from mmc ...; " \
Fabio Estevam1da27ab2017-10-02 10:11:37 -030040 "run finduuid; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000041 "run mmcargs; " \
42 "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
43 "if run loadfdt; then " \
Otavio Salvador01064b12014-01-16 19:58:04 -020044 "bootz ${loadaddr} - ${fdt_addr}; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000045 "else " \
46 "if test ${boot_fdt} = try; then " \
Otavio Salvador01064b12014-01-16 19:58:04 -020047 "bootz; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000048 "else " \
49 "echo WARN: Cannot load the DT; " \
50 "fi; " \
51 "fi; " \
52 "else " \
Otavio Salvador01064b12014-01-16 19:58:04 -020053 "bootz; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000054 "fi;\0" \
55 "netargs=setenv bootargs console=${console},${baudrate} " \
56 "root=/dev/nfs " \
57 "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
58 "netboot=echo Booting from net ...; " \
59 "run netargs; " \
60 "if test ${ip_dyn} = yes; then " \
61 "setenv get_cmd dhcp; " \
62 "else " \
63 "setenv get_cmd tftp; " \
64 "fi; " \
Otavio Salvador01064b12014-01-16 19:58:04 -020065 "${get_cmd} ${image}; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000066 "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \
67 "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \
Otavio Salvador01064b12014-01-16 19:58:04 -020068 "bootz ${loadaddr} - ${fdt_addr}; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000069 "else " \
70 "if test ${boot_fdt} = try; then " \
Otavio Salvador01064b12014-01-16 19:58:04 -020071 "bootz; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000072 "else " \
73 "echo WARN: Cannot load the DT; " \
74 "fi; " \
75 "fi; " \
76 "else " \
Otavio Salvador01064b12014-01-16 19:58:04 -020077 "bootz; " \
Fabio Estevam26e9c972013-04-10 09:32:58 +000078 "fi;\0"
79
Fabio Estevam26e9c972013-04-10 09:32:58 +000080/* Miscellaneous configurable options */
Fabio Estevam26e9c972013-04-10 09:32:58 +000081
Fabio Estevam26e9c972013-04-10 09:32:58 +000082/* Physical Memory Map */
Fabio Estevam26e9c972013-04-10 09:32:58 +000083#define PHYS_SDRAM MMDC0_ARB_BASE_ADDR
Fabio Estevam26e9c972013-04-10 09:32:58 +000084
Tom Rinibb4dd962022-11-16 13:10:37 -050085#define CFG_SYS_SDRAM_BASE PHYS_SDRAM
Tom Rini6a5dccc2022-11-16 13:10:41 -050086#define CFG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR
87#define CFG_SYS_INIT_RAM_SIZE IRAM_SIZE
Fabio Estevam26e9c972013-04-10 09:32:58 +000088
Peter Robinson4b671502015-05-22 17:30:45 +010089/* Environment organization */
Fabio Estevam26e9c972013-04-10 09:32:58 +000090
Peng Fandd6624a2014-11-10 08:50:41 +080091/* USB Configs */
Peng Fandd6624a2014-11-10 08:50:41 +080092#ifdef CONFIG_CMD_USB
Tom Rinib9796e82022-12-04 10:04:56 -050093#define CFG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW)
94#define CFG_MXC_USB_FLAGS 0
Peng Fandd6624a2014-11-10 08:50:41 +080095#endif
96
Tom Rini376b88a2022-10-28 20:27:13 -040097#define CFG_SYS_FSL_USDHC_NUM 3
Ye.Lia056ba52014-10-30 18:30:54 +080098
Fabio Estevam26e9c972013-04-10 09:32:58 +000099#endif /* __CONFIG_H */