This commit was generated by cvs2svn to compensate for changes in r52,
[reactos.git] / reactos / ntoskrnl / hal / x86 / usercall.asm
index bab7e27..0c0ba44 100644 (file)
@@ -1,46 +1,35 @@
 ;
 ;
 
-%include "internal/hal/segment.inc"
+%include 'internal/hal/segment.inc'
 
 bits 32
 section .text
-extern _SystemServiceTable
+extern __SystemServiceTable
+global _interrupt_handler2e
 
-_kernel_mode_call_handler:
-
-          ;
-         ; Save some registers
-         ; 
-          push ds
-         push es
-         push esi
-         push edi
-         
-         ;
-         ; Transfer the parameters from user mode 
-         ;
-         push USER_DS
-         pop es
-         
-         mov edx,esi
-         mov esp,edi
-         mov ecx,_SystemServiceTable[eax*4]
-         sub esp,ecx
-         cld
-         rep movsb
-         
-         ;
-         ; Call the actual service routine
-         ;
-         mov eax,_SystemServiceTable[eax*4+4]
-         jmp eax
-         
-         ;
-         ; Restore registers and return
-         ;
-         pop edi
-         pop esi
-         pop es
-         pop ds
-         ret
+_interrupt_handler2e:
+         push ds
+        push es
+        push esi
+        push edi
+        
+        mov bx,KERNEL_DS
+        mov es,bx
+        
+        mov esi,edx
+        mov ecx,[es:__SystemServiceTable+eax*8]
+        sub esp,ecx
+        mov edi,esp
+        rep movsb
+        
+        mov ds,bx
+                
+        mov eax,[__SystemServiceTable+4+eax*8]
+        call eax
+        
+        pop edi
+        pop esi
+        pop es
+        pop ds
+        iret