On Mon, Oct 13, 2008 at 11:15:26AM +0200, Sebastian Andrzej Siewior wrote: > If the vmlinux binary in memory is larger than 4 MiB than it collides > with the initial boot code which is linked at 4 MiB in case of cuBoot. > If the the uncompressed image size (on disk size) is less than 4 MiB > then it would fit. The difference between those two sizes is the bss > section. In cuBoot we have the dtb embedded right after the data > section so it is very likely that the reset of the bss section (in > kernel's start up code) will overwrite the dtb blob. Therefore we > reallocate the dtb. Something similar is allready done to the initrd. > > Signed-off-by: Sebastian Andrzej Siewior <[EMAIL PROTECTED]>
This patch looks sound to me. It does strike me as only a stopgap until we come up with some better way of managing the early memory, preferably avoiding the magical fixed 4MiB (or whatever) offset. Still, it looks safe - since it does check that the wrapper's malloc() region can't collide with the kernel's BSS. So, if this little slice of extra BSS room is useful for the time being, I see no reason not to apply the patch. Acked-by: David Gibson <[EMAIL PROTECTED]> -- David Gibson | I'll have my music baroque, and my code david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_ | _way_ _around_! http://www.ozlabs.org/~dgibson _______________________________________________ Linuxppc-dev mailing list Linuxppc-dev@ozlabs.org https://ozlabs.org/mailman/listinfo/linuxppc-dev