lkml.org 
[lkml]   [2009]   [Aug]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    Date
    From
    Subject[patch 66/74] x86: Fix VMI && stack protector
    2.6.30-stable review patch.  If anyone has any objections, please let us know.

    ------------------

    From: Alok Kataria <akataria@vmware.com>

    commit 7d5b005652bc5ae3e1e0efc53fd0e25a643ec506 upstream.

    With CONFIG_STACK_PROTECTOR turned on, VMI doesn't boot with
    more than one processor. The problem is with the gs value not
    being initialized correctly when registering the secondary
    processor for VMI's case.

    The patch below initializes the gs value for the AP to
    __KERNEL_STACK_CANARY. Without this the secondary processor
    keeps on taking a GP on every gs access.

    Signed-off-by: Alok N Kataria <akataria@vmware.com>
    LKML-Reference: <1249425262.18955.40.camel@ank32.eng.vmware.com>
    Signed-off-by: Ingo Molnar <mingo@elte.hu>
    Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>

    ---
    arch/x86/kernel/vmi_32.c | 2 +-
    1 file changed, 1 insertion(+), 1 deletion(-)

    --- a/arch/x86/kernel/vmi_32.c
    +++ b/arch/x86/kernel/vmi_32.c
    @@ -441,7 +441,7 @@ vmi_startup_ipi_hook(int phys_apicid, un
    ap.ds = __USER_DS;
    ap.es = __USER_DS;
    ap.fs = __KERNEL_PERCPU;
    - ap.gs = 0;
    + ap.gs = __KERNEL_STACK_CANARY;

    ap.eflags = 0;




    \
     
     \ /
      Last update: 2009-08-13 22:13    [W:0.021 / U:95.948 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site