summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/board_f.c8
-rw-r--r--common/board_r.c6
-rw-r--r--common/cli_hush.c1
-rw-r--r--common/init/board_init.c2
-rw-r--r--common/memsize.c6
-rw-r--r--common/spl/Kconfig4
-rw-r--r--common/spl/spl.c4
-rw-r--r--common/spl/spl_legacy.c4
-rw-r--r--common/spl/spl_ram.c4
9 files changed, 17 insertions, 22 deletions
diff --git a/common/board_f.c b/common/board_f.c
index e027248db56..2b4edf30c93 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -380,19 +380,19 @@ static int setup_dest_addr(void)
return arch_setup_dest_addr();
}
-#ifdef CONFIG_PRAM
+#ifdef CFG_PRAM
/* reserve protected RAM */
static int reserve_pram(void)
{
ulong reg;
- reg = env_get_ulong("pram", 10, CONFIG_PRAM);
+ reg = env_get_ulong("pram", 10, CFG_PRAM);
gd->relocaddr -= (reg << 10); /* size is in kB */
debug("Reserving %ldk for protected RAM at %08lx\n", reg,
gd->relocaddr);
return 0;
}
-#endif /* CONFIG_PRAM */
+#endif /* CFG_PRAM */
/* Round memory pointer down to next 4 kB limit */
static int reserve_round_4k(void)
@@ -925,7 +925,7 @@ static const init_fnc_t init_sequence_f[] = {
#ifdef CONFIG_OF_BOARD_FIXUP
fix_fdt,
#endif
-#ifdef CONFIG_PRAM
+#ifdef CFG_PRAM
reserve_pram,
#endif
reserve_round_4k,
diff --git a/common/board_r.c b/common/board_r.c
index 347bb7f7c02..42060ee709d 100644
--- a/common/board_r.c
+++ b/common/board_r.c
@@ -533,7 +533,7 @@ static int initr_ide(void)
}
#endif
-#if defined(CONFIG_PRAM)
+#if defined(CFG_PRAM)
/*
* Export available size of memory for Linux, taking into account the
* protected RAM at top of memory
@@ -543,7 +543,7 @@ int initr_mem(void)
ulong pram = 0;
char memsz[32];
- pram = env_get_ulong("pram", 10, CONFIG_PRAM);
+ pram = env_get_ulong("pram", 10, CFG_PRAM);
sprintf(memsz, "%ldk", (long int)((gd->ram_size / 1024) - pram));
env_set("mem", memsz);
@@ -791,7 +791,7 @@ static init_fnc_t init_sequence_r[] = {
*/
last_stage_init,
#endif
-#if defined(CONFIG_PRAM)
+#if defined(CFG_PRAM)
initr_mem,
#endif
run_main_loop,
diff --git a/common/cli_hush.c b/common/cli_hush.c
index 1467ff81b35..a80b84756bb 100644
--- a/common/cli_hush.c
+++ b/common/cli_hush.c
@@ -112,7 +112,6 @@
#define applet_name "hush"
#include "standalone.h"
#define hush_main main
-#undef CONFIG_FEATURE_SH_FANCY_PROMPT
#define BB_BANNER
#endif
#endif
diff --git a/common/init/board_init.c b/common/init/board_init.c
index 6a550261778..96ffb79a986 100644
--- a/common/init/board_init.c
+++ b/common/init/board_init.c
@@ -78,7 +78,7 @@ __weak void board_init_f_init_stack_protection(void)
ulong board_init_f_alloc_reserve(ulong top)
{
/* Reserve early malloc arena */
-#ifndef CONFIG_MALLOC_F_ADDR
+#ifndef CFG_MALLOC_F_ADDR
#if CONFIG_VAL(SYS_MALLOC_F_LEN)
top -= CONFIG_VAL(SYS_MALLOC_F_LEN);
#endif
diff --git a/common/memsize.c b/common/memsize.c
index 3c80ad2c834..ad9ddf67ac5 100644
--- a/common/memsize.c
+++ b/common/memsize.c
@@ -106,11 +106,11 @@ phys_size_t __weak get_effective_memsize(void)
if (gd->ram_base + ram_size < gd->ram_base)
ram_size = ((phys_size_t)~0xfffULL) - gd->ram_base;
-#ifndef CONFIG_MAX_MEM_MAPPED
+#ifndef CFG_MAX_MEM_MAPPED
return ram_size;
#else
/* limit stack to what we can reasonable map */
- return ((ram_size > CONFIG_MAX_MEM_MAPPED) ?
- CONFIG_MAX_MEM_MAPPED : ram_size);
+ return ((ram_size > CFG_MAX_MEM_MAPPED) ?
+ CFG_MAX_MEM_MAPPED : ram_size);
#endif
}
diff --git a/common/spl/Kconfig b/common/spl/Kconfig
index c6da4a403e9..f0f7acead74 100644
--- a/common/spl/Kconfig
+++ b/common/spl/Kconfig
@@ -691,7 +691,7 @@ config SPL_FS_FAT
config SPL_FS_LOAD_PAYLOAD_NAME
string "File to load for U-Boot from the filesystem"
- depends on SPL_FS_EXT4 || SPL_FS_FAT || SPL_FS_SQUASHFS
+ depends on SPL_FS_EXT4 || SPL_FS_FAT || SPL_FS_SQUASHFS || SPL_SEMIHOSTING
default "tispl.bin" if SYS_K3_SPL_ATF
default "u-boot.itb" if SPL_LOAD_FIT
default "u-boot.img"
@@ -1347,7 +1347,7 @@ config SPL_USB_HOST
config SPL_USB_STORAGE
bool "Support loading from USB"
- depends on SPL_USB_HOST && !(BLK && !DM_USB)
+ depends on SPL_USB_HOST
help
Enable support for USB devices in SPL. This allows use of USB
devices such as hard drives and flash drivers for loading U-Boot.
diff --git a/common/spl/spl.c b/common/spl/spl.c
index 1d2e8fda728..4668367b680 100644
--- a/common/spl/spl.c
+++ b/common/spl/spl.c
@@ -527,8 +527,8 @@ static int spl_common_init(bool setup_malloc)
#if CONFIG_VAL(SYS_MALLOC_F_LEN)
if (setup_malloc) {
-#ifdef CONFIG_MALLOC_F_ADDR
- gd->malloc_base = CONFIG_MALLOC_F_ADDR;
+#ifdef CFG_MALLOC_F_ADDR
+ gd->malloc_base = CFG_MALLOC_F_ADDR;
#endif
gd->malloc_limit = CONFIG_VAL(SYS_MALLOC_F_LEN);
gd->malloc_ptr = 0;
diff --git a/common/spl/spl_legacy.c b/common/spl/spl_legacy.c
index 4c7f44687e8..16851c55eb5 100644
--- a/common/spl/spl_legacy.c
+++ b/common/spl/spl_legacy.c
@@ -106,7 +106,7 @@ int spl_load_legacy_img(struct spl_image_info *spl_image,
* is set
*/
if (spl_image->flags & SPL_COPY_PAYLOAD_ONLY)
- dataptr += sizeof(hdr);
+ dataptr += sizeof(*hdr);
load->read(load, dataptr, spl_image->size,
(void *)(unsigned long)spl_image->load_addr);
@@ -116,7 +116,7 @@ int spl_load_legacy_img(struct spl_image_info *spl_image,
lzma_len = LZMA_LEN;
/* dataptr points to compressed payload */
- dataptr = offset + sizeof(hdr);
+ dataptr = offset + sizeof(*hdr);
debug("LZMA: Decompressing %08lx to %08lx\n",
dataptr, spl_image->load_addr);
diff --git a/common/spl/spl_ram.c b/common/spl/spl_ram.c
index 2b1ac191523..5753bd228f7 100644
--- a/common/spl/spl_ram.c
+++ b/common/spl/spl_ram.c
@@ -17,10 +17,6 @@
#include <spl.h>
#include <linux/libfdt.h>
-#ifndef CONFIG_SPL_LOAD_FIT_ADDRESS
-# define CONFIG_SPL_LOAD_FIT_ADDRESS 0
-#endif
-
static ulong spl_ram_load_read(struct spl_load_info *load, ulong sector,
ulong count, void *buf)
{