1 /* SPDX-License-Identifier: GPL-2.0+ */ 2 /* 3 * Copyright (C) 2015 Timesys Corporation 4 * Copyright (C) 2015 General Electric Company 5 * Copyright (C) 2014 Advantech 6 * Copyright (C) 2012 Freescale Semiconductor, Inc. 7 * 8 * Configuration settings for the GE MX6Q Bx50v3 boards. 9 */ 10 11 #ifndef __GE_BX50V3_CONFIG_H 12 #define __GE_BX50V3_CONFIG_H 13 14 #include <asm/arch/imx-regs.h> 15 #include <asm/mach-imx/gpio.h> 16 17 #include "mx6_common.h" 18 #include <linux/sizes.h> 19 20 #ifdef CONFIG_CMD_NFS 21 #define NETWORKBOOT \ 22 "setnetworkboot=" \ 23 "setenv ipaddr 172.16.2.10; setenv serverip 172.16.2.20; " \ 24 "setenv gatewayip 172.16.2.20; setenv nfsserver 172.16.2.20; " \ 25 "setenv netmask 255.255.255.0; setenv ethaddr ca:fe:de:ca:f0:11; " \ 26 "setenv bootargs root=/dev/nfs nfsroot=${nfsserver}:/srv/nfs/,v3,tcp rw rootwait" \ 27 "setenv bootargs $bootargs ip=${ipaddr}:${nfsserver}:${gatewayip}:${netmask}::eth0:off " \ 28 "setenv bootargs $bootargs cma=128M bootcause=${bootcause} ${videoargs} " \ 29 "setenv bootargs $bootargs systemd.mask=helix-network-defaults.service " \ 30 "setenv bootargs $bootargs watchdog.handle_boot_enabled=1\0" \ 31 "networkboot=" \ 32 "run setnetworkboot; " \ 33 "nfs ${loadaddr} /srv/nfs/fitImage; " \ 34 "bootm ${loadaddr}\0" \ 35 36 #define NETWORKBOOTCOMMAND \ 37 "run networkboot; " \ 38 39 #else 40 #define NETWORKBOOT \ 41 42 #endif 43 44 #define CFG_EXTRA_ENV_SETTINGS \ 45 NETWORKBOOT \ 46 "image=/boot/fitImage\0" \ 47 "dev=mmc\0" \ 48 "devnum=2\0" \ 49 "rootdev=mmcblk0p\0" \ 50 "quiet=quiet loglevel=0\0" \ 51 "setargs=setenv bootargs root=/dev/${rootdev}${partnum} " \ 52 "ro rootwait cma=128M " \ 53 "bootcause=${bootcause} " \ 54 "${quiet} " \ 55 "${videoargs}" "\0" \ 56 "doquiet=" \ 57 "if ext2load ${dev} ${devnum}:5 0x7000A000 /boot/console; " \ 58 "then setenv quiet; fi\0" \ 59 "hasfirstboot=" \ 60 "test -e ${dev} ${devnum}:${partnum} /boot/bootcause/firstboot\0" \ 61 "swappartitions=" \ 62 "setexpr partnum 3 - ${partnum}\0" \ 63 "failbootcmd=" \ 64 "cls; " \ 65 "setcurs 5 4; " \ 66 "lcdputs \"Monitor failed to start. " \ 67 "Try again, or contact GE Service for support.\"; " \ 68 "bootcount reset; " \ 69 "while true; do sleep 1; done; \0" \ 70 "loadimage=" \ 71 "ext2load ${dev} ${devnum}:${partnum} ${loadaddr} ${image}\0" \ 72 "doboot=" \ 73 "echo Booting from ${dev}:${devnum}:${partnum} ...; " \ 74 "run setargs; " \ 75 "bootm ${loadaddr}\0" \ 76 "tryboot=" \ 77 "setenv partnum 1; run hasfirstboot || setenv partnum 2; " \ 78 "run loadimage || run swappartitions && run loadimage || " \ 79 "setenv partnum 0 && echo MISSING IMAGE;" \ 80 "run doboot; " \ 81 "run failbootcmd\0" \ 82 83 /* Physical Memory Map */ 84 #define PHYS_SDRAM MMDC0_ARB_BASE_ADDR 85 86 #define CFG_SYS_BOOTMAPSZ (256 << 20) /* 256M */ 87 88 #define CFG_SYS_SDRAM_BASE PHYS_SDRAM 89 #define CFG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR 90 #define CFG_SYS_INIT_RAM_SIZE IRAM_SIZE 91 92 /* environment organization */ 93 94 #define CFG_SYS_FSL_USDHC_NUM 3 95 96 #endif /* __GE_BX50V3_CONFIG_H */ 97