aboutsummaryrefslogtreecommitdiffstats
path: root/bcopy32.inc
diff options
context:
space:
mode:
authorhpa <hpa>2002-04-28 00:50:20 +0000
committerhpa <hpa>2002-04-28 00:50:20 +0000
commitb085cb9ecd24969421d10b8d5f37af5fb22c581f (patch)
tree5509a72490638e51d723431d57856c8412c8b70e /bcopy32.inc
parent3e012b34a2eac374cd3db4c74657fb059d357536 (diff)
downloadsyslinux.git-b085cb9ecd24969421d10b8d5f37af5fb22c581f.tar.gz
syslinux.git-b085cb9ecd24969421d10b8d5f37af5fb22c581f.tar.xz
syslinux.git-b085cb9ecd24969421d10b8d5f37af5fb22c581f.zip
Make the setup of the bootup entry state saner.
Diffstat (limited to 'bcopy32.inc')
-rw-r--r--bcopy32.inc19
1 files changed, 6 insertions, 13 deletions
diff --git a/bcopy32.inc b/bcopy32.inc
index 4910fbb0..af322f91 100644
--- a/bcopy32.inc
+++ b/bcopy32.inc
@@ -381,10 +381,7 @@ try_wbinvd:
;
; Inputs:
; ESI, EDI, ECX - same as bcopy
-; EDX - edx on invocation
-; EAX - esi on invocation
-; EBX - ebx on invocation
-; ES - es on invocation
+; On stack - initial state (ad, fd, ds, es, fs, gs)
;
%define ADJUST (__bcopy_start - trackbuf)
@@ -397,10 +394,6 @@ adjlist dw bcopy_gdt.adj1 - ADJUST
adjlist_cnt equ ($-adjlist)/2
bcopy_over_self:
- push es
- push ebx
- push eax
- push edx
push esi
push edi
push ecx
@@ -408,8 +401,6 @@ bcopy_over_self:
xor bx,bx
mov es,bx
mov ds,bx
- mov fs,bx
- mov gs,bx
mov si,__bcopy_start
mov di,trackbuf
@@ -439,9 +430,11 @@ bcopy_over_self:
pop esi
call bcopy
- pop edx
- pop esi
- pop ebx
+ pop gs
+ pop fs
pop es
+ pop ds
+ popfd
+ popad
jmp 0:7c00h
__bcopy_end: