ia64/xen-unstable
changeset 1355:a2abb67d5518
bitkeeper revision 1.891.1.6 (40a0ae5eutaU3rAbWk9U-crM-pFkag)
Fix missing STI from fault handlers in Xen.
Fix missing STI from fault handlers in Xen.
author | kaf24@scramble.cl.cam.ac.uk |
---|---|
date | Tue May 11 10:43:42 2004 +0000 (2004-05-11) |
parents | 00059c1948cf |
children | 0fab6364d23b 2168eda5e9fe |
files | xen/arch/i386/entry.S |
line diff
1.1 --- a/xen/arch/i386/entry.S Fri May 07 14:53:28 2004 +0000 1.2 +++ b/xen/arch/i386/entry.S Tue May 11 10:43:42 2004 +0000 1.3 @@ -145,16 +145,13 @@ NT_MASK = 0x00004000 1.4 pushl %ecx; \ 1.5 pushl %ebx; \ 1.6 1.7 -#define SAVE_ALL_NOSTI \ 1.8 +#define SAVE_ALL \ 1.9 SAVE_ALL_NOSEGREGS \ 1.10 movl $(__HYPERVISOR_DS),%edx; \ 1.11 movl %edx,%ds; \ 1.12 movl %edx,%es; \ 1.13 movl %edx,%fs; \ 1.14 movl %edx,%gs; 1.15 - 1.16 -#define SAVE_ALL \ 1.17 - SAVE_ALL_NOSTI \ 1.18 sti; 1.19 1.20 #define GET_CURRENT(reg) \ 1.21 @@ -533,12 +530,18 @@ error_code: 1.22 movl GS(%esp), %edi # get the function address 1.23 movl %eax, ORIG_EAX(%esp) 1.24 movl %ecx, GS(%esp) 1.25 - movl %esp,%edx 1.26 - pushl %esi # push the error code 1.27 - pushl %edx # push the pt_regs pointer 1.28 movl $(__HYPERVISOR_DS),%edx 1.29 movl %edx,%ds 1.30 movl %edx,%es 1.31 + movl %edx,%fs 1.32 + movl %edx,%gs 1.33 + movl EFLAGS(%esp),%edx 1.34 + testl $0x200,%edx # Is IF asserted in saved EFLAGS? 1.35 + jz 1f # Don't STI if it isn't. 1.36 + sti 1.37 +1: movl %esp,%edx 1.38 + pushl %esi # push the error code 1.39 + pushl %edx # push the pt_regs pointer 1.40 GET_CURRENT(%ebx) 1.41 call *%edi 1.42 addl $8,%esp