lkml.org 
[lkml]   [2008]   [Jul]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Subject[PATCH 43 of 55] xen64: implement xen_load_gs_index()
    Date
    From
    From: Eduardo Habkost <ehabkost@redhat.com>

    xen-64: implement xen_load_gs_index()

    Signed-off-by: Eduardo Habkost <ehabkost@redhat.com>
    Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
    ---
    arch/x86/xen/enlighten.c | 11 +++++++++++
    1 file changed, 11 insertions(+)

    diff --git a/arch/x86/xen/enlighten.c b/arch/x86/xen/enlighten.c
    --- a/arch/x86/xen/enlighten.c
    +++ b/arch/x86/xen/enlighten.c
    @@ -384,6 +384,14 @@
    if (paravirt_get_lazy_mode() == PARAVIRT_LAZY_CPU)
    loadsegment(gs, 0);
    }
    +
    +#ifdef CONFIG_X86_64
    +static void xen_load_gs_index(unsigned int idx)
    +{
    + if (HYPERVISOR_set_segment_base(SEGBASE_GS_USER_SEL, idx))
    + BUG();
    +}
    +#endif

    static void xen_write_ldt_entry(struct desc_struct *dt, int entrynum,
    const void *ptr)
    @@ -1063,6 +1071,9 @@
    .load_gdt = xen_load_gdt,
    .load_idt = xen_load_idt,
    .load_tls = xen_load_tls,
    +#ifdef CONFIG_X86_64
    + .load_gs_index = xen_load_gs_index,
    +#endif

    .store_gdt = native_store_gdt,
    .store_idt = native_store_idt,



    \
     
     \ /
      Last update: 2008-07-09 01:33    [W:0.020 / U:60.264 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site