Ignore:
Timestamp:
2010-07-14T12:29:35Z (15 years ago)
Author:
Jakub Jermar <jakub@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
864e272
Parents:
a7220de
Message:

Preallocate space for the istate structure on the stack for the use by the
SYSENTER instruction.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/arch/ia32/src/proc/scheduler.c

    ra7220de rc8cd9a8  
    3939#include <arch.h>
    4040#include <arch/context.h>  /* SP_DELTA */
     41#include <arch/interrupt.h>
    4142#include <arch/pm.h>
    4243#include <arch/asm.h>
     
    6364        if (CPU->arch.fi.bits.sep) {
    6465                /* Set kernel stack for CP3 -> CPL0 switch via SYSENTER */
    65                 write_msr(IA32_MSR_SYSENTER_ESP, kstk);
     66                write_msr(IA32_MSR_SYSENTER_ESP, kstk - sizeof(istate_t));
    6667        }
    6768       
Note: See TracChangeset for help on using the changeset viewer.