platform/upstream/syslinux.git
14 years agoCore: opendir/readdir/closedir stuff added
Liu Aleaxander [Wed, 26 Aug 2009 23:37:44 +0000 (07:37 +0800)]
Core: opendir/readdir/closedir stuff added

Here're some big changes:
1. The vfs-dir stuff added.
2. The dir-functions in com32/lib are mostly rewritten.
3. with little change on rosh for avoid the compile error

Well, I don't think it's a good vfs-dir interface.

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore:pxelinux: fix the dns_resolv call reference in pxe.c
Aleaxander [Tue, 25 Aug 2009 21:32:38 +0000 (05:32 +0800)]
Core:pxelinux: fix the dns_resolv call reference in pxe.c

The current dns_resolv function doesn't update the _name_ string, so we should
use the strstr things to make the _p_ pointer to point to the right address we
want.

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agodnsresolv: compare returned name; "better" CNAME handling
H. Peter Anvin [Mon, 24 Aug 2009 23:32:48 +0000 (16:32 -0700)]
dnsresolv: compare returned name; "better" CNAME handling

Compare the returned name with the name we requested.  Handle CNAMEs
by overwriting the requested name with the CNAME, however, we really
should:

a) rescan the packet from the beginning;
b) send a new request if we get no A record for the CNAME.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agodnsresolv: fix timeouts, clean up types
H. Peter Anvin [Mon, 24 Aug 2009 22:43:21 +0000 (15:43 -0700)]
dnsresolv: fix timeouts, clean up types

Fix timeouts: it was way too easy to make the code give up, which
often resulted in a zero response even if valid data would soon be
available.

Also avoid passing char ** when we don't really need it.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agonetinet/in.h: fix output types
H. Peter Anvin [Mon, 24 Aug 2009 22:41:30 +0000 (15:41 -0700)]
netinet/in.h: fix output types

We need casts not just on input but on output, in order to make sure
only the correct bits are visible.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoCore:PXELINUX: dns_resolv problem resolved.
Liu Aleaxander [Fri, 21 Aug 2009 03:41:43 +0000 (11:41 +0800)]
Core:PXELINUX: dns_resolv problem resolved.

Now the dns_resolv program can work correctly now except sometimes you should add some
DNS servers manually by yourself if your current DNS server can not work, this mostly happen
when you use something like Qemu.

And, we added a host c32 module written by hpa, as a dns resolver test.

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore:PXELINUX: dnsrelov.inc converted
Liu Aleaxander [Wed, 19 Aug 2009 10:47:04 +0000 (18:47 +0800)]
Core:PXELINUX: dnsrelov.inc converted

The dnsrelov converted to C.

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore:PXELINUX: improve the pxe_mangle_name in pxe.c
Liu Aleaxander [Mon, 17 Aug 2009 23:47:55 +0000 (07:47 +0800)]
Core:PXELINUX: improve the pxe_mangle_name in pxe.c

the old code has so many goto sentences and labels, so improve it and remove them

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore: fat: make the file->file_len to store the dir sector number when we search...
Liu Aleaxander [Mon, 17 Aug 2009 08:28:52 +0000 (16:28 +0800)]
Core: fat: make the file->file_len to store the dir sector number when we search a dir

Because the opendir function in com32/lib/opendir.c use the eax to store the
dir sector, where we store the file_len before. Well, we may need add a union
structure in the file structure to store the file_len for file, file_dir for
dir respecifictly

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore: code clean
Liu Aleaxander [Sun, 16 Aug 2009 08:41:40 +0000 (16:41 +0800)]
Core: code clean

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agocore: kaboom.c: file missing from previous checkin
H. Peter Anvin [Fri, 14 Aug 2009 05:32:08 +0000 (22:32 -0700)]
core: kaboom.c: file missing from previous checkin

kaboom.c; necessary file missing from previous checkin.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: cleaner way to call kaboom from 32-bit code
H. Peter Anvin [Thu, 13 Aug 2009 04:51:54 +0000 (21:51 -0700)]
core: cleaner way to call kaboom from 32-bit code

