diff options
author | Grant Likely <grant.likely@linaro.org> | 2011-03-28 09:58:55 +0000 |
---|---|---|
committer | Gerald Van Baren <gvb@unssw.com> | 2011-04-25 21:11:21 -0400 |
commit | ce6b27a874fe30e7126ae93c060277770ee85ced (patch) | |
tree | bf731254a31da996c854c14be9e5d4016df8a4be /common | |
parent | ed59e58786cae9f8afcb575649afc65985beed4d (diff) | |
download | u-boot-imx-ce6b27a874fe30e7126ae93c060277770ee85ced.zip u-boot-imx-ce6b27a874fe30e7126ae93c060277770ee85ced.tar.gz u-boot-imx-ce6b27a874fe30e7126ae93c060277770ee85ced.tar.bz2 |
Fix off-by-one error in passing initrd end address via device tree
The initrd_end variable contains the address immediately *after* the
initrd blob, not the last address containing data. This patch fixes
an inadvertent off-by-one when setting up the initrd reserved map.
Signed-off-by: Grant Likely <grant.likely@linaro.org>
Diffstat (limited to 'common')
-rw-r--r-- | common/fdt_support.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/common/fdt_support.c b/common/fdt_support.c index edcf04a..496040b 100644 --- a/common/fdt_support.c +++ b/common/fdt_support.c @@ -183,7 +183,7 @@ int fdt_initrd(void *fdt, ulong initrd_start, ulong initrd_end, int force) } } - err = fdt_add_mem_rsv(fdt, initrd_start, initrd_end - initrd_start + 1); + err = fdt_add_mem_rsv(fdt, initrd_start, initrd_end - initrd_start); if (err < 0) { printf("fdt_initrd: %s\n", fdt_strerror(err)); return err; |