[PATCH] i386: rationalize paravirt wrappers
authorRusty Russell <rusty@rustcorp.com.au>
Wed, 2 May 2007 17:27:10 +0000 (19:27 +0200)
committerAndi Kleen <andi@basil.nowhere.org>
Wed, 2 May 2007 17:27:10 +0000 (19:27 +0200)
commit90a0a06aa81692028864c21f981905fda46b1208
tree516528b328d5288ee057d1eff5491e2ba1b49af1
parent52de74dd3994e165ef1b35c33d54655a6400e30c
[PATCH] i386: rationalize paravirt wrappers

paravirt.c used to implement native versions of all low-level
functions.  Far cleaner is to have the native versions exposed in the
headers and as inline native_XXX, and if !CONFIG_PARAVIRT, then simply
#define XXX native_XXX.

There are several nice side effects:

1) write_dt_entry() now takes the correct "struct Xgt_desc_struct *"
   not "void *".

2) load_TLS is reintroduced to the for loop, not manually unrolled
   with a #error in case the bounds ever change.

3) Macros become inlines, with type checking.

4) Access to the native versions is trivial for KVM, lguest, Xen and
   others who might want it.

Signed-off-by: Jeremy Fitzhardinge <jeremy@xensource.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Andi Kleen <ak@suse.de>
Cc: Andi Kleen <ak@muc.de>
Cc: Avi Kivity <avi@qumranet.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
arch/i386/kernel/paravirt.c
include/asm-i386/desc.h
include/asm-i386/io.h
include/asm-i386/irqflags.h
include/asm-i386/msr.h
include/asm-i386/paravirt.h
include/asm-i386/processor.h
include/asm-i386/system.h