• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /* SPDX-License-Identifier: GPL-2.0+ */
2 /*
3  * Copyright 2016 Freescale Semiconductor, Inc.
4  */
5 
6 #ifndef __LS1012ARDB_H__
7 #define __LS1012ARDB_H__
8 
9 #include "ls1012a_common.h"
10 
11 /* DDR */
12 #define CONFIG_DIMM_SLOTS_PER_CTLR	1
13 #define CONFIG_CHIP_SELECTS_PER_CTRL	1
14 #define CONFIG_NR_DRAM_BANKS		2
15 #define CONFIG_SYS_SDRAM_SIZE		0x20000000
16 #define CONFIG_CHIP_SELECTS_PER_CTRL	1
17 #define CONFIG_CMD_MEMINFO
18 #define CONFIG_SYS_MEMTEST_START	0x80000000
19 #define CONFIG_SYS_MEMTEST_END		0x9fffffff
20 
21 #ifndef CONFIG_SPL_BUILD
22 #undef BOOT_TARGET_DEVICES
23 #define BOOT_TARGET_DEVICES(func) \
24 	func(USB, usb, 0)
25 #endif
26 
27 #undef CONFIG_EXTRA_ENV_SETTINGS
28 #define CONFIG_EXTRA_ENV_SETTINGS		\
29 	"verify=no\0"				\
30 	"fdt_high=0xffffffffffffffff\0"		\
31 	"initrd_high=0xffffffffffffffff\0"	\
32 	"fdt_addr=0x00f00000\0"			\
33 	"kernel_addr=0x01000000\0"		\
34 	"scriptaddr=0x80000000\0"		\
35 	"fdtheader_addr_r=0x80100000\0"		\
36 	"kernelheader_addr_r=0x80200000\0"	\
37 	"kernel_addr_r=0x96000000\0"		\
38 	"fdt_addr_r=0x90000000\0"		\
39 	"load_addr=0x96000000\0"		\
40 	"kernel_size=0x2800000\0"		\
41 	"console=ttyS0,115200\0"		\
42 	BOOTENV					\
43 	"boot_scripts=ls1012afrdm_boot.scr\0"	\
44 	"scan_dev_for_boot_part="		\
45 	     "part list ${devtype} ${devnum} devplist; "	\
46 	     "env exists devplist || setenv devplist 1; "	\
47 	     "for distro_bootpart in ${devplist}; do "		\
48 		  "if fstype ${devtype} "			\
49 		      "${devnum}:${distro_bootpart} "		\
50 		      "bootfstype; then "			\
51 		      "run scan_dev_for_boot; "	\
52 		  "fi; "			\
53 	      "done\0"				\
54 	"scan_dev_for_boot="				  \
55 		"echo Scanning ${devtype} "		  \
56 				"${devnum}:${distro_bootpart}...; "  \
57 		"for prefix in ${boot_prefixes}; do "	  \
58 			"run scan_dev_for_scripts; "	  \
59 		"done;"					  \
60 		"\0"					  \
61 	"installer=load usb 0:2 $load_addr "	\
62 		   "/flex_installer_arm64.itb; "	\
63 		   "bootm $load_addr#$board\0"	\
64 	"qspi_bootcmd=echo Trying load from qspi..;"	\
65 		"sf probe && sf read $load_addr "	\
66 		"$kernel_addr $kernel_size && bootm $load_addr#$board\0"
67 
68 #undef CONFIG_BOOTCOMMAND
69 #define CONFIG_BOOTCOMMAND "pfe stop;run distro_bootcmd;run qspi_bootcmd"
70 
71 #define CONFIG_CMD_MEMINFO
72 #define CONFIG_SYS_MEMTEST_START	0x80000000
73 #define CONFIG_SYS_MEMTEST_END		0x9fffffff
74 
75 #endif /* __LS1012ARDB_H__ */
76