[syslinux] Large vmalloc segments with PXELINUX

Mike Polek syslinux at selfexpression.org
Thu Nov 15 23:23:02 PST 2007


Hi, all,
  I believe I've solved the issue, or at least worked around
it in a fashion. It looks like pxelinux honors the 'mem='
kernel parameter. So, I added two lines of code to have
pxelinux interpret 'upm=' in exactly the same way. (upm in
honor of grub's uppermem) Since the kernel just ignores the
unknown parameter, this has pxelinux put the initrd and cmdline
away from the vmalloc space. 

Here's the patch:
------------------------------------------------------------------------
--- runkernel.inc.orig  2007-09-25 16:30:44.000000000 -0700
+++ runkernel.inc       2007-11-15 23:06:26.000000000 -0800
@@ -141,6 +141,8 @@
                je is_vga_cmd
                 cmp eax,'mem='
                je is_mem_cmd
+                cmp eax,'upm='
+               je is_mem_cmd
 %if IS_PXELINUX
                cmp eax,'keep'                  ; Is it "keeppxe"?
                jne .notkeep
------------------------------------------------------------------------

The following config file works fine, and allows me to use about
868M of the vmalloc memory area.

------------------------------------------------------------------------
# Configuration file
# linux-2.6.20-1.2962.fc6
DEFAULT linux

LABEL linux
        kernel kernels/vmlinuz-2.6.20-1.2962.fc6
        append initrd=initrds/myinitrd-2.6.20-1.2962.fc6.img
                 vmalloc=900M upm=16M
------------------------------------------------------------------------

The only downside is that I think if you actually wanted to use 'mem='
you shouldn't use upm=, and if you did, they would be processed in order
with the last one on the line being honored by pxelinux, which could
have weird results. But as long as you use it responsibly, it does the
job.

Any chance of getting this patch (or something better) into a future
release?

Thanks!
Mike Polek


On Sat, 2007-11-10 at 13:17, Mike Polek wrote: 
> Hello,
>   I'm having a challenge with increasing vmalloc memory beyond
> 512M using pxelinux.0 to boot.
> 
> This config works fine:
> ---
> # Configuration file
> # linux-2.6.20-1.2962.fc6
> DEFAULT linux
> 
> LABEL linux
>         kernel kernels/vmlinuz-2.6.20-1.2962.fc6
>         append initrd=initrds/bladeinitrd-2.6.20-1.2962.fc6.img
> enforcing=0 vmalloc=512M
> ---
> 
>   If I increase vmalloc to 513M, I get errors about not being
> able to find a root device, root=<NULL> blah blah blah, kind
> of like what happens with grub if you don't use "uppermem."
> I'm not sure if the command line is getting clobbered, or
> if the initrd is loading in the wrong place. Any suggestions
> on how to let pxelinux.0 know where to put things when large
> amounts of vmalloc memory are required?
>   I tried bringing down HIGHMEM_MAX and adjusting the command line
> location... and a few other tweaks... but I just don't have the
> expertise to figure out exactly where everything is placed.
> 
> Thanks!
> Mike




More information about the Syslinux mailing list