| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The description field is only available during the POST phase - it is
confusing to have it live in a structure available through all phases.
The description was only used by the boot menu code - pass each drive
description directly to the bootlist code.
Add a helper (znprintf) to automatically malloc_tmp the required
space.
Also, fixup ramdisk handling - it was using an incorrect floppy
priority.
|
|
|
|
|
|
|
|
| |
Fix bvprintf to respect space padding when printing hex numbers
and the caller specifies alignment without zero padding, eg. %2x
as opposed to %02x
Signed-off-by: Jes Sorensen <Jes.Sorensen@redhat.com>
|
| |
|
|
|
|
|
| |
There is no need for custom warnings for many common failures.
Introduce a common warning which is consistent and more visible.
|
|
|
|
| |
Omitting "void" leads to a K&R style declaration which was not intended.
|
|
|
|
|
|
|
|
|
| |
Create a new code blob (code32seg) with support for 32bit functions
that need to utilize explicit segment accesses.
This code blob uses global variables relative to %gs and with a
dynamic code offset (determined by get_global_offset()).
Add BIOS32 structure and code.
Add code for 32bit PCI BIOS code.
|
|
|
|
|
| |
Prepare for support of segmented 32bit code.
Add new MODESEGMENT definition, and clarify existing 32bit mode defs.
|
|
|
|
|
|
|
|
| |
Don't use "fail" in the debug output - as this confuses users.
When reporting on an invalid parameter - use the word "invalid".
When reporting on an unimplemented call - state it is unimplemented.
Add separate debug levels for unimplemented vs invalid calls.
Also, increase the debug level of several entry points.
|
| |
|
|
|
|
|
| |
Show the "thread id" on each debug message sent from a thread.
Also, cleanup translation dprintf() so it looks nicer withe thread output.
|
| |
|
|
|
|
|
|
| |
The 16bit and 32bit code can't share debuginfo because it points to
code and must point to 16bit code in 16bit mode. Introduce two
separate variables - one for 32bit mode and one for 16bit mode.
|
| |
|
|
|
|
|
|
| |
Extend bvprintf() code to support building a string.
Don't flush the serial port from printf if CONFIG_SCREEN_AND_DEBUG not
set.
|
|
|
|
| |
gcc prefers asm parameters not be casts.
|
|
|
|
|
|
|
| |
This adds preliminary support for USB controllers and keyboards.
Add support for UHCI controllers.
Add support for "HID" USB keyboards.
Also, fix bug in hexdump() - len need not be power of 4.
|
|
|
|
|
| |
Set most code paths to have interrupts on when calling 16bit code.
This fixes at least one optionrom that needed irqs on.
|
|
|
|
| |
Introduce 'struct segoff_s' to more places.
|
|
|
|
|
| |
New option controls whether or not printf content is also written to
the debug ports.
|
|
|
|
|
| |
The address of the callers stack can be inferred from the address of
'regs' - do the math in the dump function.
|
|
|
|
|
|
| |
Save/restore %ebp on irq entry.
Support saving and restoring %ebp on call16.
Enable display of %ebp in register dumps.
|
|
|
|
|
| |
Wait for the serial port to be ready after every debug function.
This fixes an issue with serial port detection.
|
|
|
|
|
| |
Add port names for serial port registers.
When detecting serial port, ignore top two bits of IIR register.
|
|
|
|
| |
Patch from Stefan Reinauer; modified by Kevin O'Connor.
|
| |
|
| |
|
|
|
|
|
|
|
|
| |
Change license of contributions from Kevin O'Connor from GPLv3 to
LGPLv3 (or later). Since the work as a whole is based on Kevin's
contributions and the "bochs bios" which has a license of LGPL (v2 or
later), this effectively makes the work as a whole available under
LGPLv3 (or later).
|
|
|
|
|
|
|
| |
Encode lineno and return code into one u32 parameter. This reduces
the number of functions arguments to 3 - which gcc does a better
job of scheduling.
Also, consistently place *regs parameter in the first arg.
|
| |
|
| |
|
|
|
|
|
| |
When CONFIG_DEBUG_LEVEL the debug message wont be shown, so don't
bother calling bvprintf.
|
|
|
|
|
|
|
|
| |
Minor code cleanups.
Fix parenthesis imbalance in keyboard led test.
The printf() call is only used in 32bit mode - make this explicit to
the compiler - it improves the code generation.
Clear the screen after initializing the vga option rom.
|
|
|
|
|
|
|
| |
Return the line number of the debug_fail() / debug_stub() call site on
each call.
Show the return status on set_code_fail() calls.
Also, the floppy_1305() code should not clear AL.
|
| |
|
| |
|
|
|
|
|
|
| |
Apparently, some VGA option roms will enable serial irqs - this could
cause problems with spurious irqs from debug messages.
Also, improve debugging of option roms that fail the checksum check.
|
|
|
|
|
|
|
|
|
|
| |
Regular serial writing code uses the system timer to timeout failed
writes - however, serial debugging can't rely on access to the BDA
segment or the hardware timer.
Therefore, implement a simple debug only serial writing function and
separate it from the regular serial output code.
Also include change to dump_regs - don't call __dprintf if debugging
not on.
|
|
|
|
|
|
| |
Rename BX_INFO() to dprintf() and add a "severity level" parameter.
Add CONFIG_DEBUG_LEVEL compile option to control debug verbosity.
Add more debug info to init steps of post.c.
|
|
|
|
| |
Enable by turning on CONFIG_DEBUG_SERIAL option.
|
|
|
|
|
| |
Several minor comment improvements.
Rearrange some definitions to make them more clear.
|
|
|
|
|
|
|
| |
Support boot menu during last stage of post.
Improve description of option roms.
Support printf of "%.s" to force printing strings on stack.
Enhance memcpy so that it also works in real-mode.
|
| |
|
|
|
|
| |
Don't cast to a u8 - instead, cast the pointer to a u8*.
|
|
|
|
|
|
| |
Support '%p' format in bprintf.
Display pointer of register in debug output (useful for calculating
start stack).
|
|
|
|
|
| |
Remove some redundant code from Makefile.
Improve a couple of comments.
|
|
|
|
|
| |
The C code won't clobber these registers, so backing them up isn't needed.
Removing them saves a few bytes on the stack.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Don't back up all registers on isr handlers - they don't read/modify
them. This saves stack space.
extended_bios_data_area_s must be packed to match ebda spec.
Enable irqs on int 08 - follows old bochs bios code.
Fix bug in int 76 -- should clear disk_interrupt_flag not
floppy_harddisk_info.
Make sure we alert in disk_ret on failure case.
int 18/19 entry points need to setup cld/%ds too.
asm in handle_1587 clobbers flags - note that in clobber list.
|
|
|
|
|
|
| |
Calling debug_exit at the end of a call doesn't help much - several of
the registers are already clobbered at this point. It also increases
stack usage because it prevents call tail optimization in many places.
|
| |
|
|
|
|
| |
This at least allows the variable to be printed.
|