Make kaboom() a noreturn function directly callable from 32-bit code.
Do a special macro hack to keep it from interfering with the symbol
kaboom in 16-bit code.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agonetinet/in.h: add __constfunc to inlines
H. Peter Anvin [Thu, 13 Aug 2009 04:39:52 +0000 (21:39 -0700)]
netinet/in.h: add __constfunc to inlines

All the byte-swapping functions are true constfuncs...

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agonetinet/in.h: put in explicit casts for all the hton/ntoh macros
H. Peter Anvin [Thu, 13 Aug 2009 04:37:29 +0000 (21:37 -0700)]
netinet/in.h: put in explicit casts for all the hton/ntoh macros

For the macro versions of hton/ntoh, use casts everywhere.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: use stpcpy() as generic_unmangle_name()
H. Peter Anvin [Thu, 13 Aug 2009 04:31:49 +0000 (21:31 -0700)]
core: use stpcpy() as generic_unmangle_name()

We can use stpcpy() as generic_unmangle_name(); this also gives us the
pointer to the end that the assembly code wants and expects.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoiso9660: adjust to the new VFS
H. Peter Anvin [Thu, 13 Aug 2009 04:30:45 +0000 (21:30 -0700)]
iso9660: adjust to the new VFS

I missed converting iso9660 over to the new VFS.  Do it now.
In particular, getfssec now takes a struct file *.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocom32: remove strpcpy() - we already have stpcpy()
H. Peter Anvin [Thu, 13 Aug 2009 04:23:10 +0000 (21:23 -0700)]
com32: remove strpcpy() - we already have stpcpy()

Remove strpcpy(); it is exactly the same thing as stpcpy() which we
already have, and which is more "standard" (in the sense that none of
these are actually standard...)

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: make FILENAME_MAX common; librarize mangle/unmangle
H. Peter Anvin [Thu, 13 Aug 2009 03:56:46 +0000 (20:56 -0700)]
core: make FILENAME_MAX common; librarize mangle/unmangle

FILENAME_MAX was 2^8 in all variants by now; make it a common define.
Libraries mangle/unmangle; we have generic_mangle_name for Unix-like
filesystems, and unmangle now defaults to simple strcpy.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: more filesystem-specific files into subdirectories
H. Peter Anvin [Thu, 13 Aug 2009 03:23:47 +0000 (20:23 -0700)]
core: more filesystem-specific files into subdirectories

Preemptively move filesystem-specific files into core/fs/<fsname> so
we can start trying to pretend to be organized.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: VFS cleanups: add a persistent generic struct file
H. Peter Anvin [Wed, 12 Aug 2009 00:25:43 +0000 (17:25 -0700)]
core: VFS cleanups: add a persistent generic struct file

Major cleanups to the VFS layer:
- add a persistent generic "struct file"
- pass "struct file *" to getfssec
- add a close_file method
- use VFS-assigned indicies instead of pointers as file handles.
  This allows the file structures to be allocated from high memory.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMerge commit 'liu/master' into fsc syslinux-4.00-pre2
H. Peter Anvin [Tue, 11 Aug 2009 20:20:04 +0000 (13:20 -0700)]
Merge commit 'liu/master' into fsc

14 years agopxe: more tweaks to the open (searchdir) routine
H. Peter Anvin [Tue, 11 Aug 2009 20:17:27 +0000 (13:17 -0700)]
pxe: more tweaks to the open (searchdir) routine

More tweaks to the open (searchdir) routine, in particular in the OACK
packet parsing.  From testing it appears substantially more robust
now.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agonetinet/in.h: adjust hton/ntoh macros to be true constants
H. Peter Anvin [Tue, 11 Aug 2009 20:16:13 +0000 (13:16 -0700)]
netinet/in.h: adjust hton/ntoh macros to be true constants

