profile/ivi/syslinux.git
14 years agochain.c32, libcom32: Move gpt_dump() as disk_gpt_header_dump()
Shao Miller [Mon, 28 Jun 2010 10:21:21 +0000 (06:21 -0400)]
chain.c32, libcom32: Move gpt_dump() as disk_gpt_header_dump()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move struct gpt as disk_gpt_header
Shao Miller [Mon, 28 Jun 2010 10:16:27 +0000 (06:16 -0400)]
chain.c32, libcom32: Move struct gpt as disk_gpt_header

Also moved gpt_sig_magic as disk_gpt_sig_magic.
Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move gpt_part_dump() as disk_gpt_part_dump()
Shao Miller [Mon, 28 Jun 2010 10:07:04 +0000 (06:07 -0400)]
chain.c32, libcom32: Move gpt_part_dump() as disk_gpt_part_dump()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move guid_to_str() and str_to_guid()
Shao Miller [Mon, 28 Jun 2010 09:30:06 +0000 (05:30 -0400)]
chain.c32, libcom32: Move guid_to_str() and str_to_guid()

Moving portions of chain.c32 into libcom32.
There might be a better header for these to belong to.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move struct gpt_part as disk_gpt_part_entry
Shao Miller [Mon, 28 Jun 2010 07:42:44 +0000 (03:42 -0400)]
chain.c32, libcom32: Move struct gpt_part as disk_gpt_part_entry

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move guid_le_walk_map
Shao Miller [Mon, 28 Jun 2010 07:34:55 +0000 (03:34 -0400)]
chain.c32, libcom32: Move guid_le_walk_map

Moving portions of chain.c32 into libcom32.
There might be a better header for guid_le_walk_map to belong to.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move struct guid
Shao Miller [Mon, 28 Jun 2010 07:18:09 +0000 (03:18 -0400)]
chain.c32, libcom32: Move struct guid

Moving portions of chain.c32 into libcom32.
There might be a better header for struct guid to belong to.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move struct mbr as disk_dos_mbr
Shao Miller [Mon, 28 Jun 2010 07:02:14 +0000 (03:02 -0400)]
chain.c32, libcom32: Move struct mbr as disk_dos_mbr

Also move mbr_sig_magic as disk_mbr_sig_magic macro.
Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move mbr_part_dump() as disk_dos_part_dump()
Shao Miller [Mon, 28 Jun 2010 06:54:36 +0000 (02:54 -0400)]
chain.c32, libcom32: Move mbr_part_dump() as disk_dos_part_dump()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move struct part_entry as disk_dos_part_entry
Shao Miller [Mon, 28 Jun 2010 06:47:30 +0000 (02:47 -0400)]
chain.c32, libcom32: Move struct part_entry as disk_dos_part_entry

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move chs macros and chs typedef as disk_chs
Shao Miller [Mon, 28 Jun 2010 06:40:12 +0000 (02:40 -0400)]
chain.c32, libcom32: Move chs macros and chs typedef as disk_chs

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agolibcom32 disk: A slight grunt of constipation
Shao Miller [Mon, 28 Jun 2010 06:30:49 +0000 (02:30 -0400)]
libcom32 disk: A slight grunt of constipation

Add const qualifier because we can.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move write_verify_sector() as disk_write_verify_sector()
Shao Miller [Mon, 28 Jun 2010 06:26:11 +0000 (02:26 -0400)]
chain.c32, libcom32: Move write_verify_sector() as disk_write_verify_sector()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move write_sector() as disk_write_sector()
Shao Miller [Mon, 28 Jun 2010 06:14:08 +0000 (02:14 -0400)]
chain.c32, libcom32: Move write_sector() as disk_write_sector()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agolibcom32 disk: Trivial formatting fix-up
Shao Miller [Mon, 28 Jun 2010 05:54:38 +0000 (01:54 -0400)]
libcom32 disk: Trivial formatting fix-up

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move read_sectors() as disk_read_sectors()
Shao Miller [Mon, 28 Jun 2010 05:53:28 +0000 (01:53 -0400)]
chain.c32, libcom32: Move read_sectors() as disk_read_sectors()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move struct ebios_dapa as disk_ebios_dapa
Shao Miller [Mon, 28 Jun 2010 05:36:35 +0000 (01:36 -0400)]
chain.c32, libcom32: Move struct ebios_dapa as disk_ebios_dapa

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move get_disk_params() as disk_get_params()
Shao Miller [Mon, 28 Jun 2010 05:22:04 +0000 (01:22 -0400)]
chain.c32, libcom32: Move get_disk_params() as disk_get_params()

