Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=5b4d21... Commit: 5b4d2189446fd31cd618bbd1c24566b8d0ab11c8 Parent: 7d4320f3d5ace5758111f2beac931376737f80f5 Author: Sebastian Siewior <bigeasy@linutronix.de> AuthorDate: Sat Nov 1 10:00:56 2008 +0000 Committer: Paul Mackerras <paulus@samba.org> CommitDate: Thu Nov 6 09:49:43 2008 +1100 powerpc/boot: Allocate more memory for dtb David Gibson suggested that since we are now unconditionally copying the dtb into a malloc()ed buffer, it would be sensible to add a little padding to the buffer at that point, so that further device tree manipulations won't need to reallocate it. This implements that suggestion. Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Signed-off-by: Paul Mackerras <paulus@samba.org> --- arch/powerpc/boot/libfdt-wrapper.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/powerpc/boot/libfdt-wrapper.c b/arch/powerpc/boot/libfdt-wrapper.c index 9276327..bb8b9b3 100644 --- a/arch/powerpc/boot/libfdt-wrapper.c +++ b/arch/powerpc/boot/libfdt-wrapper.c @@ -185,7 +185,7 @@ void fdt_init(void *blob) /* Make sure the dt blob is the right version and so forth */ fdt = blob; - bufsize = fdt_totalsize(fdt) + 4; + bufsize = fdt_totalsize(fdt) + EXPAND_GRANULARITY; buf = malloc(bufsize); if(!buf) fatal("malloc failed. can't relocate the device tree\n\r"); -- To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html
