summaryrefslogtreecommitdiff
path: root/common
diff options
context:
space:
mode:
Diffstat (limited to 'common')
-rw-r--r--common/board_f.c8
-rw-r--r--common/console.c23
2 files changed, 18 insertions, 13 deletions
diff --git a/common/board_f.c b/common/board_f.c
index 8fa26e3ca5..82a164752a 100644
--- a/common/board_f.c
+++ b/common/board_f.c
@@ -867,6 +867,11 @@ __weak int checkcpu(void)
return 0;
}
+__weak int clear_bss(void)
+{
+ return 0;
+}
+
static const init_fnc_t init_sequence_f[] = {
setup_mon_len,
#ifdef CONFIG_OF_CONTROL
@@ -1002,11 +1007,8 @@ static const init_fnc_t init_sequence_f[] = {
#if defined(CONFIG_X86) || defined(CONFIG_ARC)
copy_uboot_to_ram,
do_elf_reloc_fixups,
- clear_bss,
#endif
-#if defined(CONFIG_XTENSA)
clear_bss,
-#endif
#if !defined(CONFIG_ARM) && !defined(CONFIG_SANDBOX) && \
!CONFIG_IS_ENABLED(X86_64)
jump_to_copy,
diff --git a/common/console.c b/common/console.c
index 7681da19a2..e398530a13 100644
--- a/common/console.c
+++ b/common/console.c
@@ -401,7 +401,7 @@ int getc(void)
if (gd->console_in.start) {
int ch;
- ch = membuff_getbyte(&gd->console_in);
+ ch = membuff_getbyte((struct membuff *)&gd->console_in);
if (ch != -1)
return 1;
}
@@ -426,7 +426,7 @@ int tstc(void)
return 0;
#ifdef CONFIG_CONSOLE_RECORD
if (gd->console_in.start) {
- if (membuff_peekbyte(&gd->console_in) != -1)
+ if (membuff_peekbyte((struct membuff *)&gd->console_in) != -1)
return 1;
}
#endif
@@ -518,7 +518,7 @@ void putc(const char c)
return;
#ifdef CONFIG_CONSOLE_RECORD
if ((gd->flags & GD_FLG_RECORD) && gd->console_out.start)
- membuff_putbyte(&gd->console_out, c);
+ membuff_putbyte((struct membuff *)&gd->console_out, c);
#endif
#ifdef CONFIG_SILENT_CONSOLE
if (gd->flags & GD_FLG_SILENT) {
@@ -569,7 +569,7 @@ void puts(const char *s)
return;
#ifdef CONFIG_CONSOLE_RECORD
if ((gd->flags & GD_FLG_RECORD) && gd->console_out.start)
- membuff_put(&gd->console_out, s, strlen(s));
+ membuff_put((struct membuff *)&gd->console_out, s, strlen(s));
#endif
#ifdef CONFIG_SILENT_CONSOLE
if (gd->flags & GD_FLG_SILENT) {
@@ -602,18 +602,20 @@ int console_record_init(void)
{
int ret;
- ret = membuff_new(&gd->console_out, CONFIG_CONSOLE_RECORD_OUT_SIZE);
+ ret = membuff_new((struct membuff *)&gd->console_out,
+ CONFIG_CONSOLE_RECORD_OUT_SIZE);
if (ret)
return ret;
- ret = membuff_new(&gd->console_in, CONFIG_CONSOLE_RECORD_IN_SIZE);
+ ret = membuff_new((struct membuff *)&gd->console_in,
+ CONFIG_CONSOLE_RECORD_IN_SIZE);
return ret;
}
void console_record_reset(void)
{
- membuff_purge(&gd->console_out);
- membuff_purge(&gd->console_in);
+ membuff_purge((struct membuff *)&gd->console_out);
+ membuff_purge((struct membuff *)&gd->console_in);
}
void console_record_reset_enable(void)
@@ -624,12 +626,13 @@ void console_record_reset_enable(void)
int console_record_readline(char *str, int maxlen)
{
- return membuff_readline(&gd->console_out, str, maxlen, ' ');
+ return membuff_readline((struct membuff *)&gd->console_out, str,
+ maxlen, ' ');
}
int console_record_avail(void)
{
- return membuff_avail(&gd->console_out);
+ return membuff_avail((struct membuff *)&gd->console_out);
}
#endif