Also moved struct diskinfo as disk_info.
Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32: Run Nindent on com32/modules/chain.c
Shao Miller [Mon, 28 Jun 2010 05:03:46 +0000 (01:03 -0400)]
chain.c32: Run Nindent on com32/modules/chain.c

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agochain.c32, libcom32: Move int13_retry() as disk_int13_retry()
Shao Miller [Mon, 28 Jun 2010 04:59:17 +0000 (00:59 -0400)]
chain.c32, libcom32: Move int13_retry() as disk_int13_retry()

Moving portions of chain.c32 into libcom32.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agolibcom32: Introduce disk header and module
Shao Miller [Mon, 28 Jun 2010 04:31:08 +0000 (00:31 -0400)]
libcom32: Introduce disk header and module

An effort to move significant portions out of chain.c32 and
into library is underway.  We begin by simply moving
SECTOR into a header and building a disk module.

Note that some of this work will essentially duplicate
some of what's found in Pierre-Alexandre Meyer's fine
work in com32/gpllib/disk/.  A difference would be the
licensing, of course.

Signed-off-by: Shao Miller <shao.miller@yrdsb.edu.on.ca>
14 years agoNEWS: correct credit for new Lua work.
H. Peter Anvin [Thu, 8 Jul 2010 21:53:02 +0000 (14:53 -0700)]
NEWS: correct credit for new Lua work.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: update syslinux-4.02-pre1
H. Peter Anvin [Thu, 8 Jul 2010 21:22:40 +0000 (14:22 -0700)]
NEWS: update

Update in preparation of a 4.02 release cycle.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoDMI: Fixing memory mgmnt in dmi_memory_module_types
Laurent Licour [Wed, 7 Jul 2010 18:53:22 +0000 (20:53 +0200)]
DMI: Fixing memory mgmnt in dmi_memory_module_types

In some case, dmi_memory_module_types could read the entire memory as a
result of a bogus snprintf usage.

14 years agozlib: rename DEBUG to DEBUG_ZLIB again
H. Peter Anvin [Tue, 6 Jul 2010 21:16:15 +0000 (14:16 -0700)]
zlib: rename DEBUG to DEBUG_ZLIB again

We don't want to use the global DEBUG for zlib...

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agomtools: slightly more obvious definition of tmpdir fallback
H. Peter Anvin [Tue, 6 Jul 2010 01:16:02 +0000 (18:16 -0700)]
mtools: slightly more obvious definition of tmpdir fallback

Make it a bit more obvious what actually happens for the tmpdir
fallback.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agomtools: honor TMPDIR, check for errors writing mtools.conf
H. Peter Anvin [Tue, 6 Jul 2010 01:12:29 +0000 (18:12 -0700)]
mtools: honor TMPDIR, check for errors writing mtools.conf

Honor TMPDIR when picking a place to write mtools.conf.

Check for errors while writing mtools.conf.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agobtrfs: print an error if finding compressed/encrypted data
H. Peter Anvin [Tue, 6 Jul 2010 00:50:13 +0000 (17:50 -0700)]
btrfs: print an error if finding compressed/encrypted data

If we find compressed or encrypted data, print an error message
instead of returning garbage.  This is suboptimal, but at least
handles the common subcase of an encrypted configuration file.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMerge remote branch 'gerth/ifcpu_remove_defines'
H. Peter Anvin [Tue, 6 Jul 2010 00:43:51 +0000 (17:43 -0700)]
Merge remote branch 'gerth/ifcpu_remove_defines'

14 years agoifcpu.c32: Remove defines used in the old sleep function.
Gert Hulselmans [Mon, 5 Jul 2010 23:59:40 +0000 (01:59 +0200)]
ifcpu.c32: Remove defines used in the old sleep function.

