00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020 #ifndef _RTAI_ASM_GENERIC_SYSCALL_H
00021 #define _RTAI_ASM_GENERIC_SYSCALL_H
00022
00023
00024 #define __xn_sys_mux 555
00025
00026 #define __xn_sys_bind 0
00027 #define __xn_sys_completion 1
00028 #define __xn_sys_migrate 2
00029 #define __xn_sys_barrier 3
00030
00031 #define XENOMAI_LINUX_DOMAIN 0
00032 #define XENOMAI_RTAI_DOMAIN 1
00033
00034 typedef struct xnsysinfo {
00035
00036 unsigned long long cpufreq;
00037 unsigned long tickval;
00038
00039 } xnsysinfo_t;
00040
00041 typedef struct xninquiry {
00042
00043 char name[32];
00044 int prio;
00045 unsigned long status;
00046 void *khandle;
00047 void *uhandle;
00048
00049 } xninquiry_t;
00050
00051 #ifdef __KERNEL__
00052
00053 #include <linux/types.h>
00054
00055 struct task_struct;
00056
00057 #define XENOMAI_MAX_SYSENT 255
00058
00059 typedef struct _xnsysent {
00060
00061 int (*svc)(struct task_struct *task,
00062 struct pt_regs *regs);
00063
00064
00065 #define __xn_exec_lostage 0x1
00066
00067 #define __xn_exec_histage 0x2
00068
00069 #define __xn_exec_shadow 0x4
00070
00071 #define __xn_exec_switchback 0x8
00072
00073 #define __xn_exec_current 0x10
00074
00075 #define __xn_exec_conforming 0x20
00076
00077 #define __xn_exec_adaptive 0x40
00078
00079 #define __xn_exec_any 0x0
00080
00081 #define __xn_exec_init __xn_exec_lostage
00082
00083 #define __xn_exec_primary (__xn_exec_shadow|__xn_exec_histage)
00084
00085 #define __xn_exec_secondary (__xn_exec_shadow|__xn_exec_lostage)
00086
00087 u_long flags;
00088
00089 } xnsysent_t;
00090
00091 extern int nkgkptd;
00092
00093 #define xnshadow_ptd(t) ((t)->ptd[nkgkptd])
00094 #define xnshadow_thread(t) ((xnthread_t *)xnshadow_ptd(t))
00095
00096 #else
00097
00098 #include <sys/types.h>
00099
00100 #endif
00101
00102 typedef struct xncompletion {
00103
00104 long syncflag;
00105 pid_t pid;
00106
00107 } xncompletion_t;
00108
00109 #endif