[syslinux] Syslinux: Broken file reading for fat16 with 3.35+?

Ram Yalamanchili ramyinc at gmail.com
Tue Feb 6 02:39:08 PST 2007


Hello,

I noticed after upgrading from 3.20, I haven't been able to get
syslinux to boot properly with menu.c32 or mboot.c32 from a USB key. I
get an error saying invalid kernel when its trying to load menu.c32 or
mboot.c32 (or any other kernel for that matter). I tried 3.35 and
3.36-pre5. Same exact behaviour.

I'm using the following to compile:
gcc version 3.2.3 20030502 (Red Hat Linux 3.2.3-34)
NASM version 0.98.39 compiled on Jan 15 2005

Steps to reproduce:
/dev/sdc is my usb key

mkdiskimage -4 /dev/sdc4 0 64 32
syslinux -s /dev/sdc4
mount /mnt/sdc4
cp
menu.c32 mboot.c32 syslinux.cfg mykernel /mnt/sdc4
umount /mnt/sdc4

reboot with key in.

syslinux.cfg has the following:
default menu.c32
menu title Boot Menu
timeout 30

label RBoot
    menu label ^RBoot
    kernel mboot.c32
    append mykernel

Errors:

It shows SYSLINUX 3.36 Pre 5, etc.. and then goes to

boot:
Loading
Invalid or corrupt kernel image
<repeat last 3 lines for like 5 mins or so>

Then all of a sudden the error message changes to:
boot:
Could not find kernel image: menu.c32
This I assume is happening because the USB key device went away for
whatever reason after many minutes.

Before the USB key 'went off', entering mboot.c32 or menu.c32 in the
prompt also produces the same error. If I enter the name of a
non-existant file it says file not found as expected.

I used the same above process with syslinux 3.20's
syslinux/mkdiskimage, and copied the 3.36-pre5 menu.c32 and mboot.c32
into the partition, and this worked.

Anyone know what might be causing this? Looks like ldlinux.sys is
broken. I need to upgrade to 3.35 because I need the 0x19 read
partition call for my use. On a similar note, Peter, are you ok with
me implementing a comboot api call which would take in the bios drive
and sector number to get data from (a 0x20 if you will)? Or 0x19 can
be modified to take in an argument which says if the partition offset
shoudl be added to eax or not before you issue the int 0x13h. I like a
newer call which is a "Read raw disk" instead of "read active
partition". I want to extend it to read from (drive number, partition
number). Further extension could lead to Grub like addressing where
you can have files on various other partitions and be able to get
them.

thanks,
Ram




More information about the Syslinux mailing list