Remove useless defines which where used in the old sleep function.

Signed-off-by: Gert Hulselmans <gerth@zytor.com>
14 years agoNEWS: add grubcfg= and whichsys.c32
Gert Hulselmans [Mon, 5 Jul 2010 23:43:29 +0000 (01:43 +0200)]
NEWS: add grubcfg= and whichsys.c32

Add grubcfg= and whichsys.c32 to the NEWS file.

14 years agoNEWS: add grubcfg= and whichsys.c32
Gert Hulselmans [Mon, 5 Jul 2010 23:38:29 +0000 (01:38 +0200)]
NEWS: add grubcfg= and whichsys.c32

Add grubcfg= and whichsys.c32 to the NEWS file.

14 years agoMerge remote branch 'gerth/whichsys'
H. Peter Anvin [Mon, 5 Jul 2010 23:05:50 +0000 (16:05 -0700)]
Merge remote branch 'gerth/whichsys'

14 years agoMerge remote branch 'gerth/chain_grubcfg'
H. Peter Anvin [Mon, 5 Jul 2010 23:05:44 +0000 (16:05 -0700)]
Merge remote branch 'gerth/chain_grubcfg'

14 years agoifcpu.c32: need <unistd.h>
H. Peter Anvin [Mon, 5 Jul 2010 22:59:36 +0000 (15:59 -0700)]
ifcpu.c32: need <unistd.h>

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoifcpu.c32: remove open-coded sleep function
H. Peter Anvin [Mon, 5 Jul 2010 22:58:45 +0000 (15:58 -0700)]
ifcpu.c32: remove open-coded sleep function

Remove open-coded sleep function, which uses an unreliable BIOS call.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agolua: change syslinux.sleep() to seconds, syslinux.msleep() to ms
H. Peter Anvin [Mon, 5 Jul 2010 22:52:07 +0000 (15:52 -0700)]
lua: change syslinux.sleep() to seconds, syslinux.msleep() to ms

For consistency with just about everything else, make syslinux.sleep()
count seconds, and syslinux.msleep() count milliseconds.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocom32: add proper sleep()/msleep() functions and make Lua use them
H. Peter Anvin [Mon, 5 Jul 2010 22:45:37 +0000 (15:45 -0700)]
com32: add proper sleep()/msleep() functions and make Lua use them

Add proper sleep() and msleep() functions, which among other things
call syslinux_idle(), and make Lua use them.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocom32: change clock_t to 32 bits, and in milliseconds
H. Peter Anvin [Mon, 5 Jul 2010 22:43:09 +0000 (15:43 -0700)]
com32: change clock_t to 32 bits, and in milliseconds

Previously, clock_t was 16 bits and counted timer ticks, now make it
32 bits and count milliseconds.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore: add a ms-denominated timer
H. Peter Anvin [Mon, 5 Jul 2010 22:41:36 +0000 (15:41 -0700)]
core: add a ms-denominated timer

Add a timer denominated in milliseconds.  This is still driven by the
18.2 Hz timer interrupt, but counts "real" milliseconds, including
handing the adjustment factor (which in reality means it advances by
55 for most timer ticks and 54 for some.)

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agowhichsys.c32: execute specific command, based on Syslinux bootloader variant
Gert Hulselmans [Mon, 5 Jul 2010 21:52:39 +0000 (23:52 +0200)]
whichsys.c32: execute specific command, based on Syslinux bootloader variant

Detemine which command to execute, based on the Syslinux bootloader variant
from which you run it.

  Usage:    whichsys.c32 [-iso- command] [-pxe- command] [-sys- command]
  Examples: whichsys.c32 -iso- chain.c32 hd0 -sys- chain.c32 hd1 swap
            whichsys.c32 -iso- config iso.cfg -sys- sys.cfg -pxe- pxe.cfg

Signed-off-by: Gert Hulselmans <gerth@zytor.com>
14 years agoMerge remote branch 'marcel/luaext'
H. Peter Anvin [Mon, 5 Jul 2010 21:23:50 +0000 (14:23 -0700)]
Merge remote branch 'marcel/luaext'

