[syslinux] boot 32 or 64 kernel depending on cpu

Luciano Miguel Ferreira Rocha strange at nsk.no-ip.org
Thu Apr 26 14:37:10 PDT 2007


On Thu, Apr 26, 2007 at 02:13:51PM -0700, H. Peter Anvin wrote:
> Luciano Miguel Ferreira Rocha wrote:
> > 
> > I don't link the command line parsing of linux.c. Mine works (well, it
> > prints the correct output), is smaller and IMHO cleaner.
> > 
> 
> Well, for one thing, you have "video=" instead of "vga=" (two different
> options!)

You're right.

> and your handling of suffixes is broken in two ways: a) you do
> "toupper" but compare against lower-case characters,

You're also right. (I shouldn't code so late. ;)

> and you don't deal
> with 64-bit suffixes, and risk boot failure as a result.

Why should I? The prototype for syslinux_boot_linux declares mem_limit
as an uint32_t. So supporting t/p/e will only cause it to overflow. I
expect to get better results from stopping at GB than by overflowing.

Still, the argument parsing is broken as far as mem and vga are
concerned, but I didn't use them anyway and boot still fails. (Note that
I sent my debugged code. I'd test all cases before submitting a final code.)

> As far as argv[0] is concerned, that's supposed to be the name of the
> c32 file itself.

Supposed, yes, but it never did. Just garbage (and I do print the
arguments at the start of the module).

-- 
lfr
0/0




More information about the Syslinux mailing list