summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/ansi.h2
-rw-r--r--include/charset.h49
-rw-r--r--include/clk.h12
-rw-r--r--include/configs/devkit3250.h5
-rw-r--r--include/configs/imx8mm_beacon.h152
-rw-r--r--include/configs/imx8qm_mek.h2
-rw-r--r--include/configs/imx8qxp_mek.h2
-rw-r--r--include/configs/nokia_rx51.h88
-rw-r--r--include/configs/pico-imx8mq.h199
-rw-r--r--include/configs/ti_armv7_common.h2
-rw-r--r--include/configs/work_92105.h5
-rw-r--r--include/cpu.h23
-rw-r--r--include/dm/uclass-id.h1
-rw-r--r--include/dt-bindings/soc/imx_rsrc.h1
-rw-r--r--include/efi_selftest.h110
-rw-r--r--include/eth_phy.h17
-rw-r--r--include/generic-phy.h9
-rw-r--r--include/linux/iopoll.h16
-rw-r--r--include/mxs_nand.h18
-rw-r--r--include/spl.h1
20 files changed, 571 insertions, 143 deletions
diff --git a/include/ansi.h b/include/ansi.h
index e90a697eaf9..af1a3712c85 100644
--- a/include/ansi.h
+++ b/include/ansi.h
@@ -1,7 +1,7 @@
/* SPDX-License-Identifier: GPL-2.0+ */
/*
* (C) Copyright 2012
- * Pali Rohár <pali.rohar@gmail.com>
+ * Pali Rohár <pali@kernel.org>
*/
/*
diff --git a/include/charset.h b/include/charset.h
index fde6bddbc2f..5564f3bce56 100644
--- a/include/charset.h
+++ b/include/charset.h
@@ -55,7 +55,7 @@ size_t utf8_utf16_strnlen(const char *src, size_t count);
/**
* utf8_utf16_strlen() - length of a utf-8 string after conversion to utf-16
*
- * @src: utf-8 string
+ * @a: utf-8 string
* Return: length in u16 after conversion to utf-16 without the
* trailing \0. If an invalid UTF-8 sequence is hit one
* u16 will be reserved for a replacement character.
@@ -75,8 +75,8 @@ int utf8_utf16_strncpy(u16 **dst, const char *src, size_t count);
/**
* utf8_utf16_strcpy() - copy utf-8 string to utf-16 string
*
- * @dst: destination buffer
- * @src: source buffer
+ * @d: destination buffer
+ * @s: source buffer
* Return: -1 if the input parameters are invalid
*/
#define utf8_utf16_strcpy(d, s) utf8_utf16_strncpy((d), (s), SIZE_MAX)
@@ -126,7 +126,7 @@ size_t utf16_utf8_strnlen(const u16 *src, size_t count);
/**
* utf16_utf8_strlen() - length of a utf-16 string after conversion to utf-8
*
- * @src: utf-16 string
+ * @a: utf-16 string
* Return: length in bytes after conversion to utf-8 without the
* trailing \0. If an invalid UTF-16 sequence is hit one
* byte will be reserved for a replacement character.
@@ -146,8 +146,8 @@ int utf16_utf8_strncpy(char **dst, const u16 *src, size_t count);
/**
* utf16_utf8_strcpy() - copy utf-16 string to utf-8 string
*
- * @dst: destination buffer
- * @src: source buffer
+ * @d: destination buffer
+ * @s: source buffer
* Return: -1 if the input parameters are invalid
*/
#define utf16_utf8_strcpy(d, s) utf16_utf8_strncpy((d), (s), SIZE_MAX)
@@ -168,7 +168,7 @@ s32 utf_to_lower(const s32 code);
*/
s32 utf_to_upper(const s32 code);
-/*
+/**
* u16_strncmp() - compare two u16 string
*
* @s1: first string to compare
@@ -181,6 +181,18 @@ s32 utf_to_upper(const s32 code);
* corresponding u16 in s2
*/
int u16_strncmp(const u16 *s1, const u16 *s2, size_t n);
+
+/**
+ * u16_strcmp() - compare two u16 string
+ *
+ * @s1: first string to compare
+ * @s2: second string to compare
+ * Return: 0 if the first n u16 are the same in s1 and s2
+ * < 0 if the first different u16 in s1 is less than the
+ * corresponding u16 in s2
+ * > 0 if the first different u16 in s1 is greater than the
+ * corresponding u16 in s2
+ */
#define u16_strcmp(s1, s2) u16_strncmp((s1), (s2), SIZE_MAX)
/**
@@ -190,12 +202,23 @@ int u16_strncmp(const u16 *s1, const u16 *s2, size_t n);
* In the EFI context we explicitly need a function handling u16 strings.
*
* @in: null terminated u16 string
- * ReturnValue: number of non-zero words.
+ * Return: number of non-zero words.
* This is not the number of utf-16 letters!
*/
size_t u16_strlen(const void *in);
/**
+ * u16_strsize() - count size of u16 string in bytes including the null
+ * character
+ *
+ * Counts the number of bytes occupied by a u16 string
+ *
+ * @in: null terminated u16 string
+ * Return: bytes in a u16 string
+ */
+size_t u16_strsize(const void *in);
+
+/**
* u16_strlen - count non-zero words
*
* This function matches wscnlen_s() if the -fshort-wchar compiler flag is set.
@@ -203,7 +226,7 @@ size_t u16_strlen(const void *in);
*
* @in: null terminated u16 string
* @count: maximum number of words to count
- * ReturnValue: number of non-zero words.
+ * Return: number of non-zero words.
* This is not the number of utf-16 letters!
*/
size_t u16_strnlen(const u16 *in, size_t count);
@@ -240,10 +263,10 @@ u16 *u16_strdup(const void *src);
* NOTE that a single utf16 character can generate up to 3 utf8
* characters. See MAX_UTF8_PER_UTF16.
*
- * @dest the destination buffer to write the utf8 characters
- * @src the source utf16 string
- * @size the number of utf16 characters to convert
- * @return the pointer to the first unwritten byte in 'dest'
+ * @dest: the destination buffer to write the utf8 characters
+ * @src: the source utf16 string
+ * @size: the number of utf16 characters to convert
+ * Return: the pointer to the first unwritten byte in 'dest'
*/
uint8_t *utf16_to_utf8(uint8_t *dest, const uint16_t *src, size_t size);
diff --git a/include/clk.h b/include/clk.h
index 60c4b7d075f..c6a2713f624 100644
--- a/include/clk.h
+++ b/include/clk.h
@@ -93,7 +93,7 @@ int clk_get_by_index_platdata(struct udevice *dev, int index,
struct phandle_1_arg *cells, struct clk *clk);
/**
- * clock_get_by_index - Get/request a clock by integer index.
+ * clk_get_by_index - Get/request a clock by integer index.
*
* This looks up and requests a clock. The index is relative to the client
* device; each device is assumed to have n clocks associated with it somehow,
@@ -110,7 +110,7 @@ int clk_get_by_index_platdata(struct udevice *dev, int index,
int clk_get_by_index(struct udevice *dev, int index, struct clk *clk);
/**
- * clock_get_by_index_nodev - Get/request a clock by integer index
+ * clk_get_by_index_nodev - Get/request a clock by integer index
* without a device.
*
* This is a version of clk_get_by_index() that does not use a device.
@@ -124,7 +124,7 @@ int clk_get_by_index(struct udevice *dev, int index, struct clk *clk);
int clk_get_by_index_nodev(ofnode node, int index, struct clk *clk);
/**
- * clock_get_bulk - Get/request all clocks of a device.
+ * clk_get_bulk - Get/request all clocks of a device.
*
* This looks up and requests all clocks of the client device; each device is
* assumed to have n clocks associated with it somehow, and this function finds
@@ -139,7 +139,7 @@ int clk_get_by_index_nodev(ofnode node, int index, struct clk *clk);
int clk_get_bulk(struct udevice *dev, struct clk_bulk *bulk);
/**
- * clock_get_by_name - Get/request a clock by name.
+ * clk_get_by_name - Get/request a clock by name.
*
* This looks up and requests a clock. The name is relative to the client
* device; each device is assumed to have n clocks associated with it somehow,
@@ -169,7 +169,7 @@ int clk_get_by_name(struct udevice *dev, const char *name, struct clk *clk);
int clk_get_by_name_nodev(ofnode node, const char *name, struct clk *clk);
/**
- * clock_get_optional_nodev - Get/request an optinonal clock by name
+ * clk_get_optional_nodev - Get/request an optinonal clock by name
* without a device.
* @node: The client ofnode.
* @name: The name of the clock to request.
@@ -331,7 +331,7 @@ static inline int clk_release_bulk(struct clk_bulk *bulk)
int clk_request(struct udevice *dev, struct clk *clk);
/**
- * clock_free - Free a previously requested clock.
+ * clk_free - Free a previously requested clock.
*
* @clock: A clock struct that was previously successfully requested by
* clk_request/get_by_*().
diff --git a/include/configs/devkit3250.h b/include/configs/devkit3250.h
index f1f2be0797b..4471a12f34d 100644
--- a/include/configs/devkit3250.h
+++ b/include/configs/devkit3250.h
@@ -55,11 +55,6 @@
#define CONFIG_LPC32XX_GPIO
/*
- * SSP/SPI
- */
-#define CONFIG_LPC32XX_SSP_TIMEOUT 100000
-
-/*
* Ethernet
*/
#define CONFIG_RMII
diff --git a/include/configs/imx8mm_beacon.h b/include/configs/imx8mm_beacon.h
new file mode 100644
index 00000000000..21102d3c14d
--- /dev/null
+++ b/include/configs/imx8mm_beacon.h
@@ -0,0 +1,152 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright 2020 Compass Electronics Group, LLC
+ */
+
+#ifndef __IMX8MM_BEACON_H
+#define __IMX8MM_BEACON_H
+
+#include <linux/sizes.h>
+#include <asm/arch/imx-regs.h>
+
+#ifdef CONFIG_SECURE_BOOT
+#define CONFIG_CSF_SIZE SZ_8K
+#endif
+
+#define CONFIG_SPL_MAX_SIZE (148 * 1024)
+#define CONFIG_SYS_MONITOR_LEN SZ_512K
+#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
+#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300
+#define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1
+#define CONFIG_SYS_UBOOT_BASE \
+ (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)
+
+#ifdef CONFIG_SPL_BUILD
+#define CONFIG_SPL_STACK 0x920000
+#define CONFIG_SPL_BSS_START_ADDR 0x910000
+#define CONFIG_SPL_BSS_MAX_SIZE SZ_8K /* 8 KB */
+#define CONFIG_SYS_SPL_MALLOC_START 0x42200000
+#define CONFIG_SYS_SPL_MALLOC_SIZE SZ_512K /* 512 KB */
+
+/* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
+#define CONFIG_MALLOC_F_ADDR 0x930000
+/* For RAW image gives a error info not panic */
+#define CONFIG_SPL_ABORT_ON_RAW_IMAGE
+
+#endif
+
+/* Initial environment variables */
+#define CONFIG_EXTRA_ENV_SETTINGS \
+ "script=boot.scr\0" \
+ "image=Image\0" \
+ "console=ttymxc1,115200\0" \
+ "fdt_addr=0x43000000\0" \
+ "fdt_high=0xffffffffffffffff\0" \
+ "boot_fit=try\0" \
+ "fdt_file=" CONFIG_DEFAULT_FDT_FILE "\0" \
+ "initrd_addr=0x43800000\0" \
+ "initrd_high=0xffffffffffffffff\0" \
+ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \
+ "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
+ "finduuid=part uuid mmc ${mmcdev}:2 uuid\0" \
+ "mmcautodetect=yes\0" \
+ "mmcargs=setenv bootargs console=${console},${baudrate}" \
+ " root=PARTUUID=${uuid} rootwait rw ${mtdparts} ${optargs}\0" \
+ "loadbootscript=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr}" \
+ " ${script};\0" \
+ "bootscript=echo Running bootscript from mmc ...; " \
+ "source\0" \
+ "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
+ "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
+ "mmcboot=echo Booting from mmc ...; " \
+ "run finduuid; " \
+ "run mmcargs; " \
+ "if run loadfdt; then " \
+ "booti ${loadaddr} - ${fdt_addr}; " \
+ "else " \
+ "echo WARN: Cannot load the DT; " \
+ "fi; " \
+ "netargs=setenv bootargs console=${console} " \
+ "root=/dev/nfs " \
+ "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
+ "netboot=echo Booting from net ...; " \
+ "run netargs; " \
+ "if test ${ip_dyn} = yes; then " \
+ "setenv get_cmd dhcp; " \
+ "else " \
+ "setenv get_cmd tftp; " \
+ "fi; " \
+ "${get_cmd} ${loadaddr} ${image}; " \
+ "if test ${boot_fit} = yes || test ${boot_fit} = try; then " \
+ "bootm ${loadaddr}; " \
+ "else " \
+ "if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \
+ "booti ${loadaddr} - ${fdt_addr}; " \
+ "else " \
+ "echo WARN: Cannot load the DT; " \
+ "fi; " \
+ "fi;\0"
+
+#define CONFIG_BOOTCOMMAND \
+ "mmc dev ${mmcdev}; if mmc rescan; then " \
+ "if run loadbootscript; then " \
+ "run bootscript; " \
+ "else " \
+ "if run loadimage; then " \
+ "run mmcboot; " \
+ "else run netboot; " \
+ "fi; " \
+ "fi; " \
+ "fi;"
+
+/* Link Definitions */
+#define CONFIG_LOADADDR 0x40480000
+
+#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
+
+#define CONFIG_SYS_INIT_RAM_ADDR 0x40000000
+#define CONFIG_SYS_INIT_RAM_SIZE 0x200000
+#define CONFIG_SYS_INIT_SP_OFFSET \
+ (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
+#define CONFIG_SYS_INIT_SP_ADDR \
+ (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
+
+#define CONFIG_ENV_OVERWRITE
+#define CONFIG_SYS_MMC_ENV_DEV 1 /* USDHC2 */
+
+/* Size of malloc() pool */
+#define CONFIG_SYS_MALLOC_LEN SZ_32M
+
+#define CONFIG_SYS_SDRAM_BASE 0x40000000
+#define PHYS_SDRAM 0x40000000
+#define PHYS_SDRAM_SIZE 0x80000000 /* 2GB DDR */
+
+#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM
+#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + (PHYS_SDRAM_SIZE >> 1))
+
+#define CONFIG_MXC_UART_BASE UART2_BASE_ADDR
+
+/* Monitor Command Prompt */
+#define CONFIG_SYS_PROMPT_HUSH_PS2 "> "
+#define CONFIG_SYS_CBSIZE 2048
+#define CONFIG_SYS_MAXARGS 64
+#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
+#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + \
+ sizeof(CONFIG_SYS_PROMPT) + 16)
+
+/* USDHC */
+#define CONFIG_SYS_FSL_USDHC_NUM 2
+#define CONFIG_SYS_FSL_ESDHC_ADDR 0
+#define CONFIG_SYS_MMC_IMG_LOAD_PART 1
+
+/* I2C */
+#define CONFIG_SYS_I2C_SPEED 100000
+
+/* FEC*/
+#define CONFIG_ETHPRIME "FEC"
+#define CONFIG_FEC_XCV_TYPE RGMII
+#define CONFIG_FEC_MXC_PHYADDR 0
+#define FEC_QUIRK_ENET_MAC
+#define IMX_FEC_BASE 0x30BE0000
+
+#endif
diff --git a/include/configs/imx8qm_mek.h b/include/configs/imx8qm_mek.h
index 97170dc9494..22d80f1747b 100644
--- a/include/configs/imx8qm_mek.h
+++ b/include/configs/imx8qm_mek.h
@@ -70,7 +70,7 @@
"fdt_addr=0x83000000\0" \
"fdt_high=0xffffffffffffffff\0" \
"boot_fdt=try\0" \
- "fdt_file=imx8qm-mek.dtb\0" \
+ "fdt_file=undefined\0" \
"initrd_addr=0x83800000\0" \
"initrd_high=0xffffffffffffffff\0" \
"mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
diff --git a/include/configs/imx8qxp_mek.h b/include/configs/imx8qxp_mek.h
index 0aaca3325bd..341e93e61e7 100644
--- a/include/configs/imx8qxp_mek.h
+++ b/include/configs/imx8qxp_mek.h
@@ -69,7 +69,7 @@
"fdt_addr=0x83000000\0" \
"fdt_high=0xffffffffffffffff\0" \
"boot_fdt=try\0" \
- "fdt_file=imx8qxp-mek.dtb\0" \
+ "fdt_file=undefined\0" \
"initrd_addr=0x83800000\0" \
"initrd_high=0xffffffffffffffff\0" \
"mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
diff --git a/include/configs/nokia_rx51.h b/include/configs/nokia_rx51.h
index 5d1c7bf8353..a9a0b1c9988 100644
--- a/include/configs/nokia_rx51.h
+++ b/include/configs/nokia_rx51.h
@@ -1,7 +1,7 @@
/* SPDX-License-Identifier: GPL-2.0+ */
/*
* (C) Copyright 2011-2012
- * Pali Rohár <pali.rohar@gmail.com>
+ * Pali Rohár <pali@kernel.org>
*
* (C) Copyright 2010
* Alistair Buxton <a.j.buxton@gmail.com>
@@ -25,12 +25,6 @@
#define CONFIG_MACH_TYPE MACH_TYPE_NOKIA_RX51
-/*
- * Nokia X-Loader loading secondary image to address 0x80400000
- * NOLO loading boot image to random place, so it doesn't really
- * matter what we set this to. We have to copy u-boot to this address
- */
-
#include <asm/arch/cpu.h> /* get chip and board defs */
#include <asm/arch/omap.h>
#include <asm/arch/mem.h>
@@ -97,54 +91,8 @@
* Board ONENAND Info.
*/
-#define PART1_NAME "bootloader"
-#define PART1_SIZE 128
-#define PART1_MULL 1024
-#define PART1_SUFF "k"
-#define PART1_OFFS 0x00000000
-#define PART1_MASK 0x00000003
-
-#define PART2_NAME "config"
-#define PART2_SIZE 384
-#define PART2_MULL 1024
-#define PART2_SUFF "k"
-#define PART2_OFFS 0x00020000
-#define PART2_MASK 0x00000000
-
-#define PART3_NAME "log"
-#define PART3_SIZE 256
-#define PART3_MULL 1024
-#define PART3_SUFF "k"
-#define PART3_OFFS 0x00080000
-#define PART3_MASK 0x00000000
-
-#define PART4_NAME "kernel"
-#define PART4_SIZE 2
-#define PART4_MULL 1024*1024
-#define PART4_SUFF "m"
-#define PART4_OFFS 0x000c0000
-#define PART4_MASK 0x00000000
-
-#define PART5_NAME "initfs"
-#define PART5_SIZE 2
-#define PART5_MULL 1024*1024
-#define PART5_SUFF "m"
-#define PART5_OFFS 0x002c0000
-#define PART5_MASK 0x00000000
-
-#define PART6_NAME "rootfs"
-#define PART6_SIZE 257280
-#define PART6_MULL 1024
-#define PART6_SUFF "k"
-#define PART6_OFFS 0x004c0000
-#define PART6_MASK 0x00000000
-
-#ifdef ONENAND_SUPPORT
-
#define CONFIG_SYS_ONENAND_BASE ONENAND_MAP
-#endif
-
/* Watchdog support */
#define CONFIG_HW_WATCHDOG
@@ -169,17 +117,11 @@ int rx51_kp_getc(struct stdio_dev *sdev);
#endif
/* Environment information */
-#ifdef CONFIG_MTDPARTS_DEFAULT
-#define MTDPARTS "mtdparts=" CONFIG_MTDPARTS_DEFAULT "\0"
-#else
-#define MTDPARTS
-#endif
#define CONFIG_EXTRA_ENV_SETTINGS \
- MTDPARTS \
"usbtty=cdc_acm\0" \
- "stdin=vga\0" \
- "stdout=vga\0" \
- "stderr=vga\0" \
+ "stdin=serial,vga\0" \
+ "stdout=serial,vga\0" \
+ "stderr=serial,vga\0" \
"setcon=setenv stdin ${con};" \
"setenv stdout ${con};" \
"setenv stderr ${con}\0" \
@@ -245,6 +187,28 @@ int rx51_kp_getc(struct stdio_dev *sdev);
"fi\0" \
"emmcboot=setenv mmcnum 1; run trymmcboot\0" \
"sdboot=setenv mmcnum 0; run trymmcboot\0" \
+ "preboot=setenv mmcnum 1; setenv mmcpart 1;" \
+ "setenv mmcscriptfile bootmenu.scr;" \
+ "if run switchmmc; then " \
+ "setenv mmcdone true;" \
+ "setenv mmctype fat;" \
+ "if run scriptload; then true; else " \
+ "setenv mmctype ext2;" \
+ "if run scriptload; then true; else " \
+ "setenv mmctype ext4;" \
+ "if run scriptload; then true; else " \
+ "setenv mmcdone false;" \
+ "fi;" \
+ "fi;" \
+ "fi;" \
+ "if ${mmcdone}; then " \
+ "run scriptboot;" \
+ "fi;" \
+ "fi;" \
+ "if run slide; then true; else " \
+ "setenv bootmenu_delay 0;" \
+ "setenv bootdelay 0;" \
+ "fi\0" \
"menucmd=bootmenu\0" \
"bootmenu_0=Attached kernel=run attachboot\0" \
"bootmenu_1=Internal eMMC=run emmcboot\0" \
diff --git a/include/configs/pico-imx8mq.h b/include/configs/pico-imx8mq.h
new file mode 100644
index 00000000000..a2f80cdd671
--- /dev/null
+++ b/include/configs/pico-imx8mq.h
@@ -0,0 +1,199 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright 2018 NXP
+ */
+
+#ifndef __IMX8M_PICOPI_H
+#define __IMX8M_PICOPI_H
+
+#include <linux/sizes.h>
+#include <asm/arch/imx-regs.h>
+
+#define CONFIG_SPL_MAX_SIZE (124 * 1024)
+#define CONFIG_SYS_MONITOR_LEN (512 * 1024)
+#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
+#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300
+#define CONFIG_SYS_MMCSD_FS_BOOT_PARTITION 1
+
+#ifdef CONFIG_SPL_BUILD
+/*#define CONFIG_ENABLE_DDR_TRAINING_DEBUG*/
+#define CONFIG_SPL_WATCHDOG_SUPPORT
+#define CONFIG_SPL_DRIVERS_MISC_SUPPORT
+#define CONFIG_SPL_POWER_SUPPORT
+#define CONFIG_SPL_I2C_SUPPORT
+#define CONFIG_SPL_LDSCRIPT "arch/arm/cpu/armv8/u-boot-spl.lds"
+#define CONFIG_SPL_STACK 0x187FF0
+#define CONFIG_SPL_LIBCOMMON_SUPPORT
+#define CONFIG_SPL_LIBGENERIC_SUPPORT
+#define CONFIG_SPL_GPIO_SUPPORT
+#define CONFIG_SPL_MMC_SUPPORT
+#define CONFIG_SPL_BSS_START_ADDR 0x00180000
+#define CONFIG_SPL_BSS_MAX_SIZE 0x2000 /* 8 KB */
+#define CONFIG_SYS_SPL_MALLOC_START 0x42200000
+#define CONFIG_SYS_SPL_MALLOC_SIZE 0x80000 /* 512 KB */
+#define CONFIG_SYS_SPL_PTE_RAM_BASE 0x41580000
+
+/* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
+#define CONFIG_MALLOC_F_ADDR 0x182000
+/* For RAW image gives a error info not panic */
+#define CONFIG_SPL_ABORT_ON_RAW_IMAGE
+
+#undef CONFIG_DM_MMC
+#undef CONFIG_DM_PMIC
+
+#define CONFIG_SYS_I2C
+#define CONFIG_SYS_I2C_MXC_I2C1 /* enable I2C bus 1 */
+#define CONFIG_SYS_I2C_MXC_I2C2 /* enable I2C bus 2 */
+#define CONFIG_SYS_I2C_MXC_I2C3 /* enable I2C bus 3 */
+
+#define CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG
+
+#define CONFIG_POWER
+#define CONFIG_POWER_I2C
+#endif
+
+#define CONFIG_REMAKE_ELF
+
+#define CONFIG_BOARD_EARLY_INIT_F
+#define CONFIG_BOARD_LATE_INIT
+
+#undef CONFIG_CMD_EXPORTENV
+#undef CONFIG_CMD_IMPORTENV
+#undef CONFIG_CMD_IMLS
+
+#undef CONFIG_CMD_CRC32
+
+/* ENET Config */
+/* ENET1 */
+#if defined(CONFIG_CMD_NET)
+#define CONFIG_CMD_PING
+#define CONFIG_CMD_DHCP
+#define CONFIG_CMD_MII
+#define CONFIG_MII
+#define CONFIG_ETHPRIME "FEC"
+
+#define CONFIG_FEC_MXC
+#define CONFIG_FEC_XCV_TYPE RGMII
+#define CONFIG_FEC_MXC_PHYADDR 1
+#define FEC_QUIRK_ENET_MAC
+
+#define CONFIG_PHY_GIGE
+#define IMX_FEC_BASE 0x30BE0000
+
+#define CONFIG_PHYLIB
+#define CONFIG_PHY_ATHEROS
+#endif
+
+/* Initial environment variables */
+#define CONFIG_EXTRA_ENV_SETTINGS \
+ "script=boot.scr\0" \
+ "image=Image\0" \
+ "console=ttymxc0,115200\0" \
+ "fdt_addr=0x43000000\0" \
+ "fdt_high=0xffffffffffffffff\0" \
+ "fdt_file=imx8mq-pico-pi.dtb\0" \
+ "initrd_addr=0x43800000\0" \
+ "initrd_high=0xffffffffffffffff\0" \
+ "mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \
+ "mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
+ "mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
+ "mmcautodetect=yes\0" \
+ "mmcargs=setenv bootargs console=${console} root=${mmcroot}\0 " \
+ "loadbootscript=" \
+ "fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
+ "bootscript=echo Running bootscript from mmc ...; source\0" \
+ "loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
+ "loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
+ "mmcboot=echo Booting from mmc ...; " \
+ "run mmcargs; " \
+ "echo wait for boot; " \
+ "fi;\0" \
+ "netargs=setenv bootargs console=${console} " \
+ "root=/dev/nfs " \
+ "ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
+ "netboot=echo Booting from net ...; " \
+ "run netargs; " \
+ "if test ${ip_dyn} = yes; then " \
+ "setenv get_cmd dhcp; " \
+ "else " \
+ "setenv get_cmd tftp; " \
+ "fi; " \
+ "${get_cmd} ${loadaddr} ${image}; " \
+ "booti; "
+
+#define CONFIG_BOOTCOMMAND \
+ "mmc dev ${mmcdev}; if mmc rescan; then " \
+ "if run loadbootscript; then " \
+ "run bootscript; " \
+ "else " \
+ "if run loadimage; then " \
+ "run mmcboot; " \
+ "else run netboot; " \
+ "fi; " \
+ "fi; " \
+ "else booti ${loadaddr} - ${fdt_addr}; fi"
+
+/* Link Definitions */
+#define CONFIG_LOADADDR 0x40480000
+
+#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
+
+#define CONFIG_SYS_INIT_RAM_ADDR 0x40000000
+#define CONFIG_SYS_INIT_RAM_SIZE 0x80000
+#define CONFIG_SYS_INIT_SP_OFFSET \
+ (CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
+#define CONFIG_SYS_INIT_SP_ADDR \
+ (CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
+
+#define CONFIG_ENV_OVERWRITE
+#define CONFIG_SYS_MMC_ENV_DEV 1 /* USDHC2 */
+#define CONFIG_MMCROOT "/dev/mmcblk1p2" /* USDHC2 */
+
+/* Size of malloc() pool */
+#define CONFIG_SYS_MALLOC_LEN ((CONFIG_ENV_SIZE + (2 * 1024)) * 1024)
+
+#define CONFIG_SYS_SDRAM_BASE 0x40000000
+#define PHYS_SDRAM 0x40000000
+#define PHYS_SDRAM_SIZE 0x80000000 /* 2 GiB DDR */
+
+#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM
+#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + \
+ (PHYS_SDRAM_SIZE >> 1))
+
+#define CONFIG_BAUDRATE 115200
+
+#define CONFIG_MXC_UART
+#define CONFIG_MXC_UART_BASE UART1_BASE_ADDR
+
+/* Monitor Command Prompt */
+#define CONFIG_SYS_CBSIZE 1024
+#define CONFIG_SYS_MAXARGS 64
+#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
+#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + \
+ sizeof(CONFIG_SYS_PROMPT) + 16)
+
+#define CONFIG_IMX_BOOTAUX
+
+#define CONFIG_CMD_MMC
+
+#define CONFIG_SYS_FSL_USDHC_NUM 2
+#define CONFIG_SYS_FSL_ESDHC_ADDR 0
+
+#define CONFIG_SYS_MMC_IMG_LOAD_PART 1
+
+#define CONFIG_MXC_GPIO
+
+#define CONFIG_CMD_FUSE
+
+/* I2C Configs */
+#define CONFIG_SYS_I2C_SPEED 100000
+
+#define CONFIG_OF_SYSTEM_SETUP
+
+#ifndef CONFIG_SPL_BUILD
+#define CONFIG_DM_PMIC
+#endif
+
+#define CONFIG_SYS_BOOTM_LEN SZ_128M
+
+#endif
diff --git a/include/configs/ti_armv7_common.h b/include/configs/ti_armv7_common.h
index a612bb5b4a8..08829781e31 100644
--- a/include/configs/ti_armv7_common.h
+++ b/include/configs/ti_armv7_common.h
@@ -63,7 +63,7 @@
"name_fit=fitImage\0" \
"update_to_fit=setenv loadaddr ${addr_fit}; setenv bootfile ${name_fit}\0" \
"get_overlaystring=" \
- "for overlay in $overlay_files;" \
+ "for overlay in $name_overlays;" \
"do;" \
"setenv overlaystring ${overlaystring}'#'${overlay};" \
"done;\0" \
diff --git a/include/configs/work_92105.h b/include/configs/work_92105.h
index 421384d9ba5..93c8d64b147 100644
--- a/include/configs/work_92105.h
+++ b/include/configs/work_92105.h
@@ -105,11 +105,6 @@
#define CONFIG_LPC32XX_GPIO
/*
- * SSP/SPI/DISPLAY
- */
-
-#define CONFIG_LPC32XX_SSP_TIMEOUT 100000
-/*
* Environment
*/
diff --git a/include/cpu.h b/include/cpu.h
index 6b1b6b37b3b..2f283fe2449 100644
--- a/include/cpu.h
+++ b/include/cpu.h
@@ -89,6 +89,15 @@ struct cpu_ops {
* @return 0 if OK, -ENOSPC if buffer is too small, other -ve on error
*/
int (*get_vendor)(struct udevice *dev, char *buf, int size);
+
+ /**
+ * is_current() - Check if the CPU that U-Boot is currently running from
+ *
+ * @dev: Device to check (UCLASS_CPU)
+ * @return 1 if the CPU that U-Boot is currently running from, 0
+ * if not.
+ */
+ int (*is_current)(struct udevice *dev);
};
#define cpu_get_ops(dev) ((struct cpu_ops *)(dev)->driver->ops)
@@ -137,4 +146,18 @@ int cpu_get_vendor(struct udevice *dev, char *buf, int size);
*/
int cpu_probe_all(void);
+/**
+ * cpu_is_current() - Check if the CPU that U-Boot is currently running from
+ *
+ * Return: 1 if yes, - 0 if not
+ */
+int cpu_is_current(struct udevice *cpu);
+
+/**
+ * cpu_get_current_dev() - Get CPU udevice for current CPU
+ *
+ * Return: udevice if OK, - NULL on error
+ */
+struct udevice *cpu_get_current_dev(void);
+
#endif
diff --git a/include/dm/uclass-id.h b/include/dm/uclass-id.h
index 37ada51f9f7..7837d459f18 100644
--- a/include/dm/uclass-id.h
+++ b/include/dm/uclass-id.h
@@ -47,6 +47,7 @@ enum uclass_id {
UCLASS_DMA, /* Direct Memory Access */
UCLASS_EFI, /* EFI managed devices */
UCLASS_ETH, /* Ethernet device */
+ UCLASS_ETH_PHY, /* Ethernet PHY device */
UCLASS_FIRMWARE, /* Firmware */
UCLASS_FS_FIRMWARE_LOADER, /* Generic loader */
UCLASS_GPIO, /* Bank of general-purpose I/O pins */
diff --git a/include/dt-bindings/soc/imx_rsrc.h b/include/dt-bindings/soc/imx_rsrc.h
index 4870eb985b4..fb6878f6e24 100644
--- a/include/dt-bindings/soc/imx_rsrc.h
+++ b/include/dt-bindings/soc/imx_rsrc.h
@@ -553,5 +553,6 @@
#define SC_R_VPU_ENC_1 539
#define SC_R_VPU 540
#define SC_R_LAST 541
+#define SC_R_NONE 0xFFF0
#endif /* DT_BINDINGS_RSCRC_IMX_H */
diff --git a/include/efi_selftest.h b/include/efi_selftest.h
index eaee188de7e..1515fdaa02b 100644
--- a/include/efi_selftest.h
+++ b/include/efi_selftest.h
@@ -17,69 +17,89 @@
#define EFI_ST_SUCCESS 0
#define EFI_ST_FAILURE 1
#define EFI_ST_SUCCESS_STR L"SUCCESS"
-/*
- * Prints a message.
+
+/**
+ * efi_st_printf() - print a message
+ *
+ * @...: format string followed by fields to print
*/
#define efi_st_printf(...) \
(efi_st_printc(-1, __VA_ARGS__))
-/*
- * Prints an error message.
+/**
+ * efi_st_error() - prints an error message
*
- * @... format string followed by fields to print
+ * @...: format string followed by fields to print
*/
#define efi_st_error(...) \
(efi_st_printc(EFI_LIGHTRED, "%s(%u):\nERROR: ", __FILE__, __LINE__), \
efi_st_printc(EFI_LIGHTRED, __VA_ARGS__))
-/*
- * Prints a TODO message.
+/**
+ * efi_st_todo() - prints a TODO message
*
- * @... format string followed by fields to print
+ * @...: format string followed by fields to print
*/
#define efi_st_todo(...) \
(efi_st_printc(EFI_YELLOW, "%s(%u):\nTODO: ", __FILE__, __LINE__), \
efi_st_printc(EFI_YELLOW, __VA_ARGS__)) \
-/*
+/**
+ * enum efi_test_phase - phase when test will be executed
+ *
* A test may be setup and executed at boottime,
* it may be setup at boottime and executed at runtime,
* or it may be setup and executed at runtime.
*/
enum efi_test_phase {
+ /**
+ * @EFI_EXECUTE_BEFORE_BOOTTIME_EXIT: - execute before ExitBootServices
+ *
+ * Setup, execute, and teardown are executed before ExitBootServices().
+ */
EFI_EXECUTE_BEFORE_BOOTTIME_EXIT = 1,
+ /**
+ * @EFI_SETUP_BEFORE_BOOTTIME_EXIT: - setup before ExitBootServices
+ *
+ * Setup is executed before ExitBootServices() while execute, and
+ * teardown are executed after ExitBootServices().
+ */
EFI_SETUP_BEFORE_BOOTTIME_EXIT,
+ /**
+ * @EFI_SETUP_AFTER_BOOTTIME_EXIT: - setup after ExitBootServices
+ *
+ * Setup, execute, and teardown are executed after ExitBootServices().
+ */
EFI_SETUP_AFTER_BOOTTIME_EXIT,
};
extern struct efi_simple_text_output_protocol *con_out;
extern struct efi_simple_text_input_protocol *con_in;
-/*
- * Exit the boot services.
+/**
+ * efi_st_exit_boot_services() - exit the boot services
*
- * The size of the memory map is determined.
- * Pool memory is allocated to copy the memory map.
- * The memory amp is copied and the map key is obtained.
- * The map key is used to exit the boot services.
+ * * The size of the memory map is determined.
+ * * Pool memory is allocated to copy the memory map.
+ * * The memory map is copied and the map key is obtained.
+ * * The map key is used to exit the boot services.
*/
void efi_st_exit_boot_services(void);
-/*
- * Print a colored message
+/**
+ * efi_st_printc() - print a colored message
*
- * @color color, see constants in efi_api.h, use -1 for no color
- * @fmt printf format
- * @... arguments to be printed
- * on return position of terminating zero word
+ * @color: color, see constants in efi_api.h, use -1 for no color
+ * @fmt: printf style format string
+ * @...: arguments to be printed
*/
void efi_st_printc(int color, const char *fmt, ...)
__attribute__ ((format (__printf__, 2, 3)));
/**
- * efi_st_translate_char() - translate a unicode character to a string
+ * efi_st_translate_char() - translate a Unicode character to a string
*
- * @code: unicode character
+ * @code: Unicode character
* Return: string
*/
u16 *efi_st_translate_char(u16 code);
@@ -87,38 +107,44 @@ u16 *efi_st_translate_char(u16 code);
/**
* efi_st_translate_code() - translate a scan code to a human readable string
*
- * @code: unicode character
- * Return: string
+ * This function translates the scan code returned by the simple text input
+ * protocol to a human readable string, e.g. 0x04 is translated to L"Left".
+ *
+ * @code: scan code
+ * Return: Unicode string
*/
u16 *efi_st_translate_code(u16 code);
-/*
- * Compare an u16 string to a char string.
+/**
+ * efi_st_strcmp_16_8() - compare an u16 string to a char string
+ *
+ * This function compares each u16 value to the char value at the same
+ * position. This function is only useful for ANSI strings.
*
* @buf1: u16 string
* @buf2: char string
- * @return: 0 if both buffers contain the same bytes
+ * Return: 0 if both buffers contain equivalent strings
*/
int efi_st_strcmp_16_8(const u16 *buf1, const char *buf2);
-/*
- * Reads an Unicode character from the input device.
+/**
+ * efi_st_get_key() - reads an Unicode character from the input device
*
- * @return: Unicode character
+ * Return: Unicode character
*/
u16 efi_st_get_key(void);
/**
* struct efi_unit_test - EFI unit test
*
- * An efi_unit_test provides a interface to an EFI unit test.
+ * The &struct efi_unit_test structure provides a interface to an EFI unit test.
*
- * @name: name of unit test
+ * @name: name of the unit test used in the user interface
* @phase: specifies when setup and execute are executed
- * @setup: set up the unit test
- * @teardown: tear down the unit test
- * @execute: execute the unit test
- * @on_request: test is only executed on request
+ * @setup: set up function of the unit test
+ * @execute: execute function of the unit test
+ * @teardown: tear down function of the unit test
+ * @on_request: flag indicating that the test shall only be executed on request
*/
struct efi_unit_test {
const char *name;
@@ -130,7 +156,15 @@ struct efi_unit_test {
bool on_request;
};
-/* Declare a new EFI unit test */
+/**
+ * EFI_UNIT_TEST() - macro to declare a new EFI unit test
+ *
+ * The macro EFI_UNIT_TEST() declares an EFI unit test using the &struct
+ * efi_unit_test structure. The test is added to a linker generated list which
+ * is evaluated by the 'bootefi selftest' command.
+ *
+ * @__name: string identifying the unit test in the linker generated list
+ */
#define EFI_UNIT_TEST(__name) \
ll_entry_declare(struct efi_unit_test, __name, efi_unit_test)
diff --git a/include/eth_phy.h b/include/eth_phy.h
new file mode 100644
index 00000000000..19c496551b4
--- /dev/null
+++ b/include/eth_phy.h
@@ -0,0 +1,17 @@
+/* SPDX-License-Identifier: GPL-2.0+ */
+/*
+ * Copyright 2020 NXP
+ */
+
+#ifndef _eth_phy_h_
+#define _eth_phy_h_
+
+#include <dm.h>
+#include <phy.h>
+
+int eth_phy_binds_nodes(struct udevice *eth_dev);
+int eth_phy_set_mdio_bus(struct udevice *eth_dev, struct mii_dev *mdio_bus);
+struct mii_dev *eth_phy_get_mdio_bus(struct udevice *eth_dev);
+int eth_phy_get_addr(struct udevice *dev);
+
+#endif
diff --git a/include/generic-phy.h b/include/generic-phy.h
index 55629ae0b41..5ab34cda03d 100644
--- a/include/generic-phy.h
+++ b/include/generic-phy.h
@@ -213,12 +213,15 @@ int generic_phy_get_by_index(struct udevice *user, int index,
struct phy *phy);
/**
- * generic_phy_get_by_node() - Get a PHY device by integer index on ofnode
+ * generic_phy_get_by_index_nodev() - Get a PHY device by integer index
+ * without a device
*
- * @node: the device node
+ * @node: The client ofnode.
* @index: The index in the list of available PHYs
* @phy: A pointer to the PHY port
*
+ * This is a version of generic_phy_get_by_index() that does not use a device.
+ *
* This looks up a PHY device for a client device based on its ofnode and on
* its position in the list of the possible PHYs.
*
@@ -237,7 +240,7 @@ int generic_phy_get_by_index(struct udevice *user, int index,
*
* @return 0 if OK, or a negative error code
*/
-int generic_phy_get_by_node(ofnode node, int index, struct phy *phy);
+int generic_phy_get_by_index_nodev(ofnode node, int index, struct phy *phy);
/**
* generic_phy_get_by_name() - Get a PHY device by its name.
diff --git a/include/linux/iopoll.h b/include/linux/iopoll.h
index ab0ae1969a4..30cdea0cdc1 100644
--- a/include/linux/iopoll.h
+++ b/include/linux/iopoll.h
@@ -6,16 +6,18 @@
#ifndef _LINUX_IOPOLL_H
#define _LINUX_IOPOLL_H
+#include <linux/delay.h>
#include <linux/errno.h>
#include <linux/io.h>
#include <time.h>
/**
- * readx_poll_timeout - Periodically poll an address until a condition is met or a timeout occurs
+ * read_poll_timeout - Periodically poll an address until a condition is met or a timeout occurs
* @op: accessor function (takes @addr as its only argument)
* @addr: Address to poll
* @val: Variable to read the value into
* @cond: Break condition (usually involving @val)
+ * @sleep_us: Maximum time to sleep in us
* @timeout_us: Timeout in us, 0 means never timeout
*
* Returns 0 on success and -ETIMEDOUT upon a timeout. In either
@@ -24,7 +26,7 @@
* When available, you'll probably want to use one of the specialized
* macros defined below rather than this macro directly.
*/
-#define readx_poll_timeout(op, addr, val, cond, timeout_us) \
+#define read_poll_timeout(op, addr, val, cond, sleep_us, timeout_us) \
({ \
unsigned long timeout = timer_get_us() + timeout_us; \
for (;;) { \
@@ -35,10 +37,20 @@
(val) = op(addr); \
break; \
} \
+ if (sleep_us) \
+ udelay(sleep_us); \
} \
(cond) ? 0 : -ETIMEDOUT; \
})
+#define readx_poll_sleep_timeout(op, addr, val, cond, sleep_us, timeout_us) \
+ read_poll_timeout(op, addr, val, cond, sleep_us, timeout_us)
+
+#define readl_poll_sleep_timeout(addr, val, cond, sleep_us, timeout_us) \
+ readx_poll_sleep_timeout(readl, addr, val, cond, sleep_us, timeout_us)
+
+#define readx_poll_timeout(op, addr, val, cond, timeout_us) \
+ read_poll_timeout(op, addr, val, cond, false, timeout_us)
#define readb_poll_timeout(addr, val, cond, timeout_us) \
readx_poll_timeout(readb, addr, val, cond, timeout_us)
diff --git a/include/mxs_nand.h b/include/mxs_nand.h
index ada20483d06..c0cefaca90b 100644
--- a/include/mxs_nand.h
+++ b/include/mxs_nand.h
@@ -16,22 +16,26 @@
* @gf_len: The length of Galois Field. (e.g., 13 or 14)
* @ecc_strength: A number that describes the strength of the ECC
* algorithm.
- * @ecc_chunk_size: The size, in bytes, of a single ECC chunk. Note
- * the first chunk in the page includes both data and
- * metadata, so it's a bit larger than this value.
+ * @ecc_chunk0_size: The size, in bytes, of a first ECC chunk.
+ * @ecc_chunkn_size: The size, in bytes, of a single ECC chunk after
+ * the first chunk in the page.
* @ecc_chunk_count: The number of ECC chunks in the page,
* @block_mark_byte_offset: The byte offset in the ECC-based page view at
* which the underlying physical block mark appears.
* @block_mark_bit_offset: The bit offset into the ECC-based page view at
* which the underlying physical block mark appears.
+ * @ecc_for_meta: The flag to indicate if there is a dedicate ecc
+ * for meta.
*/
struct bch_geometry {
unsigned int gf_len;
unsigned int ecc_strength;
- unsigned int ecc_chunk_size;
+ unsigned int ecc_chunk0_size;
+ unsigned int ecc_chunkn_size;
unsigned int ecc_chunk_count;
unsigned int block_mark_byte_offset;
unsigned int block_mark_bit_offset;
+ unsigned int ecc_for_meta; /* ECC for meta data */
};
struct mxs_nand_info {
@@ -39,6 +43,8 @@ struct mxs_nand_info {
struct udevice *dev;
unsigned int max_ecc_strength_supported;
bool use_minimum_ecc;
+ /* legacy bch geometry flag */
+ bool legacy_bch_geometry;
int cur_chip;
uint32_t cmd_queue_len;
@@ -82,13 +88,15 @@ struct mxs_nand_layout {
u32 ecc0;
u32 datan_size;
u32 eccn;
+ u32 gf_len;
};
int mxs_nand_init_ctrl(struct mxs_nand_info *nand_info);
int mxs_nand_init_spl(struct nand_chip *nand);
int mxs_nand_setup_ecc(struct mtd_info *mtd);
-void mxs_nand_mode_fcb(struct mtd_info *mtd);
+void mxs_nand_mode_fcb_62bit(struct mtd_info *mtd);
+void mxs_nand_mode_fcb_40bit(struct mtd_info *mtd);
void mxs_nand_mode_normal(struct mtd_info *mtd);
u32 mxs_nand_mark_byte_offset(struct mtd_info *mtd);
u32 mxs_nand_mark_bit_offset(struct mtd_info *mtd);
diff --git a/include/spl.h b/include/spl.h
index 6bf9fd8bebb..90395fedb0f 100644
--- a/include/spl.h
+++ b/include/spl.h
@@ -582,4 +582,5 @@ void spl_perform_fixups(struct spl_image_info *spl_image);
*/
struct image_header *spl_get_load_buffer(ssize_t offset, size_t size);
+void spl_save_restore_data(void);
#endif