Merge Marcel Ritter's work on the lua branch:

The last time he wrote about the state of his lua branch:
http://syslinux.zytor.com/archives/2009-October/013383.html

The current state is:

- VESA:
  - switching to vesa mode works
  - loading/displaying images works
  - display text works (s. com32/lua/test/vesa.lua)

- PCI:
  - list PC devices + ID
  - get human-readable device name for device
   (s. com32/lua/test/pci.lua)

- DMI:
  - get DMI info (BIOS, Hardware, etc).
  (s. com32/lua/test/dmi.lua)

- syslinux:
  - loading files, kernel, initrd
  - start kernel, initrd, local boot
  ... just working on this, so no example lua file right now

Most of the actual merging work was done by Gert Hulselmans <gerth@zytor.com>.

Resolved Conflicts:
com32/lib/sys/vesa/initvesa.c
com32/lua/src/Makefile

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agozlib: update to zlib 1.2.5
H. Peter Anvin [Mon, 5 Jul 2010 20:41:04 +0000 (13:41 -0700)]
zlib: update to zlib 1.2.5

Update zlib to zlib 1.2.5.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agochain.c32: Put declaration of *stage2 before common code
Gert Hulselmans [Mon, 5 Jul 2010 12:04:46 +0000 (14:04 +0200)]
chain.c32: Put declaration of *stage2 before common code

Put declaration of *stage2 before common code.

Signed-off-by: Gert Hulselmans <gerth@zytor.com>
14 years agolibpng: upgrade to version 1.2.44
H. Peter Anvin [Mon, 5 Jul 2010 05:29:42 +0000 (22:29 -0700)]
libpng: upgrade to version 1.2.44

Upgrade libpng from 1.2.8 to 1.2.44.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agochain.c32: add grubcfg= for passing an alternative config filename to GRUB Legacy...
Gert Hulselmans [Sun, 4 Jul 2010 18:35:15 +0000 (20:35 +0200)]
chain.c32:  add grubcfg= for passing an alternative config filename to GRUB Legacy and cleanup the root partition passing

GRUB Legacy reserves 89 bytes for storing the filename of the configfile
from memory address 0x8217 to 0x826f.
We allow overwriting the default value (/boot/grub/menu.lst) when
grubcfg=<filename> is used together with grub=<loader>.

Examples:
  chain.c32 fs grub=/boot/grub/stage2 grubcfg=/boot/grub/grub.lst
  chain.c32 hd1,10 grub=/boot/grub/stage2 grubcfg=/boot/grub/grub.lst

Use a structure instead of hard-coded offsets for modifying the install_partition variable
(and the configfile name) in the stage2 file.

Add some comments about the "boot information format" of the Multiboot specification, which
is very similar to the install_partition variable used by GRUB Legacy.

Signed-off-by: Gert Hulselmans <gerth@zytor.com>
14 years agocom32: update getopt() to the current version from klibc
H. Peter Anvin [Sat, 3 Jul 2010 01:00:42 +0000 (18:00 -0700)]
com32: update getopt() to the current version from klibc

Update getopt() to the current klibc version.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocom32: add getopt_long() to the library
H. Peter Anvin [Sat, 3 Jul 2010 00:57:17 +0000 (17:57 -0700)]
com32: add getopt_long() to the library

Add getopt_long() to the library.  This is code lifted straight out of
klibc.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoNEWS, version: now working on version 4.02
H. Peter Anvin [Fri, 2 Jul 2010 23:48:24 +0000 (16:48 -0700)]
NEWS, version: now working on version 4.02

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore: split loadconfig.c into two files
H. Peter Anvin [Fri, 2 Jul 2010 23:19:59 +0000 (16:19 -0700)]
core: split loadconfig.c into two files

Split loadconfig.c into two files.  In particular, isolinux needs
search_config() but not generic_load_config().

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore: merge the configfile-searching code, isolinux generic names
H. Peter Anvin [Fri, 2 Jul 2010 23:13:44 +0000 (16:13 -0700)]
core: merge the configfile-searching code, isolinux generic names

