Pierre-Alexandre Meyer [Sun, 26 Apr 2009 21:14:49 +0000 (14:14 -0700)]
hdt: Make the disk mode use parse_partition_table() (CLI)
Impact: code refactoring
Leverage the new call parse_partition_table() in the disk CLI.
Misc.: enhance UI output, add space in the columns for up to 46 TB disks.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 26 Apr 2009 21:09:18 +0000 (14:09 -0700)]
gpllib: Add parse_partition_table() to iterate through all partitions on a disk
Impact: expand gpllib disk API
parse_partition_table() can be used to execute a callback on each partition.
The signature of the callback is:
void callback(struct driveinfo *drive_info,
struct part_entry *ptab,
struct part_entry *ptab_root,
int offset_root,
int local_partition_number,
int ebr_seen)
* drive_info represents the disk.
* ptab is the current partition entry processed.
* ptab_root is the partition entry linking to the current one processed (extended only).
* offset_root is the offset of the ebr when iterating through extended partitions
(0 otherwise).
* local_partition_number is the number of the partition processed (0->3).
* ebr_seen counts the total number of ebr processed.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 26 Apr 2009 00:52:02 +0000 (17:52 -0700)]
hdt: Improve disk output (CLI)
Do not print EDD C/H/S info, since it is not really useful.
Add disk size to the summary.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 19:05:46 +0000 (12:05 -0700)]
hdt: Do not print information about buggy extended partitions
Impact: bug fix
Add a sanity check before printing extended partitions.
As hpa notes in chain.c:
Sanity check entry: must not extend outside the extended partition.
This is necessary since some OSes put crap in some entries.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 19:04:03 +0000 (12:04 -0700)]
hdt: Do not modify offsets in the part_entry itself
Impact: fix bug
When printing extended partitions information, we need to adjust
the start lba. Do not modify it in the part_entry struct but just
print the adjusted one.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 19:02:23 +0000 (12:02 -0700)]
gpllib: Handle unknown labels (disk)
Return "Unknown" for unknown labels.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 19:01:15 +0000 (12:01 -0700)]
gpllib: Add default error handling (disk)
In case of an unknown error, display a default message.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 17:05:05 +0000 (10:05 -0700)]
hdt: Add missing header in hdt-util.c
Impact: fix build
Add missing #include <string.h> in hdt-util.c.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 17:02:51 +0000 (10:02 -0700)]
hdt: Check if a swsusp image exists on swap partitions
Impact: new feature, add error debug information
When printing partitions information, add a message in the CLI if a swap device
contains a valid swsusp (hibernate) image.
Misc.: check and print, if needed, errors after each I/O operation.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 17:01:38 +0000 (10:01 -0700)]
gpllib: Build new objects (disk)
Add error.o and swsusp.o as part of the gpllib build.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 16:58:35 +0000 (09:58 -0700)]
gpllib: Add swsusp_check to check for swsusp signature
swsusp is a Linux mechanism to put a computer to sleep. In case of hibernation,
an image is written to the disk, on a swap partition.
swsusp_check can be used to check if a device contains the magic swsusp signature,
meaning that an image is present.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 16:56:11 +0000 (09:56 -0700)]
gpllib: Propagate error codes in disk library
It is worth propagating read/write error codes back to the caller. He can
pass NULL to ignore them, or an int* that will be populated.
To decode it, one can use the get_error function (see disk/error.c).
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 16:53:16 +0000 (09:53 -0700)]
gpllib: Move partition declarations to disk/partition.h
Add a new file for partition related structures.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 16:51:28 +0000 (09:51 -0700)]
gpllib: Move get_error from disk/util.c to disk/error.c
The get_error function is fairly big. It is worth creating
a new file for it.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 16:48:09 +0000 (09:48 -0700)]
gpllib: Add disk/common.h for shared definitions
A couple of structures/definitions are shared between several files
in the disk library. Add them in disk/common.h
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 02:46:45 +0000 (19:46 -0700)]
hdt: Add IEC 60027 format for disk size (menu)
Impact: move the decimal format code to hdt-util.c
Display size in MiB/GiB/TiB as well in the disk menu.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 02:31:13 +0000 (19:31 -0700)]
hdt: Use IEC 60027 standard for capacity (CLI)
Impact: add hdt-util.c for generic helpers
Display size of partitions in kibi, mebi, gibi ot tebibytes.
There is no point in displaying the number of sectors in the CLI, a
human readable size is more useful.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Tue, 21 Apr 2009 00:19:26 +0000 (17:19 -0700)]
hdt: Process extended partitions (CLI)
Print information about extended partitions in the CLI.
Note: the offsets reported are the offsets found in the EBR. We may want to
adjust it with the offset in the MBR.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 22:26:12 +0000 (15:26 -0700)]
hdt: Add partitions information in disk menu
Show information about valid partitions found (start, end, length, type, ...).
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 04:13:47 +0000 (21:13 -0700)]
hdt: Dump partition tables (CLI)
Use the new disk API to read mbrs and dump information about detected
primary partitions.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 04:09:21 +0000 (21:09 -0700)]
gpllib: Add partition table structure (disk)
Impact: disk API extension
Add part_entry structure to describe DOS partition tables.
The new get_label call translates a label id to a meaningful string
describing the partition.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 04:06:39 +0000 (21:06 -0700)]
gpllib: Add read_mbr helper (disk)
Impact: disk API extension
read_mbr takes a drive number and returns a pointer to a malloced buffer
containing its mbr.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 01:26:39 +0000 (18:26 -0700)]
disk.c32: Fix indentation
Impact: none
Fix indentation for the loop ending curly brace.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 01:25:44 +0000 (18:25 -0700)]
hdt: Adapt disk CLI/menu to new struct devinfo
The struct devinfo has slightly changed. Reflect the changes in hdt.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Mon, 20 Apr 2009 00:11:59 +0000 (17:11 -0700)]
gpllib: Don't clobber legacy C/H/S parameters with EDD ones
Impact: driveinfo structure change, new disk.c32 module
Adapt driveinfo structure to store both legacy and EDD parameters. Change utility
functions to use EDD when available (C/H/S being a fallback).
Add a new disk.c32 module to test the disk library. It will print information
(geometry) about every detected drive.
Misc.: refactoring, set ES:DI to 0:0 when querying legacy C/H/S
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 19:27:51 +0000 (12:27 -0700)]
hdt: Fix typo in device_parameter struct
cheksum should read checksum.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 19:25:09 +0000 (12:25 -0700)]
hdt: Remove misguiding printf() (disks)
When detecting disks, we iterate through all ports. The number of disks
scanned will always be 127, no matter how many are actually plugged in.
Remove extra printf() when scanning.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 19:19:53 +0000 (12:19 -0700)]
hdt: Fix EDD format (menu)
The EDD version is more meaningful if displayed using an hexadecimal
format:
01h = 1.x
20h = 2.0 / EDD-1.0
21h = 2.1 / EDD-1.1
30h = EDD-3.0
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 19:16:38 +0000 (12:16 -0700)]
hdt: Remove inappropriate free()
Impact: fix crash
This extra free() is not needed, as the error buffer is already freed in the
loop.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 15:39:08 +0000 (08:39 -0700)]
hdt: Add `show disk' in hdt mode (CLI)
It is now possible to see disks from hdt mode, via the `show disk'
command.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 15:31:57 +0000 (08:31 -0700)]
Merge commit 'mouraf/for-erwan' into disklib
Conflicts:
com32/hdt/hdt-cli.c
com32/hdt/hdt-cli.h
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 15:26:34 +0000 (08:26 -0700)]
hdt: Refactor disk menu
Make the disk menu use the new disk library.
Misc.: remove firmware, serial number and model information as they aren't
detected yet.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 15:20:09 +0000 (08:20 -0700)]
hdt: Add disk mode (CLI)
The disk mode features drives autodetection (geometry). Generic geometry
code from hdt-ata.c has been replaced by the new disk gpllib.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sun, 19 Apr 2009 15:13:00 +0000 (08:13 -0700)]
gpllib: Add disk library
This library features read and write operations, as well as geometry detection.
It will prevent duplicating code between several modules (e.g. hdt and chain.c32).
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Sat, 18 Apr 2009 18:39:09 +0000 (11:39 -0700)]
Merge commit 'origin/for-erwan' into disklib
Pierre-Alexandre Meyer [Sat, 18 Apr 2009 03:08:06 +0000 (20:08 -0700)]
hdt: Add VPD menu item
Add an item to display VPD information, if detected.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Fri, 17 Apr 2009 23:29:49 +0000 (16:29 -0700)]
hdt: Add vpd mode (CLI)
Add the vpd mode to dump the vpd structure, if found.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Fri, 17 Apr 2009 21:55:12 +0000 (14:55 -0700)]
Merge commit 'erwan/master' into for-erwan
Conflicts:
com32/hdt/hdt-cli-hdt.c
com32/hdt/hdt-cli.c
Pierre-Alexandre Meyer [Fri, 17 Apr 2009 21:35:52 +0000 (14:35 -0700)]
hdt: Get rid of nb_modules in struct cli_module_descr
End list of modules commands by NULL instead of managing manually
the number in nb_modules. This should limit the number of bugs when adding new
features.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Pierre-Alexandre Meyer [Thu, 16 Apr 2009 22:27:39 +0000 (15:27 -0700)]
hdt: Get rid of MAX_MODES
End the list of modes by NULL instead of managing manually the length.
Signed-off-by: Pierre-Alexandre Meyer <pierre@mouraf.org>
Erwan Velu [Thu, 16 Apr 2009 20:54:03 +0000 (22:54 +0200)]
hdt: removing useless clear_screen
Impact: Improve user experience
Prevent clear screen when not necessary
Erwan Velu [Thu, 16 Apr 2009 20:48:14 +0000 (22:48 +0200)]
hdt: Improving more_printf & clear_screen management
Impact: greatly improve user experience
This commit adds more coherency in more_printf & clear_screen usage
Erwan Velu [Thu, 16 Apr 2009 20:33:47 +0000 (22:33 +0200)]
hdt: Fixing wrong printf calls
Impact: Removing memory corruption
Some printf called were badly setup
Erwan Velu [Thu, 16 Apr 2009 19:38:45 +0000 (21:38 +0200)]
hdt: Adding reset_more_printf()
Impact: first step toward more_printf() rationalization
reset_more_printf() reset the counter used by more_printf to count
lines.
Erwan Velu [Thu, 16 Apr 2009 19:34:00 +0000 (21:34 +0200)]
hdt: menu should be 80x25
Impact: increasing menu size to improve display
80x24 was a mistake, it have to be 80x25
Erwan Velu [Thu, 16 Apr 2009 19:32:22 +0000 (21:32 +0200)]
Merge branch 'master' of git://git./boot/syslinux/syslinux into erwan
H. Peter Anvin [Thu, 16 Apr 2009 18:04:52 +0000 (11:04 -0700)]
Merge branch 'syslinux-3.7x'
H. Peter Anvin [Thu, 16 Apr 2009 04:42:14 +0000 (21:42 -0700)]
rosh: don't compile rosh.lnx by default
Don't compile rosh.lnx by default. It causes unnecessary dependencies
on the host system.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Wed, 15 Apr 2009 23:26:49 +0000 (16:26 -0700)]
NEWS: document HDT PCI fix
Erwan Velu [Tue, 14 Apr 2009 19:55:14 +0000 (21:55 +0200)]
hdt: Fixing latency indentation
Impact: Improving display
Removing useless space
Erwan Velu [Wed, 15 Apr 2009 19:05:19 +0000 (21:05 +0200)]
pci: Using for_each_pci_func3
Impact: cleaning code
Using for_each_pci_func3 instead of for_each_pci_func + pci_mkaddr
H. Peter Anvin [Tue, 14 Apr 2009 20:45:33 +0000 (13:45 -0700)]
pci: add pci_for_each_func3() which produces an address
Add pci_for_each_func3() iterator, which produces an address in
addition to the device pointer.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Erwan Velu [Tue, 14 Apr 2009 19:41:05 +0000 (21:41 +0200)]
PCI: Fixing freeze when detecting many PCI devices
Impact: Prevent hard freeze when having many PCI devices
A user reported that calling gather_additional_pci_config() when many
PCI devices exists on a host could lead to a complete freeze.
This patch remove some useless code and use for_each_pci_func() instead.
This prevent useless memory allocation.
Erwan Velu [Wed, 15 Apr 2009 19:05:19 +0000 (21:05 +0200)]
pci: Using for_each_pci_func3
Impact: cleaning code
Using for_each_pci_func3 instead of for_each_pci_func + pci_mkaddr
Erwan Velu [Wed, 15 Apr 2009 18:26:22 +0000 (20:26 +0200)]
Merge branch 'master' of git://git./boot/syslinux/syslinux
H. Peter Anvin [Wed, 15 Apr 2009 04:55:08 +0000 (21:55 -0700)]
NEWS: add the latest stuff...
Document additional changes since 3.74.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Wed, 15 Apr 2009 04:52:50 +0000 (21:52 -0700)]
gpxe: Don't use "lret $2" to return from an interrupt
Using "lret $2" to return from an interrupt causes interrupts to be
disabled in the calling program, since the INT instruction will have
disabled interrupts. Instead, patch CF on the stack and use iret to
return.
Interestingly, the original PC BIOS had this bug in at least one
place.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Wed, 15 Apr 2009 04:45:54 +0000 (21:45 -0700)]
menu: modify MENU SAVE to be a cascading default
Change MENU SAVE to be a cascading default that can be reverted with
MENU NOSAVE.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 22:36:05 +0000 (15:36 -0700)]
doc: fix stray parenthesis in syslinux.txt
Remove stay parenthesis in syslinux.txt
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 20:45:33 +0000 (13:45 -0700)]
pci: add pci_for_each_func3() which produces an address
Add pci_for_each_func3() iterator, which produces an address in
addition to the device pointer.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Erwan Velu [Tue, 14 Apr 2009 19:55:14 +0000 (21:55 +0200)]
hdt: Fixing latency indentation
Impact: Improving display
Removing useless space
Erwan Velu [Tue, 14 Apr 2009 19:41:05 +0000 (21:41 +0200)]
PCI: Fixing freeze when detecting many PCI devices
Impact: Prevent hard freeze when having many PCI devices
A user reported that calling gather_additional_pci_config() when many
PCI devices exists on a host could lead to a complete freeze.
This patch remove some useless code and use for_each_pci_func() instead.
This prevent useless memory allocation.
H. Peter Anvin [Tue, 14 Apr 2009 19:37:42 +0000 (12:37 -0700)]
doc: clarify CS.base restriction for KVM
Clarify that the CS.base restriction is a prescription of
compatibility, and not something that the ABI handles transparently.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 19:36:21 +0000 (12:36 -0700)]
doc: update copyright in syslinux.txt
Update and clarify copyright in syslinux.txt.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 19:14:04 +0000 (12:14 -0700)]
Merge branch 'syslinux-3.7x'
H. Peter Anvin [Tue, 14 Apr 2009 19:08:08 +0000 (12:08 -0700)]
NEWS: the extlinux(1) is from Brian Pellin, not Daniel Baumann.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 19:04:54 +0000 (12:04 -0700)]
NEWS: document MEMDISK fixes, updates.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Daniel Baumann [Tue, 14 Apr 2009 18:30:55 +0000 (20:30 +0200)]
Adding manpage from Brian Pellin <bpellin@gmail.com> for extlinux.
Daniel Baumann [Tue, 14 Apr 2009 18:29:43 +0000 (20:29 +0200)]
Correcting typo in extlinux documentation.
H. Peter Anvin [Tue, 14 Apr 2009 19:02:11 +0000 (12:02 -0700)]
MEMDISK: traceability for the geometry
Print the source of the geometry determination.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 19:01:07 +0000 (12:01 -0700)]
MEMDISK: fix MBR geometry extraction
Fix the MBR geometry extraction; there was an off-by-2 error in the
MBR signature offset.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 18:27:25 +0000 (11:27 -0700)]
Merge branch 'syslinux-3.7x'
Conflicts:
core/bootsect.inc
version
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 18:22:07 +0000 (11:22 -0700)]
NEWS, version: bump version to 3.75, document keeppxe fix
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 18:20:03 +0000 (11:20 -0700)]
pxelinux: fix the handling of KeepPXE
KeepPXE was broken in 3.74, because we tried to use both bits 0 and 1,
but failed to actually test both bits. Instead, just use bit 0, but
move the place where we clear the bits.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Tue, 14 Apr 2009 05:34:55 +0000 (22:34 -0700)]
core/bcopyxx.inc: save a few bytes
Muck with the GDT patching logic to save a few bytes.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 05:13:22 +0000 (22:13 -0700)]
Fix infinite loop in syslinux_memmap_find()
We can't use continue; since we're not using a for loop; we have to
advance to the next list entry...
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 03:31:40 +0000 (20:31 -0700)]
Merge branch 'timeout-fix'
H. Peter Anvin [Tue, 14 Apr 2009 03:30:26 +0000 (20:30 -0700)]
pxelinux: fix the new timeout code
Fix the new timeout code; in particular:
- on receiving an ERROR packet, we fake an immediate timeout;
this has to be done differently now.
- fix missing decrement of timeout counter.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 03:06:00 +0000 (20:06 -0700)]
com32: use xfer_buf_seg as the bounce buffer
We cannot realistically realign comboot_seg without breaking com16
modules (which have the DOS-derived assumption that they own the rest
of low memory.) However, we can use xfer_buf_seg as the com32 bounce
buffer, which allows us to retain the benefit of a 64K-aligned buffer.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 02:43:35 +0000 (19:43 -0700)]
doc: add note about KVM restriction on CS.base
Add note about KVM restrictions on CS.base before entering real mode.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 02:32:00 +0000 (19:32 -0700)]
core: don't misalign xfer_buf_seg
xfer_buf_seg is used for bulk transfers, and we really don't want
to break it up in order to avoid 64K DMA boundaries.
Note: the same is true for the com32 bounce buffer, which is
real_mode_seg. However, there are hard assumptions in the code that
real_mode_seg is the last segment; those need to be cleaned up, or we
need to verify that xfer_buf_seg can be used as the com32 bounce
buffer.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 02:28:20 +0000 (19:28 -0700)]
Something slightly saner for DummyTSS
DummyTSS should hopefully never be actually used.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 02:25:50 +0000 (19:25 -0700)]
GDT: remove unused DS16_4G and SS16 descriptors
We no longer use the DS16_4G and SS16 descriptors; we now use 32-bit
protected mode for all "big" work.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 02:19:34 +0000 (19:19 -0700)]
shuffle_rm.c: minor style cleanup
Try to make the code just a little easier to read.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Tue, 14 Apr 2009 02:11:30 +0000 (19:11 -0700)]
shuffler: work around KVM problem with the new shuffler
KVM uses V86 mode to simulate real mode. This causes problems with
the new shuffler. This changes the shuffler handover to be in
16-bit protected mode instead, and requires the stub to do the actual
entry to real mode. For the KVM hack to work, all segments must have:
(seg.base & 0xfff0000f) == 0 && seg.limit == 0xffff
As a result, we have to make sure the real-mode entry stub is
paragraph-aligned, lest we violate the first criterion.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Mon, 13 Apr 2009 22:39:04 +0000 (15:39 -0700)]
core: move vgafontbuf out of the zero segment
vgafontbuf is one of the largest (bss) structures in the zero segment,
together with the trackbuf (which we realistically can't move.)
Create a new "auxilliary segment" for fixed-sized data which needs to
be in the low megabyte, but not necessarily in the zero segment.
This pushes up the low memory usage, but only by 8K.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Mon, 13 Apr 2009 22:09:41 +0000 (15:09 -0700)]
core: add alignz macro (analogous to "alignb") for zero-pad align
Add a new macro "alignz" to align with zero bytes; use to align inside
a data section (i.e. a progbits section which doesn't contain code.)
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Mon, 13 Apr 2009 22:04:20 +0000 (15:04 -0700)]
core/macros.inc: iterative definition of asciidec
A cleaner iterative defintion of the asciidec macro.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Mon, 13 Apr 2009 21:13:52 +0000 (14:13 -0700)]
bootrm: allow entering with IF=1; smarter stub location
Change the stub location algorithm to prefer low memory above
0x800; above 0x510 if that is unavailable. Also add the ability
to invoke the real-mode code with IF=1 if so is desired.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
H. Peter Anvin [Mon, 13 Apr 2009 20:54:33 +0000 (13:54 -0700)]
pxelinux: use a table-driven backoff
Use a table-driven backoff so we can provide a backoff which doesn't
increase as sharply (by integral powers of two) as before. Rather
than worrying about doing fractional multiplication, simply provide a
backoff table.
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Erwan Velu [Mon, 13 Apr 2009 20:19:50 +0000 (22:19 +0200)]
hdt: Shortening extension when using ISOLINUX
Impact: When using ISOLINUX, we have to shorten the extension
Shortening extension when using ISOLINUX.
i.e: modules.pcimap is convertd to modules.pci
Erwan Velu [Mon, 13 Apr 2009 20:16:54 +0000 (22:16 +0200)]
hdt: Opening console earlier
Impact: Earlier printf are now possible
Prior to that commit, it was impossible to printf during paramaters
& syslinux checks
Erwan Velu [Mon, 13 Apr 2009 19:49:00 +0000 (21:49 +0200)]
hdt: Detect syslinux earlier
Impact: Internal changes
Some parameters might be dependant on syslinux's version
Erwan Velu [Mon, 13 Apr 2009 19:28:19 +0000 (21:28 +0200)]
hdt: 0.3.0
Impact: This commit ends the merge with pam's branch
CLI is improved and manage completion
Thx to pierre for that great work
Erwan Velu [Mon, 13 Apr 2009 18:54:22 +0000 (20:54 +0200)]
Merge branch 'for-erwan' of ssh://erwan@terminus.zytor.com/pub/git/users/pam/hdt-pierre into pam
Conflicts:
com32/hdt/hdt-cli.c
H. Peter Anvin [Mon, 13 Apr 2009 17:37:37 +0000 (10:37 -0700)]
pxelinux: be more aggressive about retransmitting ACKs
Some PXE stacks drop packets on transmit on a regular basis. Avoid
severe slowdowns by being much more aggressive about ACK
retransmissions.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
H. Peter Anvin [Mon, 13 Apr 2009 17:36:36 +0000 (10:36 -0700)]
Makefile: add missing MBR variants to BOBJECTS
Add missing variants to BOBJECTS.
H. Peter Anvin [Sun, 12 Apr 2009 23:36:35 +0000 (16:36 -0700)]
pxelinux: be more paranoid about saving/restoring flags
Save and restore flags around writechr and the PXE stack call, just in
case the underlying stack does something weird.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Pierre-Alexandre Meyer [Sat, 11 Apr 2009 17:50:30 +0000 (10:50 -0700)]
hdt: DEL must be handle as BACKSPACE
Impact: Better conformity to standards
To conform with serial lines, DEL must be handled as BACKSPACE
Using Ctrl+D to delete a char
Taken from http://www.gnu.org/software/bash/manual/html_node/Commands-For-Text.html
(cherry picked from commit
5be7f0228dea745aa8e1fe18036517675bbe8c1e)
Pierre-Alexandre Meyer [Sat, 11 Apr 2009 17:46:38 +0000 (10:46 -0700)]
Merge branch 'master' into for-erwan
Conflicts:
com32/hdt/Makefile