Magellan Linux

Contents of /trunk/kernel26-xen/patches-2.6.25-r1/1142-2.6.25-xen-Create-xen-specific-syscall-entry.patch

Parent Directory Parent Directory | Revision Log Revision Log


Revision 606 - (show annotations) (download)
Thu May 22 23:13:13 2008 UTC (16 years ago) by niro
File size: 1991 byte(s)
-ver bump to 2.6.25-magellan-r1:
- linux-2.6.25.4
- fbcondecor-0.9.4
- squashfs-3.3
- unionfs-2.3.3
- tuxonice-3.0-rc7
- linux-phc-0.3.0
- acpi-dstd-0.9a
- reiser4
- xen-3.2.0
. ipw3945-1.2.2

1 From f651fb2302e82ffb677241a5e5e1b919f4028fb3 Mon Sep 17 00:00:00 2001
2 From: Eduardo Habkost <ehabkost@redhat.com>
3 Date: Mon, 4 Feb 2008 17:36:08 -0200
4 Subject: [PATCH] Create xen-specific syscall entry
5
6 The stack and register saving for syscall entry is very different under
7 xen. xen_system_call_entry just handle the register saving and jumps
8 to system_call_after_saveargs, inside system_call.
9
10 Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
11 ---
12 arch/x86/xen/entry_64.S | 15 +++++++++++++++
13 arch/x86/xen/setup.c | 2 +-
14 arch/x86/xen/xen-ops.h | 1 +
15 3 files changed, 17 insertions(+), 1 deletions(-)
16
17 diff --git a/arch/x86/xen/entry_64.S b/arch/x86/xen/entry_64.S
18 index 2a2a0a0..5c8910b 100644
19 --- a/arch/x86/xen/entry_64.S
20 +++ b/arch/x86/xen/entry_64.S
21 @@ -51,3 +51,18 @@ ENTRY(xen_retint_swapgs) /* return to user-space */
22 TRACE_IRQS_IRETQ
23 jmp restore_args
24 END(xen_retint_swapgs)
25 +
26 +
27 +ENTRY(xen_system_call_entry)
28 + CFI_STARTPROC simple
29 +
30 + //FIXME: CFI directives here
31 +
32 + // We need additional space for orig_ax.
33 + // That would be SAVE_ARGS 8, but we already have
34 + // r11 and rcx saved on the stack
35 + SAVE_ARGS -8
36 +
37 + jmp system_call_after_saveargs
38 + CFI_ENDPROC
39 +END(xen_system_call_entry)
40 diff --git a/arch/x86/xen/setup.c b/arch/x86/xen/setup.c
41 index a64385d..7b0468f 100644
42 --- a/arch/x86/xen/setup.c
43 +++ b/arch/x86/xen/setup.c
44 @@ -100,7 +100,7 @@ void __init xen_arch_setup(void)
45 #else
46 HYPERVISOR_set_callbacks((unsigned long)xen_hypervisor_callback,
47 (unsigned long)xen_failsafe_callback,
48 - (unsigned long)system_call_after_swapgs);
49 + (unsigned long)xen_system_call_entry);
50 #endif
51
52 set_iopl.iopl = 1;
53 diff --git a/arch/x86/xen/xen-ops.h b/arch/x86/xen/xen-ops.h
54 index b523062..4bd901c 100644
55 --- a/arch/x86/xen/xen-ops.h
56 +++ b/arch/x86/xen/xen-ops.h
57 @@ -74,4 +74,5 @@ void xen_iret_direct(void);
58 void xen_iret(void);
59 void xen_irqenable_syscall_ret(void);
60
61 +void xen_system_call_entry(void);
62 #endif /* XEN_OPS_H */
63 --
64 1.5.4.1
65