Fix SYSENTER support in VMware. New benchmar: 200ms. ***70%*** faster then with Int2E...
authorAlex Ionescu <aionescu@gmail.com>
Tue, 18 Jan 2005 03:28:00 +0000 (03:28 +0000)
committerAlex Ionescu <aionescu@gmail.com>
Tue, 18 Jan 2005 03:28:00 +0000 (03:28 +0000)
svn path=/trunk/; revision=13107

reactos/ntoskrnl/ke/i386/syscall.S
reactos/subsys/system/vmwinst/vmwinst.c
reactos/win32k.S [deleted file]

index a281683..7a8d833 100644 (file)
 .globl _KiSystemService
 
 _KiFastCallEntry:
-
+    
     /* Set FS to PCR */
     movl $PCR_SELECTOR, %ecx
     movw %cx, %fs
-    
+       
     /* Set the current stack to Kernel Stack */
     movl %fs:KPCR_TSS, %ecx
-    movl KTSS_ESP0(%ecx), %ecx
+    movl %ss:KTSS_ESP0(%ecx), %ecx
     movl %ecx, %esp
     
     /* Set up a fake INT Stack. */
@@ -205,7 +205,7 @@ _KiServiceExit:
     /* Save pointer to Trap Frame */
     movl %esp, %ebx
     
-    /* Raise IRQL to HIGH_LEVEL */
+    /* Raise IRQL to APC_LEVEL */
     movl $1, %ecx
     call @KfRaiseIrql@4
     
index f90e9f6..3af6cbd 100644 (file)
@@ -315,43 +315,6 @@ SaveResolutionSettings(DWORD ResX, DWORD ResY, DWORD ColDepth)
   return TRUE;
 }
 
-BOOL
-DisableFastSystemCall(VOID)
-{
-    DWORD Value = 1;
-    HKEY hReg;
-    
-    /* Open or Create the Kernel Settings Key */    
-    if(RegCreateKeyEx(HKEY_LOCAL_MACHINE,
-                      L"SYSTEM\\CurrentControlSet\\Control\\Session Manager\\Kernel", 
-                      0,
-                      NULL,
-                      REG_OPTION_NON_VOLATILE,
-                      KEY_SET_VALUE, 
-                      NULL,
-                      &hReg,
-                      NULL) != ERROR_SUCCESS) {
-        DbgPrint("Failed to Disable Sysenter\n");
-        return FALSE;
-    }
-    
-    /* Disable Fast System Call */
-    if(RegSetValueEx(hReg, 
-                     L"FastSystemCallDisable", 
-                     0, 
-                     REG_DWORD, 
-                     (BYTE*)&Value, 
-                     sizeof(DWORD)) != ERROR_SUCCESS) {
-        RegCloseKey(hReg);
-        DbgPrint("Failed to Disable Sysenter\n");
-        return FALSE;
-    }
-  
-    /* Return Success */  
-    RegCloseKey(hReg);
-    return TRUE;
-}
-
 BOOL
 EnableDriver(WCHAR *Key, BOOL Enable)
 {
@@ -1061,9 +1024,6 @@ WinMain(HINSTANCE hInstance,
   /* restore the exception handler */
   SetUnhandledExceptionFilter(OldHandler);
   
-  /* Disable Fast System Call no matter what */
-  DisableFastSystemCall();
-  
   lc = DestinationPath;
   lc += GetSystemDirectory(DestinationPath, MAX_PATH) - 1;
   if(lc >= DestinationPath && *lc != L'\\')
diff --git a/reactos/win32k.S b/reactos/win32k.S
deleted file mode 100644 (file)
index f6b4d90..0000000
+++ /dev/null
@@ -1 +0,0 @@
-#include "../gdi32/misc/win32k.c"