Messages in this thread | | | Date | Thu, 13 Jul 2000 17:47:30 -0700 (PDT) | From | Linus Torvalds <> | Subject | Re: Bug in kernel - how to make big kernel bootable with GRUB (was Re: Linux 2.4.0-Test{1,2} with Grub (I think I found the answer)) |
| |
On Fri, 14 Jul 2000, Khimenko Victor wrote: > > Huh. Patch is trivial. Really trivial. Just one problem: I do not think it'll > be applied. Since it's TWO patches: one for kernel and one for GRUB.
Actually, the only problem with the patch is that it is not byte-order-safe, which means that you cannot cross-compile from a big-endian host.
I don't see any real problem in extending syssize to be 4 bytes, as the two ne wbytes that it writes over are the "swap_dev" bytes that I don't think anybody ever used. We might as well get rid of them. And thanks to being little-endian, it would not change for loaders that don't know about the new 4-byte format (the two low bytes are still the same).
So I won't apply the patch as-is, but fix it to be endian-safe and get some input from other bootloaders (assuming they all agree that swap_dev is a non-issue - which I think they will) and I _will_ apply it.
> Who's the bright idea was to extend maximum kernel beyond 1MB and STILL write > only two bytes of sys_size in boot sector anyway ? And why it was done via > buf in first place ?
I'd be careful about calling other people stupid if you don't understand the code.
Using "buf" the way the code used it meant that people whose native byte-order was big-endian would still be able to build images. Performance was never a big issue here, so it works fine. It may not be pretty, but I doubt beauty was a big issue either ;)
The field never got extended because nobody really needed it extended. That's as simple as it can get, no?
Linus
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |