diff options
author | H. Peter Anvin <hpa@zytor.com> | 2008-01-30 07:31:02 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-01-30 07:31:02 -0500 |
commit | faca62273b602ab482fb7d3d940dbf41ef08b00e (patch) | |
tree | 913fb1c565a2b719b00ae4b745c38cc9b0ebf279 /arch/x86/kernel/vmi_32.c | |
parent | 25149b62d3e6a3e737af39bd4a0b4e97de0811b7 (diff) |
x86: use generic register name in the thread and tss structures
This changes size-specific register names (eip/rip, esp/rsp, etc.) to
generic names in the thread and tss structures.
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'arch/x86/kernel/vmi_32.c')
-rw-r--r-- | arch/x86/kernel/vmi_32.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/arch/x86/kernel/vmi_32.c b/arch/x86/kernel/vmi_32.c index 599b6f2ed562..4cfda7dbe90f 100644 --- a/arch/x86/kernel/vmi_32.c +++ b/arch/x86/kernel/vmi_32.c | |||
@@ -62,7 +62,7 @@ static struct { | |||
62 | void (*cpuid)(void /* non-c */); | 62 | void (*cpuid)(void /* non-c */); |
63 | void (*_set_ldt)(u32 selector); | 63 | void (*_set_ldt)(u32 selector); |
64 | void (*set_tr)(u32 selector); | 64 | void (*set_tr)(u32 selector); |
65 | void (*set_kernel_stack)(u32 selector, u32 esp0); | 65 | void (*set_kernel_stack)(u32 selector, u32 sp0); |
66 | void (*allocate_page)(u32, u32, u32, u32, u32); | 66 | void (*allocate_page)(u32, u32, u32, u32, u32); |
67 | void (*release_page)(u32, u32); | 67 | void (*release_page)(u32, u32); |
68 | void (*set_pte)(pte_t, pte_t *, unsigned); | 68 | void (*set_pte)(pte_t, pte_t *, unsigned); |
@@ -214,17 +214,17 @@ static void vmi_set_tr(void) | |||
214 | vmi_ops.set_tr(GDT_ENTRY_TSS*sizeof(struct desc_struct)); | 214 | vmi_ops.set_tr(GDT_ENTRY_TSS*sizeof(struct desc_struct)); |
215 | } | 215 | } |
216 | 216 | ||
217 | static void vmi_load_esp0(struct tss_struct *tss, | 217 | static void vmi_load_sp0(struct tss_struct *tss, |
218 | struct thread_struct *thread) | 218 | struct thread_struct *thread) |
219 | { | 219 | { |
220 | tss->x86_tss.esp0 = thread->esp0; | 220 | tss->x86_tss.sp0 = thread->sp0; |
221 | 221 | ||
222 | /* This can only happen when SEP is enabled, no need to test "SEP"arately */ | 222 | /* This can only happen when SEP is enabled, no need to test "SEP"arately */ |
223 | if (unlikely(tss->x86_tss.ss1 != thread->sysenter_cs)) { | 223 | if (unlikely(tss->x86_tss.ss1 != thread->sysenter_cs)) { |
224 | tss->x86_tss.ss1 = thread->sysenter_cs; | 224 | tss->x86_tss.ss1 = thread->sysenter_cs; |
225 | wrmsr(MSR_IA32_SYSENTER_CS, thread->sysenter_cs, 0); | 225 | wrmsr(MSR_IA32_SYSENTER_CS, thread->sysenter_cs, 0); |
226 | } | 226 | } |
227 | vmi_ops.set_kernel_stack(__KERNEL_DS, tss->x86_tss.esp0); | 227 | vmi_ops.set_kernel_stack(__KERNEL_DS, tss->x86_tss.sp0); |
228 | } | 228 | } |
229 | 229 | ||
230 | static void vmi_flush_tlb_user(void) | 230 | static void vmi_flush_tlb_user(void) |
@@ -793,7 +793,7 @@ static inline int __init activate_vmi(void) | |||
793 | para_fill(pv_cpu_ops.write_ldt_entry, WriteLDTEntry); | 793 | para_fill(pv_cpu_ops.write_ldt_entry, WriteLDTEntry); |
794 | para_fill(pv_cpu_ops.write_gdt_entry, WriteGDTEntry); | 794 | para_fill(pv_cpu_ops.write_gdt_entry, WriteGDTEntry); |
795 | para_fill(pv_cpu_ops.write_idt_entry, WriteIDTEntry); | 795 | para_fill(pv_cpu_ops.write_idt_entry, WriteIDTEntry); |
796 | para_wrap(pv_cpu_ops.load_esp0, vmi_load_esp0, set_kernel_stack, UpdateKernelStack); | 796 | para_wrap(pv_cpu_ops.load_sp0, vmi_load_sp0, set_kernel_stack, UpdateKernelStack); |
797 | para_fill(pv_cpu_ops.set_iopl_mask, SetIOPLMask); | 797 | para_fill(pv_cpu_ops.set_iopl_mask, SetIOPLMask); |
798 | para_fill(pv_cpu_ops.io_delay, IODelay); | 798 | para_fill(pv_cpu_ops.io_delay, IODelay); |
799 | 799 | ||