diff options
author | Anton Altaparmakov <aia21@hera.kernel.org> | 2006-03-23 14:39:08 +0000 |
---|---|---|
committer | Anton Altaparmakov <aia21@hera.kernel.org> | 2006-03-23 14:39:08 +0000 |
commit | 74293759002aa7db0179158c20676a034614577b (patch) | |
tree | 030ef62361042d1a034087ad9a726db3b57bba72 /arch/i386/kernel/efi.c | |
parent | bb8047d3540affd6b8c2adac3fe792e07143be0f (diff) | |
parent | 2e6e33bab6e1996a5dec9108fb467b52b841e7a8 (diff) | |
download | op-kernel-dev-74293759002aa7db0179158c20676a034614577b.zip op-kernel-dev-74293759002aa7db0179158c20676a034614577b.tar.gz |
Merge branch 'master' of /home/aia21/ntfs-2.6/
Diffstat (limited to 'arch/i386/kernel/efi.c')
-rw-r--r-- | arch/i386/kernel/efi.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/arch/i386/kernel/efi.c b/arch/i386/kernel/efi.c index ecad519..aeabb41 100644 --- a/arch/i386/kernel/efi.c +++ b/arch/i386/kernel/efi.c @@ -70,10 +70,13 @@ static void efi_call_phys_prelog(void) { unsigned long cr4; unsigned long temp; + struct Xgt_desc_struct *cpu_gdt_descr; spin_lock(&efi_rt_lock); local_irq_save(efi_rt_eflags); + cpu_gdt_descr = &per_cpu(cpu_gdt_descr, 0); + /* * If I don't have PSE, I should just duplicate two entries in page * directory. If I have PSE, I just need to duplicate one entry in @@ -103,17 +106,18 @@ static void efi_call_phys_prelog(void) */ local_flush_tlb(); - cpu_gdt_descr[0].address = __pa(cpu_gdt_descr[0].address); - load_gdt((struct Xgt_desc_struct *) __pa(&cpu_gdt_descr[0])); + cpu_gdt_descr->address = __pa(cpu_gdt_descr->address); + load_gdt(cpu_gdt_descr); } static void efi_call_phys_epilog(void) { unsigned long cr4; + struct Xgt_desc_struct *cpu_gdt_descr = &per_cpu(cpu_gdt_descr, 0); + + cpu_gdt_descr->address = (unsigned long)__va(cpu_gdt_descr->address); + load_gdt(cpu_gdt_descr); - cpu_gdt_descr[0].address = - (unsigned long) __va(cpu_gdt_descr[0].address); - load_gdt(&cpu_gdt_descr[0]); cr4 = read_cr4(); if (cr4 & X86_CR4_PSE) { |