diff options
author | Adrian Alonso <adrian.alonso@nxp.com> | 2016-09-07 18:00:54 -0500 |
---|---|---|
committer | Ye Li <ye.li@nxp.com> | 2017-04-05 19:48:56 +0800 |
commit | 41a5d28743c67de411a0d723418f36589a224d1b (patch) | |
tree | 2bbc618b257f6ff6c2c7867623f53e6cf90f76d8 | |
parent | 4d226b92b3dd577bf02c11d1e0d32494b68a5a66 (diff) | |
download | u-boot-imx-41a5d28743c67de411a0d723418f36589a224d1b.zip u-boot-imx-41a5d28743c67de411a0d723418f36589a224d1b.tar.gz u-boot-imx-41a5d28743c67de411a0d723418f36589a224d1b.tar.bz2 |
MLK-13130: configs: mx6qarm2: android lpddr2 pop support
Add Android support for mx6qarm2 lpddr2 pop target
Signed-off-by: Adrian Alonso <adrian.alonso@nxp.com>
(cherry picked from commit 6356f2b420f3571493755f6b3a307a66a539b60c)
-rw-r--r-- | cmd/read.c | 2 | ||||
-rw-r--r-- | configs/mx6qarm2android_pop_lpddr2_revb_defconfig | 45 | ||||
-rw-r--r-- | include/configs/mx6qarm2.h | 6 | ||||
-rw-r--r-- | include/configs/mx6qarm2_android.h | 76 | ||||
-rw-r--r-- | scripts/config_whitelist.txt | 4 |
5 files changed, 131 insertions, 2 deletions
@@ -66,7 +66,7 @@ int do_read(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) return 1; } - if (blk_read(dev_desc, offset + blk, cnt, addr) < 0) { + if (blk_dread(dev_desc, offset + blk, cnt, addr) < 0) { printf("Error reading blocks\n"); return 1; } diff --git a/configs/mx6qarm2android_pop_lpddr2_revb_defconfig b/configs/mx6qarm2android_pop_lpddr2_revb_defconfig new file mode 100644 index 0000000..8468413 --- /dev/null +++ b/configs/mx6qarm2android_pop_lpddr2_revb_defconfig @@ -0,0 +1,45 @@ +CONFIG_ARM=y +CONFIG_ARCH_MX6=y +CONFIG_TARGET_MX6QARM2=y +CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6qarm2/mt128x64mx32.cfg,MX6Q,MX6DQ_POP_LPDDR2,DDR_MB=512" +CONFIG_FASTBOOT=y +CONFIG_EFI_PARTITION=y +CONFIG_BOOTDELAY=3 +CONFIG_BOARD_EARLY_INIT_F=y +CONFIG_HUSH_PARSER=y +CONFIG_CMD_BOOTZ=y +# CONFIG_CMD_IMLS is not set +# CONFIG_CMD_FLASH is not set +CONFIG_CMD_MEMTEST=y +CONFIG_CMD_MMC=y +CONFIG_CMD_USB=y +CONFIG_CMD_GPIO=y +# CONFIG_CMD_SETEXPR is not set +CONFIG_CMD_DHCP=y +CONFIG_CMD_MII=y +CONFIG_CMD_PING=y +CONFIG_CMD_CACHE=y +CONFIG_CMD_EXT2=y +CONFIG_CMD_EXT4=y +CONFIG_CMD_EXT4_WRITE=y +CONFIG_CMD_FAT=y +CONFIG_CMD_FS_GENERIC=y +CONFIG_USB=y +CONFIG_USB_STORAGE=y +# CONFIG_OF_LIBFDT=y + +CONFIG_DEFAULT_DEVICE_TREE="imx6q-pop-arm2" +CONFIG_DEFAULT_FDT_FILE="imx6q-pop-arm2.dtb" +CONFIG_OF_CONTROL=y +# CONFIG_BLK is not set +CONFIG_DM_GPIO=y +CONFIG_DM_I2C=y +CONFIG_DM_MMC=y +# CONFIG_DM_MMC_OPS is not set +CONFIG_PINCTRL=y +CONFIG_PINCTRL_IMX6=y +CONFIG_DM_REGULATOR=y +CONFIG_DM_REGULATOR_FIXED=y +CONFIG_DM_REGULATOR_GPIO=y +CONFIG_DM_ETH=y +CONFIG_DM_USB=y diff --git a/include/configs/mx6qarm2.h b/include/configs/mx6qarm2.h index f496be9..1edd300 100644 --- a/include/configs/mx6qarm2.h +++ b/include/configs/mx6qarm2.h @@ -152,4 +152,8 @@ #define CONFIG_USB_MAX_CONTROLLER_COUNT 1 #endif -#endif /* __CONFIG_H */ +#if defined(CONFIG_FASTBOOT) +#include "mx6qarm2_android.h" +#endif + +#endif /* __CONFIG_H */ diff --git a/include/configs/mx6qarm2_android.h b/include/configs/mx6qarm2_android.h new file mode 100644 index 0000000..3dc13bf --- /dev/null +++ b/include/configs/mx6qarm2_android.h @@ -0,0 +1,76 @@ +/* + * Copyright (C) 2013-2016 Freescale Semiconductor, Inc. All Rights Reserved. + * + * SPDX-License-Identifier: GPL-2.0+ + */ + +#ifndef IMX6Q_ARM2_ANDROID_H +#define IMX6Q_ARM2_ANDROID_H + +#define CONFIG_CI_UDC +#define CONFIG_USBD_HS +#define CONFIG_USB_GADGET_DUALSPEED + +#define CONFIG_USB_GADGET +#define CONFIG_CMD_USB_MASS_STORAGE +#define CONFIG_USB_FUNCTION_MASS_STORAGE +#define CONFIG_USB_GADGET_DOWNLOAD +#define CONFIG_USB_GADGET_VBUS_DRAW 2 + +#define CONFIG_G_DNL_VENDOR_NUM 0x18d1 +#define CONFIG_G_DNL_PRODUCT_NUM 0x0d02 +#define CONFIG_G_DNL_MANUFACTURER "FSL" + +#define CONFIG_USB_FUNCTION_FASTBOOT +#define CONFIG_CMD_FASTBOOT +#define CONFIG_CMD_READ +#define CONFIG_BCB_SUPPORT +#define CONFIG_ANDROID_BOOT_IMAGE +#define CONFIG_FASTBOOT_FLASH + +/* For NAND we don't support lock/unlock */ +#ifndef CONFIG_SYS_BOOT_NAND +#define CONFIG_FASTBOOT_LOCK +#endif + +#define FSL_FASTBOOT_FB_DEV "mmc" +#define FSL_FASTBOOT_DATA_PART_NUM 4 +#define FSL_FASTBOOT_FB_PART_NUM 11 +#define FSL_FASTBOOT_PR_DATA_PART_NUM 12 + +#define CONFIG_FSL_CAAM_KB +#define CONFIG_CMD_FSL_CAAM_KB +#define CONFIG_SHA1 +#define CONFIG_SHA256 + +#define CONFIG_FSL_FASTBOOT +#define CONFIG_ANDROID_RECOVERY + +#if defined CONFIG_SYS_BOOT_NAND +#define CONFIG_FASTBOOT_STORAGE_NAND +#elif defined CONFIG_SYS_BOOT_SATA +#define CONFIG_FASTBOOT_STORAGE_SATA +#else +#define CONFIG_FASTBOOT_STORAGE_MMC +#endif + +#if defined(CONFIG_FASTBOOT_STORAGE_NAND) +#define ANDROID_FASTBOOT_NAND_PARTS "16m@64m(boot) 16m@80m(recovery) 810m@96m(android_root)ubifs" +#endif + +#define CONFIG_CMD_BOOTA +#define CONFIG_SUPPORT_RAW_INITRD +#define CONFIG_SERIAL_TAG + +#undef CONFIG_EXTRA_ENV_SETTINGS +#undef CONFIG_BOOTCOMMAND + +#define CONFIG_EXTRA_ENV_SETTINGS \ + "splashpos=m,m\0" \ + "fdt_high=0xffffffff\0" \ + "initrd_high=0xffffffff\0" \ + +#define CONFIG_FASTBOOT_BUF_ADDR CONFIG_SYS_LOAD_ADDR +#define CONFIG_FASTBOOT_BUF_SIZE 0x19000000 + +#endif /* IMX6Q_ARM2_ANDROID_H */ diff --git a/scripts/config_whitelist.txt b/scripts/config_whitelist.txt index 09f01a6..a2e2b28 100644 --- a/scripts/config_whitelist.txt +++ b/scripts/config_whitelist.txt @@ -226,6 +226,7 @@ CONFIG_BAT_CMD CONFIG_BAT_PAIR CONFIG_BAT_RW CONFIG_BAUDRATE +CONFIG_BCB_SUPPORT CONFIG_BCH CONFIG_BCH_CONST_M CONFIG_BCH_CONST_PARAMS @@ -488,6 +489,7 @@ CONFIG_CMD_FPGA_LOADBP CONFIG_CMD_FPGA_LOADFS CONFIG_CMD_FPGA_LOADMK CONFIG_CMD_FPGA_LOADP +CONFIG_CMD_FSL_CAAM_KB CONFIG_CMD_FUSE CONFIG_CMD_GETTIME CONFIG_CMD_GSC @@ -1066,6 +1068,7 @@ CONFIG_FACTORYSET CONFIG_FASTBOOT_FLASH_FILLBUF_SIZE CONFIG_FASTBOOT_FLASH_NAND_DEV CONFIG_FASTBOOT_FLASH_NAND_TRIMFFS +CONFIG_FASTBOOT_LOCK CONFIG_FAST_FLASH_BIT CONFIG_FAT_WRITE CONFIG_FB_ADDR @@ -1135,6 +1138,7 @@ CONFIG_FPGA_SPARTAN3 CONFIG_FPGA_STRATIX_V CONFIG_FPGA_ZYNQPL CONFIG_FSLDMAFEC +CONFIG_FSL_CAAM_KB CONFIG_FSL_CADMUS CONFIG_FSL_CORENET CONFIG_FSL_CPLD |