Xenomai API
2.5.6.1
|
00001 00023 #ifndef _XENO_NUCLEUS_SCHED_SPORADIC_H 00024 #define _XENO_NUCLEUS_SCHED_SPORADIC_H 00025 00026 #ifndef _XENO_NUCLEUS_SCHED_H 00027 #error "please don't include nucleus/sched-sporadic.h directly" 00028 #endif 00029 00030 #ifdef CONFIG_XENO_OPT_SCHED_SPORADIC 00031 00032 #include <nucleus/heap.h> 00033 00034 extern struct xnsched_class xnsched_class_sporadic; 00035 00036 struct xnsched_sporadic_repl { 00037 xntime_t date; 00038 xntime_t amount; 00039 }; 00040 00041 struct xnsched_sporadic_data { 00042 xnticks_t resume_date; 00043 xnticks_t budget; 00044 int repl_in; 00045 int repl_out; 00046 int repl_pending; 00047 struct xntimer repl_timer; 00048 struct xntimer drop_timer; 00049 struct xnsched_sporadic_repl repl_data[CONFIG_XENO_OPT_SCHED_SPORADIC_MAXREPL]; 00050 struct xnsched_sporadic_param param; 00051 struct xnthread *thread; 00052 }; 00053 00054 struct xnsched_sporadic { 00055 #if XENO_DEBUG(NUCLEUS) 00056 unsigned long drop_retries; 00057 #endif 00058 }; 00059 00060 static inline int xnsched_sporadic_init_tcb(struct xnthread *thread) 00061 { 00062 thread->pss = NULL; 00063 00064 return 0; 00065 } 00066 00067 #endif /* !CONFIG_XENO_OPT_SCHED_SPORADIC */ 00068 00069 #endif /* !_XENO_NUCLEUS_SCHED_SPORADIC_H */