Subversion Repositories HelenOS

Rev

Rev 2541 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 2541 Rev 2610
Line 37... Line 37...
37
 
37
 
38
#include <sys/types.h>
38
#include <sys/types.h>
39
#include <kernel/syscall/syscall.h>
39
#include <kernel/syscall/syscall.h>
40
 
40
 
41
static inline sysarg_t
41
static inline sysarg_t
-
 
42
__syscall(const sysarg_t p1, const sysarg_t p2, const sysarg_t p3,
42
__syscall(const sysarg_t p1, const sysarg_t p2, const sysarg_t p3, const sysarg_t p4, const syscall_t id)
43
    const sysarg_t p4, const sysarg_t p5, const sysarg_t p6, const syscall_t id)
43
{
44
{
44
    register uint64_t a1 asm("o0") = p1;
45
    register uint64_t a1 asm("o0") = p1;
45
    register uint64_t a2 asm("o1") = p2;
46
    register uint64_t a2 asm("o1") = p2;
46
    register uint64_t a3 asm("o2") = p3;
47
    register uint64_t a3 asm("o2") = p3;
47
    register uint64_t a4 asm("o3") = p4;
48
    register uint64_t a4 asm("o3") = p4;
-
 
49
    register uint64_t a5 asm("o4") = p5;
-
 
50
    register uint64_t a6 asm("o5") = p6;
48
 
51
 
49
    asm volatile (
52
    asm volatile (
50
        "ta %5\n"
53
        "ta %7\n"
51
        : "=r" (a1)
54
        : "=r" (a1)
52
        : "r" (a1), "r" (a2), "r" (a3), "r" (a4), "i" (id)
55
        : "r" (a1), "r" (a2), "r" (a3), "r" (a4), "r" (a5), "r" (a6),
-
 
56
          "i" (id)
53
        : "memory"
57
        : "memory"
54
    );
58
    );
55
   
59
   
56
    return a1;
60
    return a1;
57
}
61
}