chore: fix almost *ALL* warnings.
[lunaix-os.git] / lunaix-os / kernel / asm / x86 / syscall.S
index bde7f36d9d79b6a0f2e59736be6fd5e4ad191fdc..b48aeade91db4150136b9201f3872c5b616014e1 100644 (file)
 .section .text
     syscall_hndlr:
         pushl %ebp
-        movl 8(%esp), %ebp
+        movl 8(%esp), %ebp          // isr_param*
 
-        movl  (%ebp), %eax          /* eax: call code as well as the return value from syscall */
-        cmpl  $__SYSCALL_MAX, %eax
+        addl $4, %ebp
+        movl (%ebp), %eax          /* eax: call code as well as the return value from syscall */
+        cmpl $__SYSCALL_MAX, %eax
         jae 2f
 
         shll $2, %eax
@@ -93,7 +94,7 @@
         pushl 8(%ebp)       /* ecx - #2 arg */
         pushl 4(%ebp)       /* ebx - #1 arg */
         
-        call (%eax)
+        call *(%eax)
 
         movl %eax, (%ebp)    /* save the return value */