2 more fixes to arm/arch/.../redboot_linux_exec.c

Patrick Doyle wpd@delcomsys.com
Fri Jan 17 16:42:00 GMT 2003


This time, I'll start by attaching the patch file.  Then I'll describe
what's in it.  (Now I just have to hope I attached the right one... :-)

Anyway, I ran into a problem in the copy loop in redboot_linux_exec.c when
the length of the kernel was not a multiple of 4.  (It surprised me that the
kernel length would not be a multiple of 4, but for whatever reason, the end
of the particular kernel I was working with that day, with whatever
toolchain I was using that day, had a bunch of strings, and they were not
padded out to a multiple of 4 length).  The copy loop, which decremented the
count by 4 every time, ran for a very long time. :-(

The other problem that I fixed was that the size of the memory that was
reported to my kernel was double what I thought it should be.  This confused
me tremendously since the comment in the code indicated that it should not
double the size when it is already a power of two, but I suspect somebody
made a change to 'hal_msbindex()' that didn't get propagated to this
function.

Finally, this patch also includes my previous patch changing INITRD to
INITRD2 as per recent arm kernels.  I don't know if this hasn't been
included yet because you've been too busy to commit it to CVS, or if you
have a philosophical disagreement over whether it should be included or not.
If the later, please let me know.

--wpd
-------------- next part --------------
A non-text attachment was scrubbed...
Name: exec.patch2
Type: application/octet-stream
Size: 3678 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/ecos-patches/attachments/20030117/9c6cbaf8/attachment.obj>


More information about the Ecos-patches mailing list