From: Mike Frysinger <vapier@gentoo.org>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH 1/1] nios2 - adjust gbl data off to account for bd_info
Date: Thu, 23 Feb 2012 18:54:07 -0500 [thread overview]
Message-ID: <201202231854.08292.vapier@gentoo.org> (raw)
In-Reply-To: <1329781545-18177-1-git-send-email-alex@alexhornung.com>
On Monday 20 February 2012 18:45:45 Alex Hornung wrote:
> * Adjust the GBL_DATA_OFFSET to account for the fact that we'll be
> using the space between that offset and the start of the malloc
> region to allocate both a gd structure and a board info structure.
>
> * This fixes a memory corruption bug due to overlap of the malloc
> region and the bd_info structure.
>
> Signed-off-by: Alex Hornung <alex@alexhornung.com>
> ---
> include/configs/nios2-generic.h | 3 ++-
> 1 files changed, 2 insertions(+), 1 deletions(-)
>
> diff --git a/include/configs/nios2-generic.h
> b/include/configs/nios2-generic.h index 9ba35e8..17017a5 100644
> --- a/include/configs/nios2-generic.h
> +++ b/include/configs/nios2-generic.h
> @@ -131,7 +131,8 @@
> #define CONFIG_SYS_MALLOC_BASE (CONFIG_SYS_MONITOR_BASE - \
> CONFIG_SYS_MALLOC_LEN)
> #define CONFIG_SYS_GBL_DATA_OFFSET (CONFIG_SYS_MALLOC_BASE - \
> - GENERATED_GBL_DATA_SIZE)
> + GENERATED_GBL_DATA_SIZE - \
> + GENERATED_BD_INFO_SIZE)
> #define CONFIG_SYS_INIT_SP CONFIG_SYS_GBL_DATA_OFFSET
>
> /*
+cc the nios maintainers ...
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20120223/c7f4321d/attachment.pgp>
next prev parent reply other threads:[~2012-02-23 23:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-20 23:45 [U-Boot] [PATCH 1/1] nios2 - adjust gbl data off to account for bd_info Alex Hornung
2012-02-21 10:33 ` Graeme Russ
2012-02-23 8:13 ` Alex Hornung
2012-02-23 8:49 ` Graeme Russ
2012-02-23 23:54 ` Mike Frysinger [this message]
2012-02-24 3:03 ` Thomas Chou
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=201202231854.08292.vapier@gentoo.org \
--to=vapier@gentoo.org \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox