summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Brown2008-08-26 06:03:19 +0200
committerMichael Brown2008-08-26 06:03:19 +0200
commitd5732b027252e87509aea29d35d2c2f020f11ec2 (patch)
tree8896e193eccfec603694f7685eb5d0b7dd9b21a2
parent[phantom] Remove comment that no longer matches reality (diff)
downloadipxe-d5732b027252e87509aea29d35d2c2f020f11ec2.tar.gz
ipxe-d5732b027252e87509aea29d35d2c2f020f11ec2.tar.xz
ipxe-d5732b027252e87509aea29d35d2c2f020f11ec2.zip
[romprefix] Preserve %edi when issuing INT 1A,B101
INT 1A,B101 (get PCI BIOS version) will overwrite %edi.
-rw-r--r--src/arch/i386/prefix/romprefix.S4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/arch/i386/prefix/romprefix.S b/src/arch/i386/prefix/romprefix.S
index 8b2e20b2..b22cbab3 100644
--- a/src/arch/i386/prefix/romprefix.S
+++ b/src/arch/i386/prefix/romprefix.S
@@ -177,6 +177,7 @@ init:
/* Check for PCI BIOS version */
pushl %ebx
pushl %edx
+ pushl %edi
stc
movw $0xb101, %ax
int $0x1a
@@ -199,7 +200,8 @@ init:
1: /* PCI <3.0: set %gs (runtime segment) = %cs (init-time segment) */
pushw %cs
popw %gs
-2: popl %edx
+2: popl %edi
+ popl %edx
popl %ebx
/* Check for PnP BIOS */