[BACK]Return to locore.S CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / arch / i386 / i386

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/arch/i386/i386/locore.S between version 1.47.4.9 and 1.47.4.10

version 1.47.4.9, 2007/11/16 20:31:20 version 1.47.4.10, 2007/12/03 18:36:43
Line 111 
Line 111 
  */   */
   
 #include "opt_compat_oldboot.h"  #include "opt_compat_oldboot.h"
 #include "opt_cputype.h"  
 #include "opt_ddb.h"  #include "opt_ddb.h"
 #include "opt_realmem.h"  #include "opt_realmem.h"
 #include "opt_vm86.h"  #include "opt_vm86.h"
Line 764  ENTRY(cpu_switchto)
Line 763  ENTRY(cpu_switchto)
         /* Switch TSS.  Reset "task busy" flag before loading. */          /* Switch TSS.  Reset "task busy" flag before loading. */
         movl    %cr3,%eax          movl    %cr3,%eax
         movl    %eax,PCB_CR3(%ebx)      # for TSS gates          movl    %eax,PCB_CR3(%ebx)      # for TSS gates
         movl    CPUVAR(GDT),%eax          movl    CPUVAR(GDT),%ecx
         movl    L_MD_TSS_SEL(%edi),%edx          movl    L_MD_TSS_SEL(%edi),%edx
         andl    $~0x0200,4(%eax,%edx, 1)          andl    $~0x0200,4(%ecx,%edx, 1)
         ltr     %dx          ltr     %dx
   
         /* Don't bother with the rest if switching to a system process. */          /* Don't bother with the rest if switching to a system process. */
         testl   $LW_SYSTEM,L_FLAG(%edi)          testl   $LW_SYSTEM,L_FLAG(%edi)
         jnz     4f          jnz     4f
   
           /* Restore thread-private %fs/%gs descriptors. */
           movl    PCB_FSD(%ebx), %eax
           movl    PCB_FSD+4(%ebx), %edx
           movl    %eax, (GUFS_SEL*8)(%ecx)
           movl    %edx, (GUFS_SEL*8+4)(%ecx)
           movl    PCB_GSD(%ebx), %eax
           movl    PCB_GSD+4(%ebx), %edx
           movl    %eax, (GUGS_SEL*8)(%ecx)
           movl    %edx, (GUGS_SEL*8+4)(%ecx)
   
           /* Restore thread-private %fs/%gs descriptors. */
           movl    PCB_FSD(%ebx), %eax
           movl    PCB_FSD+4(%ebx), %edx
           movl    %eax, (GUFS_SEL*8)(%ecx)
           movl    %edx, (GUFS_SEL*8+4)(%ecx)
           movl    PCB_GSD(%ebx), %eax
           movl    PCB_GSD+4(%ebx), %edx
           movl    %eax, (GUGS_SEL*8)(%ecx)
           movl    %edx, (GUGS_SEL*8+4)(%ecx)
   
         /* Is this process using RAS (restartable atomic sequences)? */          /* Is this process using RAS (restartable atomic sequences)? */
         movl    L_PROC(%edi),%eax          movl    L_PROC(%edi),%eax
         cmpl    $0,P_RASLIST(%eax)          cmpl    $0,P_RASLIST(%eax)

Legend:
Removed from v.1.47.4.9  
changed lines
  Added in v.1.47.4.10

CVSweb <webmaster@jp.NetBSD.org>