summaryrefslogtreecommitdiff
path: root/include/asm-x86/irqflags.h
diff options
context:
space:
mode:
authorJeremy Fitzhardinge <jeremy@goop.org>2008-06-25 00:19:28 -0400
committerIngo Molnar <mingo@elte.hu>2008-07-08 13:15:52 +0200
commit2be29982a08009c731307f4a39053b70ac4700da (patch)
treef01fcf847f36b9da5cd87cefa7ee6c13d193077d /include/asm-x86/irqflags.h
parentc7245da6ae7e5208504ff027c4e0eec69b788651 (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.h14
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)
#ifdef CONFIG_X86_64
#define INTERRUPT_RETURN iretq
-#define USERGS_SYSRET \
- swapgs; \
- sysretq;
+#define USERGS_SYSRET64 \
+ swapgs; \
+ sysretq;
+#define USERGS_SYSRET32 \
+ swapgs; \
+ sysretl
+#define ENABLE_INTERRUPTS_SYSEXIT32 \
+ swapgs; \
+ sti; \
+ sysexit
+
#else
#define INTERRUPT_RETURN iret
#define ENABLE_INTERRUPTS_SYSEXIT sti; sysexit