diff mbox

[U-Boot,PATCH-v2,2/2] mips: qemu-mips/64: Expand malloc pool for CONFIG_SYS_BOOTPARAMS_LEN

Message ID 1492051352-5240-3-git-send-email-kyleedwardsny@gmail.com
State Accepted
Commit 1967228b028b5ddf0b0b41806e5bd10e49e836a6
Delegated to: Daniel Schwierzeck
Headers show

Commit Message

Kyle Edwards April 13, 2017, 2:42 a.m. UTC
Before this patch, CONFIG_SYS_BOOTPARAMS_LEN was the same size as
CONFIG_SYS_MALLOC_LEN. So, if malloc() had previously been called, and
initr_malloc_bootparams() was called, it would fail with an out-of-
memory error. This patch fixes this issue by expanding the malloc pool
to 256KB.

Signed-off-by: Kyle Edwards <kyleedwardsny@gmail.com>
Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
---
 include/configs/qemu-mips.h   | 2 +-
 include/configs/qemu-mips64.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Comments

Daniel Schwierzeck April 14, 2017, 5:36 p.m. UTC | #1
Am 13.04.2017 um 04:42 schrieb Kyle Edwards:
> Before this patch, CONFIG_SYS_BOOTPARAMS_LEN was the same size as
> CONFIG_SYS_MALLOC_LEN. So, if malloc() had previously been called, and
> initr_malloc_bootparams() was called, it would fail with an out-of-
> memory error. This patch fixes this issue by expanding the malloc pool
> to 256KB.
> 
> Signed-off-by: Kyle Edwards <kyleedwardsny@gmail.com>
> Cc: Daniel Schwierzeck <daniel.schwierzeck@gmail.com>
> ---
>  include/configs/qemu-mips.h   | 2 +-
>  include/configs/qemu-mips64.h | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 

applied to u-boot-mips/master, thanks
diff mbox

Patch

diff --git a/include/configs/qemu-mips.h b/include/configs/qemu-mips.h
index b67d413..59a793b 100644
--- a/include/configs/qemu-mips.h
+++ b/include/configs/qemu-mips.h
@@ -80,7 +80,7 @@ 
 /* max number of command args */
 #define CONFIG_SYS_MAXARGS		16
 
-#define CONFIG_SYS_MALLOC_LEN		128*1024
+#define CONFIG_SYS_MALLOC_LEN		(256 << 10)
 
 #define CONFIG_SYS_BOOTPARAMS_LEN	128*1024
 
diff --git a/include/configs/qemu-mips64.h b/include/configs/qemu-mips64.h
index 4856087..28b791a 100644
--- a/include/configs/qemu-mips64.h
+++ b/include/configs/qemu-mips64.h
@@ -80,7 +80,7 @@ 
 /* max number of command args */
 #define CONFIG_SYS_MAXARGS		16
 
-#define CONFIG_SYS_MALLOC_LEN		128*1024
+#define CONFIG_SYS_MALLOC_LEN		(256 << 10)
 
 #define CONFIG_SYS_BOOTPARAMS_LEN	128*1024