diff options
author | Jeremy Fitzhardinge <jeremy@goop.org> | 2008-06-25 00:19:28 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-08 07:15:52 -0400 |
commit | 2be29982a08009c731307f4a39053b70ac4700da (patch) | |
tree | f01fcf847f36b9da5cd87cefa7ee6c13d193077d /include/asm-x86/irqflags.h | |
parent | c7245da6ae7e5208504ff027c4e0eec69b788651 (diff) |
x86/paravirt: add sysret/sysexit pvops for returning to 32-bit compatibility userspace
In a 64-bit system, we need separate sysret/sysexit operations to
return to a 32-bit userspace.
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citirx.com>
Cc: xen-devel <xen-devel@lists.xensource.com>
Cc: Stephen Tweedie <sct@redhat.com>
Cc: Eduardo Habkost <ehabkost@redhat.com>
Cc: Mark McLoughlin <markmc@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/asm-x86/irqflags.h')
-rw-r--r-- | include/asm-x86/irqflags.h | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/include/asm-x86/irqflags.h b/include/asm-x86/irqflags.h index 544836c96b61..ea9bd2635d59 100644 --- a/include/asm-x86/irqflags.h +++ b/include/asm-x86/irqflags.h | |||
@@ -112,9 +112,17 @@ static inline unsigned long __raw_local_irq_save(void) | |||
112 | 112 | ||
113 | #ifdef CONFIG_X86_64 | 113 | #ifdef CONFIG_X86_64 |
114 | #define INTERRUPT_RETURN iretq | 114 | #define INTERRUPT_RETURN iretq |
115 | #define USERGS_SYSRET \ | 115 | #define USERGS_SYSRET64 \ |
116 | swapgs; \ | 116 | swapgs; \ |
117 | sysretq; | 117 | sysretq; |
118 | #define USERGS_SYSRET32 \ | ||
119 | swapgs; \ | ||
120 | sysretl | ||
121 | #define ENABLE_INTERRUPTS_SYSEXIT32 \ | ||
122 | swapgs; \ | ||
123 | sti; \ | ||
124 | sysexit | ||
125 | |||
118 | #else | 126 | #else |
119 | #define INTERRUPT_RETURN iret | 127 | #define INTERRUPT_RETURN iret |
120 | #define ENABLE_INTERRUPTS_SYSEXIT sti; sysexit | 128 | #define ENABLE_INTERRUPTS_SYSEXIT sti; sysexit |