[romprefix] Inhibit the use of relocation during POST

It is common for system memory maps to be grotesquely unreliable
during POST.  Many sanity checks have been added to the memory map
reading code, but these do not catch all problems.

Skip relocation entirely if called during POST.  This should avoid the
problems typically encountered, at the cost of slightly disrupting the
memory map of an operating system booted via iPXE when iPXE was
entered during POST.  Since this is a very rare special case (used,
for example, when reflashing an experimental ROM that would otherwise
prevent the system from completing POST), this is an acceptable cost.

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown
2010-04-25 01:50:46 +01:00
parent c97079710f
commit 5a5d8dd10a
3 changed files with 25 additions and 6 deletions
+1
View File
@@ -28,6 +28,7 @@ undiloader:
movw %es:14(%di), %ax
movl image_source, %esi
movl decompress_to, %edi
clc /* Allow relocation */
call install_prealloc
popw %di
/* Call UNDI loader C code */