SeaBIOS

SeaBIOS Git Change Log

Age Message
10 days 29 minutes add scripts/tarball.sh

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
14 days 9 hours pciinit: Fix build warning in mch_pci_slot_get_irq()

Some old versions of gcc warn that 'irq might be used uninitialized'.
Replace the switch statement with an if statement to suppress the
warning.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
14 days 9 hours Fix build issue on gcc34

Older versions of gcc may not inline on_extra_stack() and thus cause a
link error when compiling in 32bit segmented mode. Test for MODE16
explicitly in stack_hop_back() to prevent the problem.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
21 days 14 hours Minor - comment updates in romlayout.S

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
21 days 17 hours Use an aligned stack offset when entering on the extra stack

The size of 'struct bregs' is not evenly divisible by four and where
the assembler placed a 'struct bregs' on the extra stack as part of
entering into the C functions it caused the C functions to run with a
non-aligned stack. It's technically not correct to use an unaligned
stack and it is certainly less efficient.

This patch avoids using BREGS_size (the sizeof struct bregs) and
instead introduces PUSHBREGS_size (the size of the general purpose
registers in struct bregs) in the assembler. Where the code actually
did use the %cs:%ip and flags, an extra 8 (instead of 6) bytes are
added to maintain a sane alignment.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 9 days vgabios: Add software cursor capability

Add mechanism for drawing a cursor to the framebuffer to implement a
cursor in software. The timer interrupt is "hooked" so that the
cursor can blink. This can be useful for "coreboot native vga".

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
27 days 15 hours vgabios: Support emulating text mode attributes while in graphics mode

Add support for simple text mode attribute emulation while in graphics
mode. This improves text highlighting and background color on some
boot-loaders. Enable it only for CBVGA vgabios and only when a text
mode is requested.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
23 days 17 hours Minor - move PORT_PS2_CTRLB from hw/ps2port.h to hw/timer.c

The PORT_PS2_CTRLB port is only used by timers - it's just a
historical artifact that it was part of the original ps2 controller.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
20 days 18 hours megasas: read addional PCI I/O bar

Some newer cards have the I/O bar at BAR 0, so we need to check
that, too, if we cannot get an address for BAR 2.
Without this patch the new 'megasas-gen2' emulation in qemu
is not detected.

Signed-off-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Commit 09f876f11743c1143c73a52eb889ae9231f7a5b3, by Hannes Reinecke
23 days 17 hours Fix PNP regression introduced in 99cb8f3e due to missed conversion

Commit 99cb8f3e missed a conversion from 12(%esp) to BREGS_eax(%esp)
causing winxp to break.

Reported-by: Ian Campbell <Ian.Campbell@citrix.com>
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 10 days vgabios: Add support for reading framebuffer in "direct" mode

Support reading high memory "direct" framebuffers and translating the
results to 8 bit attribute values.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 3 days vgabios: Fill in available legacy modes in video_func_static at runtime

Instead of hard coding the list of modes, fill them in from the list
of supported modes.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 3 days vgabios: Move standard table definitions to std/vga.h

Move the standard video bios definitions into a new header file.
Also, define a struct with the layout for the static functionality
table.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 3 days vgabios: Only set the dcc_index=8 if stdvga ports are available

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 3 days vgabios: Only init BDA device details in init_bios_area()

Don't set the device details when changing modes, and don't set mode
details outside of mode setting.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 4 days vgabios: Refactor get/set_cursor_shape() code

Rework the code so that it is possible to calculate the current cursor
shape even when not changing it.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 4 days vgabios: Set cursor shape fixes

The "cursor scaling" mode is determined by the first bit of the
video_ctl bda value, not the modeset_ctl value. Also, on a
set_scan_lines() call, the shape should be set to lines-3/lines-2 and
the shape must be set after char_height has been updated.

The existing cursor shape code matches the legacy "lgpl vgabios", but
the behavior doesn't match bios documentation nor observations with an
ati vga bios.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 5 days vgabios: Rename vbe_flags to flags

Allow the custom bda field vbe_flags to be used for flags outside of
vbe.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 9 days vgabios: Don't pass vmode_g to vgafb_move_chars() / vgafb_clear_chars()

Now that a pointer to the current video mode info struct is cached in
memory, it's not necessary to pass the struct into the vgafb code.
The vgafb code can lookup the struct itself.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 9 days vgabios: Cache a pointer to the current mode struct in the BDA

Cache a pointer to the current mode 'vgamode_s' struct in the BDA to
avoid doing a linear scan of all available vga modes when the struct
is needed.

This uses an additional two bytes in the BDA (at offset 0xbc). It's
possible this could conflict with some other software, but that seams
unlikely because that part of the BDA seems reserved for BIOS and
VGABIOS uses. (And neither SeaBIOS nor Bochs BIOS currently make use
of that area.)

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 9 days vgabios: Don't declare custom internal BDA storage in std/bda.h

The vgabios uses storage in the BDA at offset 0xb9 for internal custom
storage (the contents do not appear to be part of any bios standard).
Move the description of this custom vgabios area from std/bda.h to
vgasrc/vgabios.h. Add two new macros (GET_BDA_EXT and SET_BDA_EXT).
This should make it more clear that the area is for custom internal
storage.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 5 days Remove unused macro ENTRY_ST

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 5 days Do full BREGS backup/restore for pmm, pnp, and irqentry_extrastack

Although these entry points only require backup and restore of the
registers that the C code clobbers, there is no harm in backing up
some additional registers. This allows the BREGS macros to be used
which makes the code a little more readable.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 6 days Create assembler macros for saving and restoring 'struct bregs'

Create macros SAVEBREGS_POP_DSEAX and RESTOREBREGS_DSEAX for saving
and restoring the cpu state. These are similar to the existing
PUSHBREGS and POPBREGS macros.

This also fixes a bug in __farcall16 which inadvertently restored %ds
in %es and vice-versa.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
1 month 5 days Don't clobber %ax on ENTRY_INTO32 macro

There's no need to clobber %ax in ENTRY_INTO32. Now that %eax isn't
clobbered, use ENTRY_INTO32 in entry_csm.

Signed-off-by: Kevin O'Connor <kevin@koconnor.net>