From 752513d8d9768ef9d9da29db608d89b5d3517c2f Mon Sep 17 00:00:00 2001 From: Gong Qianyu Date: Mon, 18 Sep 2017 16:59:28 +0800 Subject: armv8: ls1046aqds: Fix NAND offset for Fman ucode and env Fix a bug of 'commit 8104deb2d6b7 ("armv8: layerscape: Adjust memory mapping for Flash/SD card on LS1046A")' as NAND block size is 256KB on LS1046AQDS. Signed-off-by: Gong Qianyu Reviewed-by: York Sun --- include/configs/ls1046a_common.h | 2 +- include/configs/ls1046aqds.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'include') diff --git a/include/configs/ls1046a_common.h b/include/configs/ls1046a_common.h index dfc8e9237d0..6d501b9c545 100644 --- a/include/configs/ls1046a_common.h +++ b/include/configs/ls1046a_common.h @@ -183,7 +183,7 @@ #define CONFIG_ENV_SPI_MODE 0x03 #elif defined(CONFIG_NAND_BOOT) #define CONFIG_SYS_QE_FMAN_FW_IN_NAND -#define CONFIG_SYS_FMAN_FW_ADDR (72 * CONFIG_SYS_NAND_BLOCK_SIZE) +#define CONFIG_SYS_FMAN_FW_ADDR (36 * CONFIG_SYS_NAND_BLOCK_SIZE) #else #define CONFIG_SYS_QE_FMAN_FW_IN_NOR #define CONFIG_SYS_FMAN_FW_ADDR 0x60900000 diff --git a/include/configs/ls1046aqds.h b/include/configs/ls1046aqds.h index 9231cca9e95..39bd1c38a80 100644 --- a/include/configs/ls1046aqds.h +++ b/include/configs/ls1046aqds.h @@ -435,7 +435,7 @@ unsigned long get_board_ddr_clk(void); #ifdef CONFIG_NAND_BOOT #define CONFIG_ENV_SIZE 0x2000 -#define CONFIG_ENV_OFFSET (24 * CONFIG_SYS_NAND_BLOCK_SIZE) +#define CONFIG_ENV_OFFSET (12 * CONFIG_SYS_NAND_BLOCK_SIZE) #elif defined(CONFIG_SD_BOOT) #define CONFIG_ENV_OFFSET (3 * 1024 * 1024) #define CONFIG_SYS_MMC_ENV_DEV 0 -- cgit v1.2.3 From 4912551bb04f6ae19b8d8418c51791ad2670f8bf Mon Sep 17 00:00:00 2001 From: Fabio Estevam Date: Thu, 28 Sep 2017 13:24:30 -0300 Subject: armv7: ls1021aiot: Move CONFIG_CMD_BOOTZ to Kconfig CONFIG_CMD_BOOTZ symbol does not work in board config file anymore, so fix this by moving it to Kconfig. Signed-off-by: Fabio Estevam Reviewed-by: York Sun --- include/configs/ls1021aiot.h | 1 - 1 file changed, 1 deletion(-) (limited to 'include') diff --git a/include/configs/ls1021aiot.h b/include/configs/ls1021aiot.h index 3fe7b8f44c1..906697f5aa5 100644 --- a/include/configs/ls1021aiot.h +++ b/include/configs/ls1021aiot.h @@ -280,7 +280,6 @@ #define CONFIG_OF_BOARD_SETUP #define CONFIG_OF_STDOUT_VIA_ALIAS -#define CONFIG_CMD_BOOTZ #define CONFIG_MISC_INIT_R -- cgit v1.2.3 From c48deb9073da50f2dd7fa9d7ce951b1fe4dfaec7 Mon Sep 17 00:00:00 2001 From: Bogdan Purcareata Date: Thu, 5 Oct 2017 06:56:53 +0000 Subject: armv8: ls1088a: Update MC boot sequence The MC boot sequence is contained in mc_env_boot. Update LS1088A boards to use this function, and hook it to reset_phy so that it's called late enough, after the ports have been initialized, for proper DPC / DPL fixup. Signed-off-by: Bogdan Purcareata Reviewed-by: York Sun --- include/configs/ls1088a_common.h | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'include') diff --git a/include/configs/ls1088a_common.h b/include/configs/ls1088a_common.h index 84e9b140d09..fa058f7e525 100644 --- a/include/configs/ls1088a_common.h +++ b/include/configs/ls1088a_common.h @@ -122,6 +122,12 @@ unsigned long long get_qixis_addr(void); #define CONFIG_SYS_LS_MC_DRAM_DPL_OFFSET 0x00F20000 #define CONFIG_SYS_LS_MC_AIOP_IMG_MAX_LENGTH 0x200000 #define CONFIG_SYS_LS_MC_DRAM_AIOP_IMG_OFFSET 0x07000000 + +/* Define phy_reset function to boot the MC based on mcinitcmd. + * This happens late enough to properly fixup u-boot env MAC addresses. + */ +#define CONFIG_RESET_PHY_R + /* * Carve out a DDR region which will not be used by u-boot/Linux * -- cgit v1.2.3 From d1fc0a31b5f307c92b7a047d4f90d5ad2e54cdcc Mon Sep 17 00:00:00 2001 From: York Sun Date: Thu, 28 Sep 2017 08:42:10 -0700 Subject: spl: fix assignment of board info to global data Commit 15eb1d43bf47 ("spl: reorder the assignment of board info to global data") intended to move assignment of board info earlier, into board_init_r(). However, function preload_console_init() is called either from spl_board_init() or from board_init_f(). For the latter case, the board info assignment is much earlier than proposed board_init_r(). Create a new function to fill gd->bd and call this function when needed. Signed-off-by: York Sun CC: Lokesh Vutla CC: Ravi Babu CC: Lukasz Majewski CC: Tom Rini Reviewed-by: Simon Glass --- include/spl.h | 1 + 1 file changed, 1 insertion(+) (limited to 'include') diff --git a/include/spl.h b/include/spl.h index ce4cf0abbeb..b14a29c57cc 100644 --- a/include/spl.h +++ b/include/spl.h @@ -68,6 +68,7 @@ int spl_load_simple_fit(struct spl_image_info *spl_image, void preloader_console_init(void); u32 spl_boot_device(void); u32 spl_boot_mode(const u32 boot_device); +void spl_set_bd(void); /** * spl_set_header_raw_uboot() - Set up a standard SPL image structure -- cgit v1.2.3 From f554411beaa30aa34e75baddb8a906dc06986922 Mon Sep 17 00:00:00 2001 From: York Sun Date: Thu, 28 Sep 2017 08:42:13 -0700 Subject: armv8: ls1043ardb: Use static DDR setting for SPL boot This board has soldered DDR chips. To reduce the SPL image size, use static DDR setting instead of dynamic DDR driver. Signed-off-by: York Sun --- include/configs/ls1043ardb.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/configs/ls1043ardb.h b/include/configs/ls1043ardb.h index ca1d862479c..da87497d0a1 100644 --- a/include/configs/ls1043ardb.h +++ b/include/configs/ls1043ardb.h @@ -28,13 +28,13 @@ #define CONFIG_SYS_SPD_BUS_NUM 0 -#define CONFIG_FSL_DDR_BIST #ifndef CONFIG_SPL -#define CONFIG_FSL_DDR_INTERACTIVE /* Interactive debugging */ -#endif #define CONFIG_SYS_DDR_RAW_TIMING +#define CONFIG_FSL_DDR_INTERACTIVE /* Interactive debugging */ +#define CONFIG_FSL_DDR_BIST #define CONFIG_ECC_INIT_VIA_DDRCONTROLLER #define CONFIG_MEM_INIT_VALUE 0xdeadbeef +#endif #ifdef CONFIG_RAMBOOT_PBL #define CONFIG_SYS_FSL_PBL_PBI board/freescale/ls1043ardb/ls1043ardb_pbi.cfg -- cgit v1.2.3 From 23af484b0156baaafd578222d73513418df78f09 Mon Sep 17 00:00:00 2001 From: York Sun Date: Thu, 28 Sep 2017 08:42:16 -0700 Subject: armv8: ls1043ardb_sdcard: prepare falcon boot Due to a conflict with recent Primary Protected Application (PPA), PPA cannot be loaded for SPL stage, falcon boot is not enabled by default. With compatible PPA image, to enable falcon boot, activate these Kconfig options in defconfig CONFIG_SPL_FIT=y CONFIG_SPL_FSL_LS_PPA=y CONFIG_SPL_GZIP=y CONFIG_SPL_LOAD_FIT=y CONFIG_SPL_OS_BOOT=y CONFIG_SPL_OF_LIBFDT=y Because environment variables are not avaiable during SPL stage for SD boot, set "boot_os=y" as default. Signed-off-by: York Sun Reviewed-by: Simon Glass --- include/configs/ls1043a_common.h | 7 ++++--- include/configs/ls1043ardb.h | 5 +++++ 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'include') diff --git a/include/configs/ls1043a_common.h b/include/configs/ls1043a_common.h index 1f9efffa562..a29713499b5 100644 --- a/include/configs/ls1043a_common.h +++ b/include/configs/ls1043a_common.h @@ -73,10 +73,10 @@ #define CONFIG_SPL_STACK 0x1001e000 #define CONFIG_SPL_PAD_TO 0x1d000 -#define CONFIG_SYS_SPL_MALLOC_START (CONFIG_SYS_TEXT_BASE + \ - CONFIG_SYS_MONITOR_LEN) +#define CONFIG_SYS_SPL_MALLOC_START (CONFIG_SPL_BSS_START_ADDR + \ + CONFIG_SPL_BSS_MAX_SIZE) #define CONFIG_SYS_SPL_MALLOC_SIZE 0x100000 -#define CONFIG_SPL_BSS_START_ADDR 0x80100000 +#define CONFIG_SPL_BSS_START_ADDR 0x8f000000 #define CONFIG_SPL_BSS_MAX_SIZE 0x80000 #ifdef CONFIG_SECURE_BOOT @@ -280,6 +280,7 @@ "load_addr=0xa0000000\0" \ "kernel_size=0x2800000\0" \ "console=ttyS0,115200\0" \ + "boot_os=y\0" \ "mtdparts=" MTDPARTS_DEFAULT "\0" \ BOOTENV \ "boot_scripts=ls1043ardb_boot.scr\0" \ diff --git a/include/configs/ls1043ardb.h b/include/configs/ls1043ardb.h index da87497d0a1..f9843f5ebae 100644 --- a/include/configs/ls1043ardb.h +++ b/include/configs/ls1043ardb.h @@ -46,6 +46,11 @@ #ifdef CONFIG_SD_BOOT #define CONFIG_SYS_FSL_PBL_RCW board/freescale/ls1043ardb/ls1043ardb_rcw_sd.cfg +#define CONFIG_CMD_SPL +#define CONFIG_SYS_SPL_ARGS_ADDR 0x90000000 +#define CONFIG_SYS_MMCSD_RAW_MODE_KERNEL_SECTOR 0x10000 +#define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTOR 0x500 +#define CONFIG_SYS_MMCSD_RAW_MODE_ARGS_SECTORS 30 #endif /* -- cgit v1.2.3