Merge the config file searching code between syslinux and isolinux,
and make isolinux also recognize the generic names "syslinux" and
"syslinux.cfg".  Thus, isolinux now searches for configuration files
in the following order:

/boot/isolinux/isolinux.cfg
/boot/isolinux/syslinux.cfg
/isolinux/isolinux.cfg
/isolinux/syslinux.cfg
/boot/syslinux/isolinux.cfg
/boot/syslinux/syslinux.cfg
/syslinux/isolinux.cfg
/syslinux/syslinux.cfg
/isolinux.cfg
/syslinux.cfg

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore: always canonicalize the configuration file name
H. Peter Anvin [Fri, 2 Jul 2010 23:01:19 +0000 (16:01 -0700)]
core: always canonicalize the configuration file name

The FAT installers may not produce a canonical pathname in the
CurrentDirName field on entry.  Make sure that the core doesn't croak
when that happens, and still produces an absolute pathname for the
configuration file.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agolua: quiet warnings about unused variables and functions syslinux-4.01
H. Peter Anvin [Fri, 2 Jul 2010 18:19:39 +0000 (11:19 -0700)]
lua: quiet warnings about unused variables and functions

Quiet gcc warnings about unused variables and functions -- things that
are not used in the Syslinux environment at this time.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agolua: add parents to luaconf.h to quiet a gcc warning
H. Peter Anvin [Fri, 2 Jul 2010 18:18:57 +0000 (11:18 -0700)]
lua: add parents to luaconf.h to quiet a gcc warning

gcc warns about suspicious-looking code with a comparison inside ==.
The code is correct, but add parens so that gcc know we know it is
correct.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agolua: add missing <syslinux/boot.h> to syslinux.c
H. Peter Anvin [Fri, 2 Jul 2010 18:18:24 +0000 (11:18 -0700)]
lua: add missing <syslinux/boot.h> to syslinux.c

Need header files for functions we invoke.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agolua: Modernize the Makefile
H. Peter Anvin [Fri, 2 Jul 2010 18:16:40 +0000 (11:16 -0700)]
lua: Modernize the Makefile

Modernize the Makefile for lua to match the current style, in
particular to have it pick up its configuration and rules from the
central MCONFIG file.

This also fixes the incorrect use of "clean" vs. "spotless" which was
picked up from the Makefile style in use at that time.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: explain the memory overwrite bug a bit better
H. Peter Anvin [Fri, 2 Jul 2010 18:00:51 +0000 (11:00 -0700)]
NEWS: explain the memory overwrite bug a bit better

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoFix nuisance _FORTIFY_SOURCE failures
H. Peter Anvin [Fri, 2 Jul 2010 16:49:45 +0000 (09:49 -0700)]
Fix nuisance _FORTIFY_SOURCE failures

Fix a couple of _FORTIFY_SOURCE failures which are nuisance warnings,
but fortunately not too hard to just plain avoid.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoinstallers: handle asprintf() correctly
H. Peter Anvin [Fri, 2 Jul 2010 16:39:18 +0000 (09:39 -0700)]
installers: handle asprintf() correctly

It appears that the glibc version of asprintf() is braindamaged, and
doesn't set the target pointer to NULL in the event of an error (only
returns -1).  Therefore we need to check the return value.  Just in
case someone else made the *opposite* error, also check the pointer.

Bleh.  The glibc documentation states that *BSD sets the pointer to
NULL, but instead of following that, the glibc people put
warn_unused_result on asprintf.  Sigh.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoDocument 'nopassany' in MEMDISK documentation.
Gert Hulselmans [Sat, 6 Mar 2010 21:56:41 +0000 (13:56 -0800)]
Document 'nopassany' in MEMDISK documentation.

'nopassany' is missing in the MEMDISK documentation:
http://www.zytor.com/pipermail/syslinux-commits/2010-February/000096.html

14 years agopxelinux: new IPAPPEND 4 to generate a SYSUUID= option. syslinux-4.01-pre3
H. Peter Anvin [Fri, 2 Jul 2010 02:44:53 +0000 (19:44 -0700)]
pxelinux: new IPAPPEND 4 to generate a SYSUUID= option.

