Michael Brown
2cfe0dee1f
Don't trash the %ecx value returned by relocate(). This was causing
us to round down the size for the relocation copy to the nearest 64kB
(+0x10 bytes); this just happened to work on most machines because the
last 64kB of the image is all-zeroes anyway (it's the .bss).
17 jaren geleden
Michael Brown
c94cdf2b7d
Move .zinfo to libprefix.S; it doesn't belong with the decompression code.
17 jaren geleden
Michael Brown
048bbeeebc
Compressed ROM images now work.
17 jaren geleden
Michael Brown
ab859a5355
Use a single _payload_offset linker-defined variable to locate the
start of the non-prefix blocks in the loaded image, and rely on the
image ordering. This should make introducing compression much easier.
17 jaren geleden
Michael Brown
dca369ddc3
Call hide_etherboot() from startup(), rather than requiring the prefix to
do it.
18 jaren geleden
Michael Brown
86171c53f4
Damn Broadcom and their damned incorrect assumptions about x86 memory
allocation.
18 jaren geleden
Michael Brown
6abfaa153b
Towards making KEEP_IT_REAL work again.
Fix bug that caused over-allocation of .text16 and .data16 memory areas
by a factor of 16.
18 jaren geleden
Michael Brown
e7eca7b7cb
Code segment may not be writable; create the temporary pointer to the GDT
on the stack.
18 jaren geleden
Michael Brown
041a04335e
Fixed assembly on old versions of gas
18 jaren geleden
Michael Brown
89da833c5d
init_librm() and prot_call() are now real-mode far calls.
install() now calls relocate(), moves the protected-mode code to the new
location, and calls hide_etherboot().
18 jaren geleden
Michael Brown
832807726a
Add infrastructure to support access to .data16 (and .text16) variables
from protected-mode code.
Set up %ds to point to .data16 in prot_to_real, so that code specified
via REAL_EXEC() and friends can access variables in .data16.
Move most real-mode librm variables from .text16 to .data16.
18 jaren geleden
Michael Brown
cc23057b59
Typo
18 jaren geleden
Michael Brown
10c28a51bd
Create two easy-to-use entry points in libprefix: install and
install_prealloc. I *think* these will suffice for all the 16-bit
prefixes.
18 jaren geleden
Michael Brown
5463169c1a
Verified as working
18 jaren geleden
Michael Brown
d081d65d48
This should be much more elegant: we use flat real mode for the
highmem data, so decompress16 will be able to unpack blocks bigger
than 64kB.
18 jaren geleden
Michael Brown
cc8821a443
Checking in because I don't want to lose this rather neat code for
running the decompresser in 16:16 protected mode using the real-mode
stack. However, there's an even simpler way to do it...
18 jaren geleden