aboutsummaryrefslogtreecommitdiffstats
path: root/gpxe/src/arch/i386/firmware/pcbios/fakee820.c
diff options
context:
space:
mode:
Diffstat (limited to 'gpxe/src/arch/i386/firmware/pcbios/fakee820.c')
-rw-r--r--gpxe/src/arch/i386/firmware/pcbios/fakee820.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/gpxe/src/arch/i386/firmware/pcbios/fakee820.c b/gpxe/src/arch/i386/firmware/pcbios/fakee820.c
index e171edfd..552bf41d 100644
--- a/gpxe/src/arch/i386/firmware/pcbios/fakee820.c
+++ b/gpxe/src/arch/i386/firmware/pcbios/fakee820.c
@@ -63,6 +63,8 @@ void fake_e820 ( void ) {
"cmpl $0x534d4150, %%edx\n\t"
"jne 99f\n\t"
"pushaw\n\t"
+ "movw %%sp, %%bp\n\t"
+ "andb $~0x01, 22(%%bp)\n\t" /* Clear return CF */
"leaw e820map(%%bx), %%si\n\t"
"cs rep movsb\n\t"
"popaw\n\t"
@@ -73,8 +75,7 @@ void fake_e820 ( void ) {
"xorl %%ebx,%%ebx\n\t"
"\n1:\n\t"
"popfw\n\t"
- "clc\n\t"
- "lret $2\n\t"
+ "iret\n\t"
"\n99:\n\t"
"popfw\n\t"
"ljmp *%%cs:real_int15_vector\n\t" )