Tweak the hton/ntoh macros so that they are true constants if the
input is a constant expression; this makes them usable in the
preprocessor.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agopxe: clean up C code; reimplement "Plan C"; share PXE API definitions
H. Peter Anvin [Tue, 11 Aug 2009 18:49:04 +0000 (11:49 -0700)]
pxe: clean up C code; reimplement "Plan C"; share PXE API definitions

Minor cleanups to the C code.
Reimplement "Plan C" for finding the entry point.
Share the PXE API definitions between com32 and the core.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoCore:SYSLINUX: make searchdir do work
Liu Aleaxander [Tue, 11 Aug 2009 09:18:38 +0000 (17:18 +0800)]
Core:SYSLINUX: make searchdir do work

well, still get lots of bugs, like when we execute
dir /boot/syslinux
in fact, it will list the file in /boot/ directory but not in /boot/syslinux/

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore:SYSLINUX: fix the vfat_searchdir
Liu Aleaxander [Tue, 11 Aug 2009 06:16:23 +0000 (14:16 +0800)]
Core:SYSLINUX: fix the vfat_searchdir

This makes the searchdir can find a dir; it's also prepared for the readdir function used in rosh

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agocore: remove assembly definition of Files in iso/pxelinux
H. Peter Anvin [Tue, 11 Aug 2009 00:30:25 +0000 (17:30 -0700)]
core: remove assembly definition of Files in iso/pxelinux

Remove the assembly definition of Files in isolinux and pxelinux.
Still to do: remove dependencies on Files living in .bss16 space.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMCONFIG: update GCCOPT
H. Peter Anvin [Mon, 10 Aug 2009 23:56:06 +0000 (16:56 -0700)]
MCONFIG: update GCCOPT

Add -fwrapv, -freg-struct-return, -fno-exceptions,
-fno-asynchronous-unwind-tables, -fno-strict-aliasing.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: add missing (void), drop casts for Files[], cleanups
H. Peter Anvin [Mon, 10 Aug 2009 23:45:44 +0000 (16:45 -0700)]
core: add missing (void), drop casts for Files[], cleanups