Add a new IPAPPEND option to generate a SYSUUID= option with the
in-system UUID.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMakefile: add lua.c32 to installables syslinux-4.01-pre2
H. Peter Anvin [Fri, 2 Jul 2010 01:12:41 +0000 (18:12 -0700)]
Makefile: add lua.c32 to installables

lua.c32 is an installable file.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore, diskio: reset controller between EDD retries
H. Peter Anvin [Fri, 2 Jul 2010 01:10:22 +0000 (18:10 -0700)]
core, diskio: reset controller between EDD retries

As documented in the old assembly code, reset the disk controller
between retries when using EDD.  We don't want to do that for CHS,
since a reset shuts down the floppy motor, and we might be suffering a
timeout.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoMerge branch 'lua'
H. Peter Anvin [Fri, 2 Jul 2010 01:08:24 +0000 (18:08 -0700)]
Merge branch 'lua'

Resolved Conflicts:
NEWS

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: document memory overwrite fix
H. Peter Anvin [Fri, 2 Jul 2010 01:05:57 +0000 (18:05 -0700)]
NEWS: document memory overwrite fix

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocom32: canonicalize DEBUG to mean <dprintf.h>
H. Peter Anvin [Fri, 2 Jul 2010 01:04:13 +0000 (18:04 -0700)]
com32: canonicalize DEBUG to mean <dprintf.h>

Remove historical uses of DEBUG/dprintf in favor of the centralized
<dprintf.h>.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agozlib: change DEBUG to DEBUG_ZLIB
H. Peter Anvin [Fri, 2 Jul 2010 01:03:01 +0000 (18:03 -0700)]
zlib: change DEBUG to DEBUG_ZLIB

zlib uses DEBUG for something slightly different than the Syslinux
main code, so change the name of the symbol.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agodprintf: allow overriding the serial port address
H. Peter Anvin [Fri, 2 Jul 2010 01:02:11 +0000 (18:02 -0700)]
dprintf: allow overriding the serial port address

Allow overriding the serial port address, e.g. for systems which only
have PCI serial ports.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocomboot.inc: vk_append is a field in a struct, not an address
H. Peter Anvin [Fri, 2 Jul 2010 00:59:30 +0000 (17:59 -0700)]
comboot.inc: vk_append is a field in a struct, not an address

We want to use VKernelBuf as temporary storage, not vk_append.
vk_append is an offset into a larger buffer, and we ended up
corrupting low BIOS memory.

Reported-by: Joseph Cihula <joseph.cihula@intel.com>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: add lua.c32
H. Peter Anvin [Thu, 1 Jul 2010 21:29:42 +0000 (14:29 -0700)]
NEWS: add lua.c32

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agolua: update for Syslinux 4
Geert Stappers [Thu, 1 Jul 2010 19:14:38 +0000 (21:14 +0200)]
lua: update for Syslinux 4

Update the lua code to work with Syslinux 4.

14 years agoMerge branch 'master' into lua
H. Peter Anvin [Thu, 1 Jul 2010 21:26:36 +0000 (14:26 -0700)]
Merge branch 'master' into lua

Resolved Conflicts:
com32/Makefile

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoMCONFIG: add -Wno-error to .lnx files
H. Peter Anvin [Thu, 1 Jul 2010 21:21:14 +0000 (14:21 -0700)]
MCONFIG: add -Wno-error to .lnx files

Again, .lnx files are test vehicles... erroring out due to warnings
makes no sense.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoMCONFIG: .lnx files are for testing, don't do _FORTIFY_SOURCE
H. Peter Anvin [Thu, 1 Jul 2010 21:15:38 +0000 (14:15 -0700)]
MCONFIG: .lnx files are for testing, don't do _FORTIFY_SOURCE

.lnx files are strictly a testing vehicle.  It makes absolutely no
sense to enforce the often rather arbitrary rules of _FORTIFY_SOURCE
on those, so override the default _FORTIFY_SOURCE setting.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoifplop.c32: Detect if PLoP USB/CD INT13h hook is enabled/disabled
Gert Hulselmans [Thu, 1 Jul 2010 15:57:44 +0000 (17:57 +0200)]
ifplop.c32: Detect if PLoP USB/CD INT13h hook is enabled/disabled

