Re: [RFC PATCH 18/35] Support gdt/idt/ldt handling on Xen.
From: Andi Kleen
Date: Wed Mar 22 2006 - 10:03:20 EST
On Wednesday 22 March 2006 07:30, Chris Wright wrote:
>
> -#define load_TR_desc() __asm__ __volatile__("ltr %w0"::"q" (GDT_ENTRY_TSS*8))
> -#define load_LDT_desc() __asm__ __volatile__("lldt %w0"::"q" (GDT_ENTRY_LDT*8))
> -
> -#define load_gdt(dtr) __asm__ __volatile("lgdt %0"::"m" (*dtr))
> -#define load_idt(dtr) __asm__ __volatile("lidt %0"::"m" (*dtr))
> -#define load_tr(tr) __asm__ __volatile("ltr %0"::"mr" (tr))
> -#define load_ldt(ldt) __asm__ __volatile("lldt %0"::"mr" (ldt))
> -
> -#define store_gdt(dtr) __asm__ ("sgdt %0":"=m" (*dtr))
> -#define store_idt(dtr) __asm__ ("sidt %0":"=m" (*dtr))
> -#define store_tr(tr) __asm__ ("str %0":"=mr" (tr))
> -#define store_ldt(ldt) __asm__ ("sldt %0":"=mr" (ldt))
These are all very infrequent except perhaps LLDT. I suspect trapping would
work too. But ok.
> -#define _set_tssldt_desc(n,addr,limit,type) \
[...]
Why are you moving these? Xen should just be parsing the same structures
as the hardware, shouldn't it?
-Andi
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/