Tom Rini | 10e4779 | 2018-05-06 17:58:06 -0400 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0+ */ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 2 | /* |
| 3 | * Copyright 2013 Freescale Semiconductor, Inc. |
| 4 | * |
| 5 | * Configuration settings for the Freescale i.MX6SL EVK board. |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 6 | */ |
| 7 | |
| 8 | #ifndef __CONFIG_H |
| 9 | #define __CONFIG_H |
| 10 | |
Fabio Estevam | 881c271 | 2014-01-09 08:57:12 -0200 | [diff] [blame] | 11 | #include "mx6_common.h" |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 12 | |
Tom Rini | a17aa19 | 2022-12-04 10:04:55 -0500 | [diff] [blame] | 13 | #define CFG_MXC_UART_BASE UART1_IPS_BASE_ADDR |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 14 | |
| 15 | /* MMC Configs */ |
Tom Rini | 376b88a | 2022-10-28 20:27:13 -0400 | [diff] [blame] | 16 | #define CFG_SYS_FSL_ESDHC_ADDR USDHC2_BASE_ADDR |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 17 | |
Tom Rini | c9edebe | 2022-12-04 10:03:50 -0500 | [diff] [blame] | 18 | #define CFG_EXTRA_ENV_SETTINGS \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 19 | "script=boot.scr\0" \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 20 | "image=zImage\0" \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 21 | "console=ttymxc0\0" \ |
| 22 | "fdt_high=0xffffffff\0" \ |
| 23 | "initrd_high=0xffffffff\0" \ |
| 24 | "fdt_file=imx6sl-evk.dtb\0" \ |
Fabio Estevam | a5c5b6e | 2014-01-22 12:23:32 -0200 | [diff] [blame] | 25 | "fdt_addr=0x88000000\0" \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 26 | "boot_fdt=try\0" \ |
| 27 | "ip_dyn=yes\0" \ |
Fabio Estevam | 678d48c | 2024-08-26 15:04:52 -0300 | [diff] [blame] | 28 | "mmcdev=0\0" \ |
Otavio Salvador | c36bd3f | 2013-06-28 18:52:41 -0300 | [diff] [blame] | 29 | "mmcpart=1\0" \ |
Fabio Estevam | 678d48c | 2024-08-26 15:04:52 -0300 | [diff] [blame] | 30 | "finduuid=part uuid mmc ${mmcdev}:2 uuid\0" \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 31 | "mmcargs=setenv bootargs console=${console},${baudrate} " \ |
Fabio Estevam | 1da27ab | 2017-10-02 10:11:37 -0300 | [diff] [blame] | 32 | "root=PARTUUID=${uuid} rootwait rw\0" \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 33 | "loadbootscript=" \ |
| 34 | "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \ |
| 35 | "bootscript=echo Running bootscript from mmc ...; " \ |
| 36 | "source\0" \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 37 | "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 38 | "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \ |
| 39 | "mmcboot=echo Booting from mmc ...; " \ |
Fabio Estevam | 1da27ab | 2017-10-02 10:11:37 -0300 | [diff] [blame] | 40 | "run finduuid; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 41 | "run mmcargs; " \ |
| 42 | "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ |
| 43 | "if run loadfdt; then " \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 44 | "bootz ${loadaddr} - ${fdt_addr}; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 45 | "else " \ |
| 46 | "if test ${boot_fdt} = try; then " \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 47 | "bootz; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 48 | "else " \ |
| 49 | "echo WARN: Cannot load the DT; " \ |
| 50 | "fi; " \ |
| 51 | "fi; " \ |
| 52 | "else " \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 53 | "bootz; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 54 | "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 Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 65 | "${get_cmd} ${image}; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 66 | "if test ${boot_fdt} = yes || test ${boot_fdt} = try; then " \ |
| 67 | "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 68 | "bootz ${loadaddr} - ${fdt_addr}; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 69 | "else " \ |
| 70 | "if test ${boot_fdt} = try; then " \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 71 | "bootz; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 72 | "else " \ |
| 73 | "echo WARN: Cannot load the DT; " \ |
| 74 | "fi; " \ |
| 75 | "fi; " \ |
| 76 | "else " \ |
Otavio Salvador | 01064b1 | 2014-01-16 19:58:04 -0200 | [diff] [blame] | 77 | "bootz; " \ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 78 | "fi;\0" |
| 79 | |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 80 | /* Miscellaneous configurable options */ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 81 | |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 82 | /* Physical Memory Map */ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 83 | #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 84 | |
Tom Rini | bb4dd96 | 2022-11-16 13:10:37 -0500 | [diff] [blame] | 85 | #define CFG_SYS_SDRAM_BASE PHYS_SDRAM |
Tom Rini | 6a5dccc | 2022-11-16 13:10:41 -0500 | [diff] [blame] | 86 | #define CFG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR |
| 87 | #define CFG_SYS_INIT_RAM_SIZE IRAM_SIZE |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 88 | |
Peter Robinson | 4b67150 | 2015-05-22 17:30:45 +0100 | [diff] [blame] | 89 | /* Environment organization */ |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 90 | |
Tom Rini | 376b88a | 2022-10-28 20:27:13 -0400 | [diff] [blame] | 91 | #define CFG_SYS_FSL_USDHC_NUM 3 |
Ye.Li | a056ba5 | 2014-10-30 18:30:54 +0800 | [diff] [blame] | 92 | |
Fabio Estevam | 26e9c97 | 2013-04-10 09:32:58 +0000 | [diff] [blame] | 93 | #endif /* __CONFIG_H */ |