mirror of https://github.com/ipxe/ipxe.git
[pcbios] Add extra debugging messages when unhiding iPXE from memory
Signed-off-by: Michael Brown <mcb30@ipxe.org>pull/6/merge
parent
3a8dbd9cdf
commit
b33082a52b
|
@ -190,6 +190,8 @@ static void hide_etherboot ( void ) {
|
||||||
* possible.
|
* possible.
|
||||||
*/
|
*/
|
||||||
static void unhide_etherboot ( int flags __unused ) {
|
static void unhide_etherboot ( int flags __unused ) {
|
||||||
|
struct memory_map memmap;
|
||||||
|
int rc;
|
||||||
|
|
||||||
/* If we have more than one hooked interrupt at this point, it
|
/* If we have more than one hooked interrupt at this point, it
|
||||||
* means that some other vector is still hooked, in which case
|
* means that some other vector is still hooked, in which case
|
||||||
|
@ -203,15 +205,23 @@ static void unhide_etherboot ( int flags __unused ) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Try to unhook INT 15. If it fails, then just leave it
|
/* Try to unhook INT 15 */
|
||||||
* hooked; it takes care of protecting itself. :)
|
if ( ( rc = unhook_bios_interrupt ( 0x15, ( unsigned int ) int15,
|
||||||
*/
|
&int15_vector ) ) != 0 ) {
|
||||||
unhook_bios_interrupt ( 0x15, ( unsigned int ) int15,
|
DBG ( "Cannot unhook INT15: %s\n", strerror ( rc ) );
|
||||||
&int15_vector );
|
/* Leave it hooked; there's nothing else we can do,
|
||||||
|
* and it should be intrinsically safe (though
|
||||||
|
* wasteful of RAM).
|
||||||
|
*/
|
||||||
|
}
|
||||||
|
|
||||||
/* Unhook fake E820 map, if used */
|
/* Unhook fake E820 map, if used */
|
||||||
if ( FAKE_E820 )
|
if ( FAKE_E820 )
|
||||||
unfake_e820();
|
unfake_e820();
|
||||||
|
|
||||||
|
/* Dump memory map after unhiding */
|
||||||
|
DBG ( "Unhidden iPXE from system memory map\n" );
|
||||||
|
get_memmap ( &memmap );
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Hide Etherboot startup function */
|
/** Hide Etherboot startup function */
|
||||||
|
|
Loading…
Reference in New Issue