Add missing (void) on no-argument functions, drop casts for Files
(it's now a properly typed array), clean up loop forms.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoext2: fix missing (void), use standard form for loop
H. Peter Anvin [Mon, 10 Aug 2009 23:42:53 +0000 (16:42 -0700)]
ext2: fix missing (void), use standard form for loop

Use the standard form for a for loop; add missing (void).

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMerge commit 'liu/master'; fix Files[] definition
H. Peter Anvin [Mon, 10 Aug 2009 23:39:29 +0000 (16:39 -0700)]
Merge commit 'liu/master'; fix Files[] definition

Resolved Conflicts:
core/extlinux.asm
core/ldlinux.asm

Merge in liu's changes, but fix Files[] to be a private structure
inside the filesystem, thus we don't have to worry about the
size of it in the assembly code at all.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore/diskstart.inc: make the root filesystem a configurable
H. Peter Anvin [Mon, 10 Aug 2009 21:27:21 +0000 (14:27 -0700)]
core/diskstart.inc: make the root filesystem a configurable

Instead of using conditional compilation, just set the root filesystem
type in the assembly stub.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: merge ldlinux.asm and extlinux.asm
H. Peter Anvin [Mon, 10 Aug 2009 02:47:24 +0000 (19:47 -0700)]
core: merge ldlinux.asm and extlinux.asm

ldlinux.asm and extlinux.asm are by now extremely similar.  Merge
them.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMerge branch 'core32' into fsc
H. Peter Anvin [Sun, 9 Aug 2009 21:44:34 +0000 (14:44 -0700)]
Merge branch 'core32' into fsc

14 years agocore: remove hack for dynamic symbol table generation
H. Peter Anvin [Sun, 9 Aug 2009 21:42:50 +0000 (14:42 -0700)]
core: remove hack for dynamic symbol table generation

Kill hack we used to generate a dynamic symbol table.  There is a much
better technique for doing this which is already deployed on the
"dynamic" branch.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoCore:pxelinux: improves the tftp options parsing
Liu Aleaxander [Sun, 9 Aug 2009 07:00:48 +0000 (15:00 +0800)]
Core:pxelinux: improves the tftp options parsing

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agopxe: fix OACK packet handling
Liu Aleaxander [Sun, 9 Aug 2009 06:54:08 +0000 (14:54 +0800)]
pxe: fix OACK packet handling

The current code only works iff the tsize option is set.
This patch fixes the handling of the OACK packet and makes the code
work with all combinations of the tsize and blksize options.

Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
14 years agoMerge branch 'master' into core32
H. Peter Anvin [Sun, 9 Aug 2009 01:48:35 +0000 (18:48 -0700)]
Merge branch 'master' into core32

14 years agoCore: code-clean
Liu Aleaxander [Sat, 8 Aug 2009 09:49:48 +0000 (17:49 +0800)]
Core: code-clean

removes the unused variables and functions

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore: unmangle_name converted
Liu Aleaxander [Sat, 8 Aug 2009 09:39:43 +0000 (17:39 +0800)]
Core: unmangle_name converted

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore:EXTLINUX: fix the bug of open_file_t struct in extlinux
Liu Aleaxander [Sat, 8 Aug 2009 09:03:56 +0000 (17:03 +0800)]
Core:EXTLINUX: fix the bug of open_file_t struct in extlinux

The size of open_file_t structure in extlinux is twice than in the others derivatiives. So we
should cut the MAX_OPEN to half.

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore: move the comman externs to core.h
Liu Aleaxander [Sat, 8 Aug 2009 08:53:24 +0000 (16:53 +0800)]
Core: move the comman externs to core.h

the trackbuf and Files are all uesed in all the four fs, so it would be nice to put the externs
in core.h instead in each c file of the four fs

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agoCore: add _static_ statement to all fs
Liu Aleaxander [Sat, 8 Aug 2009 08:36:26 +0000 (16:36 +0800)]
Core: add _static_ statement to all fs

This well let me far away from some werid trouble

Signed-off-by: Liu Aleaxander <Aleaxander@gmail.com>
14 years agocore:PXELINUX: fix the OACK option parsing bug.
Liu Aleaxander [Sat, 8 Aug 2009 08:05:08 +0000 (16:05 +0800)]
core:PXELINUX: fix the OACK option parsing bug.

the current code can just handle one option beacuse I put the do-while loop in the wrong position.

14 years agoCore: get the rid of the ld warnings
Liu Aleaxander [Sat, 8 Aug 2009 07:51:34 +0000 (15:51 +0800)]
Core: get the rid of the ld warnings

we extern the SecPerClust from diskstart.inc and used in fat.c, but we also defined another
SecPerClust in ext2.c. So we should be better to make more things in _static_, just like hpa told.

14 years agoextlinux: add ext4 support to the installer syslinux-4.00-pre1
H. Peter Anvin [Fri, 7 Aug 2009 07:11:21 +0000 (00:11 -0700)]
extlinux: add ext4 support to the installer

The filesystem code now supports ext4, so support it in the installer
as well.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMakefile: add back the gpxe directory
H. Peter Anvin [Fri, 7 Aug 2009 07:07:02 +0000 (00:07 -0700)]
Makefile: add back the gpxe directory

Add the gpxe directory back into the build.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMerge branch 'core32' into fsc
H. Peter Anvin [Fri, 7 Aug 2009 07:05:28 +0000 (00:05 -0700)]
Merge branch 'core32' into fsc

Resolved Conflicts:
core/extlinux.asm
core/pxelinux.asm

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoCore:PXELINUX: pxelinux derivative merged succeesfully
Liu Aleaxander [Thu, 6 Aug 2009 09:27:02 +0000 (17:27 +0800)]
Core:PXELINUX: pxelinux derivative merged succeesfully

So, now we have all the fs converted, and the rest is to make it better and more simple

14 years agoCore:PXELINUX: try to merge pxelinux
Liu Aleaxander [Thu, 6 Aug 2009 07:17:48 +0000 (15:17 +0800)]
Core:PXELINUX: try to merge pxelinux

the others Syslinux derivative disabled for now

14 years agoNEWS: document isohybrid -id fixed.
H. Peter Anvin [Mon, 3 Aug 2009 21:14:40 +0000 (14:14 -0700)]
NEWS: document isohybrid -id fixed.

14 years agoisohybrid: convert -id to a binary string
Steffen Winterfeldt [Mon, 3 Aug 2009 13:21:02 +0000 (15:21 +0200)]
isohybrid: convert -id to a binary string

Shouldn't 'isohybrid -id ID' write ID as 32bit number? Currently it ends up
as string messing up the mbr.

14 years agomemdisk: remove unnecessary %ifdef syslinux-3.83-pre6
H. Peter Anvin [Sun, 2 Aug 2009 18:59:03 +0000 (11:59 -0700)]
memdisk: remove unnecessary %ifdef

Remove an %ifdef that the macros take care of anyway.

14 years agomemdisk: don't set CX:DX for INT 13h AH=15h for floppies
H. Peter Anvin [Sun, 2 Aug 2009 18:56:38 +0000 (11:56 -0700)]
memdisk: don't set CX:DX for INT 13h AH=15h for floppies

Win98SE DOS apparently hangs if INT 13h, AH=15h returns the capacity
in CX:DX for floppies... *unless* EDD is enabled.  Confused yet?

This patch also adds some more tracing framework.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMEMDISK: additional EDD DPT Fields
Miller, Shao [Sun, 2 Aug 2009 05:33:36 +0000 (01:33 -0400)]
MEMDISK: additional EDD DPT Fields

We incorrectly used "equ" instead of "dd" (or "db") for strings in
memdisk.inc.  Oops!  My mistake in my 'freedos' branch.  Silly
mistake.  - Shao

15 years agomemdisk: correct the types for the EDD DPT, and write a real one syslinux-3.83-pre5
H. Peter Anvin [Fri, 31 Jul 2009 15:27:58 +0000 (08:27 -0700)]
memdisk: correct the types for the EDD DPT, and write a real one

Fix the sizes of some of the fields in the EDD DPT.  Write a real one
to the best of our ability.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agomemdisk: don't write the EDD DPT unless we are in EDD mode...
H. Peter Anvin [Fri, 31 Jul 2009 15:24:27 +0000 (08:24 -0700)]
memdisk: don't write the EDD DPT unless we are in EDD mode...

Don't write the EDD DPT unless we're actually in EDD mode!  Otherwise
we end up corrupting memory beyond the defined code.  This was the
reason 5ca2764460883f5e9a5bd83db00f242ea1272e33 worked, by moving
variables out of the corruption zone.

Debugged-by: Shao Miller <Shao.Miller@yrdsb.edu.on.ca>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoMerge commit 'andytim/freedos'
H. Peter Anvin [Fri, 31 Jul 2009 05:40:06 +0000 (22:40 -0700)]
Merge commit 'andytim/freedos'

15 years agographics: actually do 32-bit writes to VGA
H. Peter Anvin [Fri, 31 Jul 2009 05:27:16 +0000 (22:27 -0700)]
graphics: actually do 32-bit writes to VGA

Use "rep movsd" to copy data to VGA memory, not "rep movsb".

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years ago[memdisk] Additional EDD Device Parameter Table fields
Shao Miller [Fri, 31 Jul 2009 05:27:05 +0000 (01:27 -0400)]
[memdisk] Additional EDD Device Parameter Table fields

Some additional fields from the EDD-4 spec. draft for the Device Parameter
Table have been added into the structure in setup.c and memdisk.inc.  These
were added in the hopes of resolving a FreeDOS MEMDISK bug on IBM ThinkPads.

15 years agographics: trivial optimization of old-style graphic mode syslinux-3.83-pre4
H. Peter Anvin [Fri, 31 Jul 2009 00:44:12 +0000 (17:44 -0700)]
graphics: trivial optimization of old-style graphic mode

Trivially optimize the old-style graphics by using another level of
temporary buffering in bitplane format, thereby enabling the use of
rep movsd to write the contents to the screen.  This can speed things
up substantially in virtualization environments.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoNEWS: document Thinkpad fix syslinux-3.83-pre3
H. Peter Anvin [Thu, 30 Jul 2009 19:31:10 +0000 (12:31 -0700)]
NEWS: document Thinkpad fix

15 years agomemdisk: move temporary variables away from the EDD data block
H. Peter Anvin [Thu, 30 Jul 2009 19:28:45 +0000 (12:28 -0700)]
memdisk: move temporary variables away from the EDD data block

Move a couple of variables away from the EDD data block.  Without this
change, FreeDOS doesn't boot on Thinkpads.  Unfortunately, this should
have been a null change, so it is really not clear why this happens.
Stack overflows have been ruled out.  Probably need to examine the
FreeDOS kernel in some detail.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agomemdisk: handle recursive INT 13h invocation
H. Peter Anvin [Thu, 30 Jul 2009 18:24:25 +0000 (11:24 -0700)]
memdisk: handle recursive INT 13h invocation

Some systems, e.g. a lot of Thinkpads, invoke INT 13h recursively from
within the stack itself.  This is generally a bad idea as it re-runs
any INT 13h hooks (including the ones that DOS installs!), but it
should work.  Keep a counter of recursive invocations and simply
bypass the whole system including the DL shift if the invocation is
recursive.

With this, MS-DOS boots on a Thinkpad T61.  FreeDOS is still broken,
though, but apparently in a different manner...

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoPXELINUX: allow filenames up to 251 characters long syslinux-3.83-pre2
H. Peter Anvin [Wed, 29 Jul 2009 03:19:14 +0000 (20:19 -0700)]
PXELINUX: allow filenames up to 251 characters long

At least one users really need this, so be nice and provide it...

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoMerge commit 'syslinux-3.83-pre1'
H. Peter Anvin [Mon, 27 Jul 2009 18:15:43 +0000 (11:15 -0700)]
Merge commit 'syslinux-3.83-pre1'

Conflicts:
com32/modules/chain.c

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoNEWS: document chain.c32 ISOLINUX fix. syslinux-3.83-pre1
H. Peter Anvin [Fri, 24 Jul 2009 00:24:13 +0000 (17:24 -0700)]
NEWS: document chain.c32 ISOLINUX fix.

15 years agochain.c32: set DL properly when loaded from ISOLINUX
H. Peter Anvin [Fri, 24 Jul 2009 00:23:04 +0000 (17:23 -0700)]
chain.c32: set DL properly when loaded from ISOLINUX

When loaded from ISOLINUX, we still have a valid boot drive.  Set it!
This permits the use of chainloaded boot loaders.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoCore: some bugs fixed
Liu Aleaxander [Mon, 20 Jul 2009 00:46:16 +0000 (08:46 +0800)]
Core: some bugs fixed

15 years agogfxboot: remove obsolete message regarding pxelinux support
Sebastian Herbszt [Sat, 18 Jul 2009 15:06:32 +0000 (17:06 +0200)]
gfxboot: remove obsolete message regarding pxelinux support

PXELINUX is supported by the gfxboot module.

Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
15 years agogfxboot: parse TIMEOUT keyword
Sebastian Herbszt [Sat, 18 Jul 2009 15:05:22 +0000 (17:05 +0200)]
gfxboot: parse TIMEOUT keyword

Parse the TIMEOUT keyword from the config file and pass it to gfxboot core.

Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
15 years agogfxboot: only call gfxboot core if labels are specified
Sebastian Herbszt [Sat, 18 Jul 2009 15:03:29 +0000 (17:03 +0200)]
gfxboot: only call gfxboot core if labels are specified

Only call gfxboot core if labels are specified in the config file.

Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
15 years agogfxboot: display error message if bootlogo file not found
Sebastian Herbszt [Sat, 18 Jul 2009 15:01:19 +0000 (17:01 +0200)]
gfxboot: display error message if bootlogo file not found

Display an error message if the user specified bootlogo file is not found.

Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
15 years agogfxboot: change handling of keywords
Sebastian Herbszt [Sat, 18 Jul 2009 14:53:09 +0000 (16:53 +0200)]
gfxboot: change handling of keywords

Makes handling of keywords more flexible.

Signed-off-by: Sebastian Herbszt <herbszt@gmx.de>
15 years agoextlinux: handle more than one sector of sector pointers
H. Peter Anvin [Thu, 16 Jul 2009 16:11:14 +0000 (12:11 -0400)]
extlinux: handle more than one sector of sector pointers

Fix the extlinux installer so we can handle more than one sector of
sector pointers.  This code should be merged with the equivalent code
in the syslinux installer.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoCore: do trick on the hybrid mode detection
Liu Aleaxander [Mon, 13 Jul 2009 08:08:12 +0000 (16:08 +0800)]
Core: do trick on the hybrid mode detection

15 years agoCore: fix the hybride mode detection code
Liu Aleaxander [Mon, 13 Jul 2009 07:56:51 +0000 (15:56 +0800)]
Core: fix the hybride mode detection code

15 years agoCore: code clean
Liu Aleaxander [Mon, 13 Jul 2009 06:47:02 +0000 (14:47 +0800)]
Core: code clean

cleans the unused variables\18

15 years agoCore: fix the HD-mode error in isolinux
Liu Aleaxander [Mon, 13 Jul 2009 06:34:52 +0000 (14:34 +0800)]
Core: fix the HD-mode error in isolinux

error fixed. Just as what hpa told, deal with that might simply be to consider a 2K CD sector a
"block" rather than a "sector". so, in cdrom mode, we have 2K blocksize and 2k sector size, while
in hybrid mode we have 2k blocksize and 512 bytes sector size.

15 years agodos: add pointer to PE header in binary
H. Peter Anvin [Fri, 10 Jul 2009 23:40:20 +0000 (16:40 -0700)]
dos: add pointer to PE header in binary

Explicitly add the pointer to the PE header in the binary.  That way
we might be eventually able to create a merged DOS/Win32 binary.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoCore: changes the sector_t and block_t types to be uint64_t
Liu Aleaxander [Fri, 10 Jul 2009 21:46:47 +0000 (05:46 +0800)]
Core: changes the sector_t and block_t types to be uint64_t

15 years agocom32: add openmem.o to the Makefile
H. Peter Anvin [Thu, 9 Jul 2009 19:15:21 +0000 (12:15 -0700)]
com32: add openmem.o to the Makefile

We need openmem.o in the Makefile if it's actually supposed to get
built...

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoAdd openmem() function to read from memory as if it were a file
H. Peter Anvin [Thu, 9 Jul 2009 18:56:17 +0000 (11:56 -0700)]
Add openmem() function to read from memory as if it were a file

Reading from memory as if it were a file is pretty easy... we just
treat it as a really big block buffer and tell the file layer that we
already closed the underlying handle.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agocore: include exported symbol information
H. Peter Anvin [Thu, 9 Jul 2009 17:48:57 +0000 (10:48 -0700)]
core: include exported symbol information

Extract symbol table information to be exported to modules.  This is a
really hacky way of doing it, so replace it later.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agosyslinux.ld: add support for .ctors and .dtors
H. Peter Anvin [Wed, 8 Jul 2009 23:29:35 +0000 (16:29 -0700)]
syslinux.ld: add support for .ctors and .dtors

We're going to need at least constructors when we start linking in
com32 library code in a serious way.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agocore: give 64K to the PM stack
H. Peter Anvin [Wed, 8 Jul 2009 00:02:44 +0000 (17:02 -0700)]
core: give 64K to the PM stack

Give a full aligned 64K chunk for the PM stack.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoCore: code clean: cuts the unnecessary data type conversion in disk read-write function
Liu Aleaxander [Tue, 7 Jul 2009 16:59:03 +0000 (00:59 +0800)]
Core: code clean: cuts the unnecessary data type conversion in disk read-write function

It's unnecessary to do that conversion.

15 years agoCore: code clean: breakup the fs->fs_dev->disk stuff
Liu Aleaxander [Tue, 7 Jul 2009 16:44:45 +0000 (00:44 +0800)]
Core: code clean: breakup the fs->fs_dev->disk stuff

Add a new disk structure pointer disk to point to fs->fs_dev_disk to break the
long code.

15 years agoMerge branch 'master' into core32
H. Peter Anvin [Mon, 6 Jul 2009 00:14:54 +0000 (17:14 -0700)]
Merge branch 'master' into core32

15 years agodosutil/Makefile: more complete structure
H. Peter Anvin [Sun, 5 Jul 2009 21:15:12 +0000 (14:15 -0700)]
dosutil/Makefile: more complete structure

More complete and consistent structure for dosutil/Makefile.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agodosutil/Makefile: more complete structure
H. Peter Anvin [Sun, 5 Jul 2009 21:15:12 +0000 (14:15 -0700)]
dosutil/Makefile: more complete structure

More complete and consistent structure for dosutil/Makefile.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoMerge branch 'master' into core32
H. Peter Anvin [Sun, 5 Jul 2009 08:05:48 +0000 (01:05 -0700)]
Merge branch 'master' into core32

15 years agodosutil: update mdiskchk, add Makefile
H. Peter Anvin [Sun, 5 Jul 2009 08:04:50 +0000 (01:04 -0700)]
dosutil: update mdiskchk, add Makefile

Update mdiskchk and add a Makefile.  Note that since this needs
OpenWatcom to compile, we still check in the binary file (which is
quite small, anyway.)

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agocore/rllpack.c: fix some particular bad formatting
H. Peter Anvin [Wed, 1 Jul 2009 21:24:23 +0000 (14:24 -0700)]
core/rllpack.c: fix some particular bad formatting

indent doesn't always do the right thing...

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoMerge branch 'master' into core32
H. Peter Anvin [Sat, 27 Jun 2009 00:45:51 +0000 (17:45 -0700)]
Merge branch 'master' into core32

15 years agoCreate a dosutil subdirectory and move mdiskchk there
H. Peter Anvin [Sat, 27 Jun 2009 00:44:22 +0000 (17:44 -0700)]
Create a dosutil subdirectory and move mdiskchk there

DOS utilities aren't really "samples".  Create a dedicated "dosutil"
directory, and move mdiskchk there for now.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agodos: assume NASM 2.03, so use -MP -MD for dependencies
H. Peter Anvin [Wed, 24 Jun 2009 23:39:08 +0000 (16:39 -0700)]
dos: assume NASM 2.03, so use -MP -MD for dependencies

Assume NASM 2.03 or later, so use -MP -MD to generate dependencies.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agocore: assume NASM 2.03 or later, so we can use -MD for deps
H. Peter Anvin [Wed, 24 Jun 2009 23:36:50 +0000 (16:36 -0700)]
core: assume NASM 2.03 or later, so we can use -MD for deps

Let's require NASM 2.03 or later, so we can use the -MD and -MP
options to generate dependencies.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoMCONFIG: we need NASM 2 these days, use -Ox
H. Peter Anvin [Wed, 24 Jun 2009 23:26:59 +0000 (16:26 -0700)]
MCONFIG: we need NASM 2 these days, use -Ox

We need NASM 2 anyway for this branch, so we might as well use the -Ox
option.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
15 years agoMCONFIG: build GCCOPT one step at a time, don't align stack
H. Peter Anvin [Wed, 24 Jun 2009 22:55:43 +0000 (15:55 -0700)]
MCONFIG: build GCCOPT one step at a time, don't align stack

Some gcc options are only valid together with other gcc options, so
build GCCOPT one bit at a time, and change gcc_ok to take already
existing GCCOPT flags into account.

This lets us build with -mpreferred-stack-boundary=2, which is only
valid on 32 bits and therefore with -m32.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>