summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/setup64.c
diff options
context:
space:
mode:
authorGlauber Costa <gcosta@redhat.com>2008-05-29 01:19:53 +0200
committerIngo Molnar <mingo@elte.hu>2008-07-08 12:48:16 +0200
commita939098afcfa5f81d3474782ec15c6d114e57763 (patch)
tree62c21fb10d6b58dc8247c34e68ab5562e045b8d0 /arch/x86/kernel/setup64.c
parentx86: don't use gdt_page openly. (diff)
downloadlinux-a939098afcfa5f81d3474782ec15c6d114e57763.tar.xz
linux-a939098afcfa5f81d3474782ec15c6d114e57763.zip
x86: move x86_64 gdt closer to i386
i386 and x86_64 used two different schemes for maintaining the gdt. With this patch, x86_64 initial gdt table is defined in a .c file, same way as i386 is now. Also, we call it "gdt_page", and the descriptor, "early_gdt_descr". This way we achieve common naming, which can allow for more code integration. Signed-off-by: Glauber Costa <gcosta@redhat.com> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/setup64.c')
-rw-r--r--arch/x86/kernel/setup64.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/arch/x86/kernel/setup64.c b/arch/x86/kernel/setup64.c
index fc1a56da8240..70ff07186772 100644
--- a/arch/x86/kernel/setup64.c
+++ b/arch/x86/kernel/setup64.c
@@ -202,11 +202,8 @@ void __cpuinit cpu_init (void)
* Initialize the per-CPU GDT with the boot GDT,
* and set up the GDT descriptor:
*/
- if (cpu)
- memcpy(get_cpu_gdt_table(cpu), cpu_gdt_table, GDT_SIZE);
- cpu_gdt_descr[cpu].size = GDT_SIZE;
- load_gdt((const struct desc_ptr *)&cpu_gdt_descr[cpu]);
+ switch_to_new_gdt();
load_idt((const struct desc_ptr *)&idt_descr);
memset(me->thread.tls_array, 0, GDT_ENTRY_TLS_ENTRIES * 8);