aboutsummaryrefslogtreecommitdiffstats
path: root/tools/firmware/rombios
diff options
context:
space:
mode:
authorKeir Fraser <keir.fraser@citrix.com>2010-07-08 09:51:40 +0100
committerKeir Fraser <keir.fraser@citrix.com>2010-07-08 09:51:40 +0100
commit6456803dabb092076c6adb9e0fcb7b2161e7bfec (patch)
tree9269b0e805133477f99159b869d3a1fc67f2f1a3 /tools/firmware/rombios
parentb825e251d26688e4843668a555221d4fbf1f114d (diff)
downloadxen-6456803dabb092076c6adb9e0fcb7b2161e7bfec.tar.gz
xen-6456803dabb092076c6adb9e0fcb7b2161e7bfec.tar.bz2
xen-6456803dabb092076c6adb9e0fcb7b2161e7bfec.zip
rombios: move the stack to 0x9e000 and protect it with an e820 entry
so that we don't corrupt E820_RAM memory with stack ops in S3 wakeup. It has to move up so the lowest contiguous RAM area is >= 512MiB. This relies on the previous fix to let DS != SS Signed-off-by: Paul Durrant <Paul.Durrant@citrix.com> Signed-off-by: Tim Deegan <Tim.Deegan@citrix.com>
Diffstat (limited to 'tools/firmware/rombios')
-rw-r--r--tools/firmware/rombios/rombios.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/tools/firmware/rombios/rombios.c b/tools/firmware/rombios/rombios.c
index 3de72cf9d1..4e0157c80f 100644
--- a/tools/firmware/rombios/rombios.c
+++ b/tools/firmware/rombios/rombios.c
@@ -1,6 +1,6 @@
/////////////////////////////////////////////////////////////////////////
// $Id: rombios.c,v 1.221 2008/12/07 17:32:29 sshwarts Exp $
-/////////////////////////////////////////////////////////////////////////
+////////////////////////////#/////////////////////////////////////////////
//
// Copyright (C) 2002 MandrakeSoft S.A.
//
@@ -8862,13 +8862,14 @@ int13_out:
int18_handler: ;; Boot Failure recovery: try the next device.
;; Reset SP and SS
- mov ax, #0xfffe
+ mov ax, #0x0ffe
mov sp, ax
- xor ax, ax
+ mov ax, #0x9e00
mov ss, ax
;; The first time we do this it will have been set to -1 so
;; we will start from device 0.
+ xor ax, ax
mov ds, ax
mov bx, word ptr [0x40E] ;; EBDA segment
mov ds, bx ;; Set segment
@@ -8902,9 +8903,9 @@ int19_relocated: ;; Boot function, relocated
;;
;; Reset SP and SS
- mov ax, #0xfffe
+ mov ax, #0x0ffe
mov sp, ax
- xor ax, ax
+ mov ax, #0x9e00
mov ss, ax
call _machine_reset
@@ -10839,10 +10840,9 @@ normal_post:
; case 0: normal startup
cli
- mov ax, #0xfffe
+ mov ax, #0x0ffe
mov sp, ax
- xor ax, ax
- mov ds, ax
+ mov ax, #0x9e00
mov ss, ax
;; Save shutdown status