New module which detects if the PLoP Boot Loader already has booted a
CDROM or USB drive by checking for the presence of the PLoP INT13h hook.

The following assembly code (NASM) can detect the PLoP INT13h hook:

  mov eax,'PoLP'  ; Reverse of 'PLoP'
  mov ebp,'DKHC'  ; Reverse of 'CHKD'
  int 13h
  cmp eax,' sey'  ; Reverse of 'yes '
  jz plop_INT13h_active

Signed-off-by: Gert Hulselmans <gerth@zytor.com>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoMerge branch 'master' of ssh://terminus.zytor.com/pub/git/syslinux/syslinux
H. Peter Anvin [Thu, 1 Jul 2010 19:47:02 +0000 (12:47 -0700)]
Merge branch 'master' of ssh://terminus.zytor.com/pub/git/syslinux/syslinux

14 years agoNEWS: document changes to the CD-ROM initialization sequence syslinux-4.01-pre1
H. Peter Anvin [Thu, 1 Jul 2010 14:22:30 +0000 (07:22 -0700)]
NEWS: document changes to the CD-ROM initialization sequence

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore, diskio: skip EDD/CHS detect for CD-ROMs
H. Peter Anvin [Wed, 30 Jun 2010 21:02:56 +0000 (14:02 -0700)]
core, diskio: skip EDD/CHS detect for CD-ROMs

Skip EDD and CHS detection if we know it is a CD-ROM, because some
CD-ROMs possibly report bad information, and/or screw up the stack,
possibly permanently.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore, diskio: move dprintfs to the intended location
H. Peter Anvin [Thu, 1 Jul 2010 14:19:23 +0000 (07:19 -0700)]
core, diskio: move dprintfs to the intended location

Move the dprintfs to the location that they were intended to use.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agocore, diskio: put the error code in dprintf and printable messages
H. Peter Anvin [Wed, 30 Jun 2010 16:53:46 +0000 (09:53 -0700)]
core, diskio: put the error code in dprintf and printable messages

When we print an error message to the screen, include the error
number.  Furthermore, dprintf it on retries.

Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agomboot.h: use <dprintf.h>
H. Peter Anvin [Wed, 30 Jun 2010 00:45:23 +0000 (17:45 -0700)]
mboot.h: use <dprintf.h>

Use <dprintf.h> like more and more of the system does...

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: beginning of a 4.01 NEWS file
H. Peter Anvin [Wed, 30 Jun 2010 00:21:43 +0000 (17:21 -0700)]
NEWS: beginning of a 4.01 NEWS file

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agodiskstart: don't let the function number clobber the LBA
H. Peter Anvin [Wed, 30 Jun 2010 00:17:58 +0000 (17:17 -0700)]
diskstart: don't let the function number clobber the LBA

The LBA for getonesec and getlinsec is in EDX:EAX, but both DL and AX
are function inputs to INT 13h (drive number and function number).  We
need to preserve the LBA across *both* those, otherwise retries will
not function.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoisolinux: don't clobber DX (DL!) on startup
H. Peter Anvin [Tue, 29 Jun 2010 22:17:11 +0000 (15:17 -0700)]
isolinux: don't clobber DX (DL!) on startup

DL contains the initial drive number, don't clobber it!

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoisolinux: make sure Hidden is zero in native El Torito mode
H. Peter Anvin [Tue, 29 Jun 2010 20:27:03 +0000 (13:27 -0700)]
isolinux: make sure Hidden is zero in native El Torito mode

In native El Torito mode, there is no such thing as a partition
offset.  Make sure that we set Hidden to zero -- we don't use Hidden
(yet, although the ebios and cdrom code should be merged!) but we pass
it to the PM code, which will produce *really* wrong results...

Reported-by: Helmut Hullen <Hullen@t-online.de>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore, diskio: add a few dprintf()'s
H. Peter Anvin [Tue, 29 Jun 2010 17:36:28 +0000 (10:36 -0700)]
core, diskio: add a few dprintf()'s

Add a handful of dprintf's to make it easier to debug disk I/O
failures.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoversion: next version in 4.01
H. Peter Anvin [Mon, 28 Jun 2010 22:59:25 +0000 (15:59 -0700)]
version: next version in 4.01

4.00 is out, start work on 4.01...

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoMerge remote branch 'debian/daniel'
H. Peter Anvin [Mon, 28 Jun 2010 22:56:43 +0000 (15:56 -0700)]
Merge remote branch 'debian/daniel'

14 years agoMerge remote branch 'sha0/newness' syslinux-4.00
H. Peter Anvin [Mon, 28 Jun 2010 21:42:11 +0000 (14:42 -0700)]
Merge remote branch 'sha0/newness'

14 years agoNEWS: Document mdiskchk.com and eltorito.sys changes
Shao Miller [Mon, 28 Jun 2010 21:41:21 +0000 (14:41 -0700)]
NEWS: Document mdiskchk.com and eltorito.sys changes

14 years agoconfig.c32: accept an optional new directory
H. Peter Anvin [Mon, 28 Jun 2010 21:37:45 +0000 (14:37 -0700)]
config.c32: accept an optional new directory

Accept an optional new directory to config.c32, just as we permit for
the CONFIG statement.

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agodiskio: hard-code CD-ROM sectors to 2048 bytes
H. Peter Anvin [Mon, 28 Jun 2010 21:34:08 +0000 (14:34 -0700)]
diskio: hard-code CD-ROM sectors to 2048 bytes

At least the ThinkPad T22 and T23 will incorrectly report a sector
size of 512 bytes for El Torito CD-ROMs.  Ignore the reported sector
size for El Torito boots.

Reported-by: Helmut Hullen <hullen@t-online.de>
Tested-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: document MENU IMMEDIATE
H. Peter Anvin [Mon, 28 Jun 2010 20:51:15 +0000 (13:51 -0700)]
NEWS: document MENU IMMEDIATE

14 years agoNEWS: document isohybrid.c
H. Peter Anvin [Mon, 28 Jun 2010 20:48:21 +0000 (13:48 -0700)]
NEWS: document isohybrid.c

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: document ifcpu*.c32 fix
H. Peter Anvin [Mon, 28 Jun 2010 20:47:37 +0000 (13:47 -0700)]
NEWS: document ifcpu*.c32 fix

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agoNEWS: Fixing HDT, adding ifcpu changes
Erwan Velu [Mon, 28 Jun 2010 19:39:04 +0000 (21:39 +0200)]
NEWS: Fixing HDT, adding ifcpu changes

14 years agoNEWS: first cut of a NEWS file for 4.00
H. Peter Anvin [Mon, 28 Jun 2010 19:24:28 +0000 (12:24 -0700)]
NEWS: first cut of a NEWS file for 4.00

Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
14 years agocore, chdir: collapse slashes, avoid copy-to-self syslinux-4.00-pre64
H. Peter Anvin [Mon, 28 Jun 2010 01:46:36 +0000 (18:46 -0700)]
core, chdir: collapse slashes, avoid copy-to-self

Collapse multiple slashes into one (this still doesn't resolve . and
.. in the path, since that requires awareness of symlinks.)

This code also avoids a copy-over-self bug by introducing a temporary
buffer.

Reported-by: Gene Cumm <gene.cumm@gmail.com>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
14 years agoMerge remote branch 'sha0/gert_chain'
H. Peter Anvin [Mon, 28 Jun 2010 01:29:02 +0000 (18:29 -0700)]
Merge remote branch 'sha0/gert_chain'

14 years agochain.c32: pass partition number to stage2 of Grub Legacy
Gert Hulselmans [Mon, 28 Jun 2010 01:11:48 +0000 (03:11 +0200)]
chain.c32: pass partition number to stage2 of Grub Legacy

Grub Legacy stage2 will read the install_partition variable from
memory address 0x8208.
We only need to change the value at 0x820a to the correct partition
number:
  -1:   whole drive (default)
  0-3:  primary partitions
  4-*:  logical partitions

Signed-off-by: Gert Hulselmans <gerth@zytor.com>