Mercurial > hg > Game > Cerium
diff TaskManager/kernel/schedule/SchedTaskList.cc @ 704:ec6c897448ca draft
Compatibility mode works.
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Mon, 14 Dec 2009 19:54:00 +0900 |
parents | 77c89477daa8 |
children | d41c62201b1e |
line wrap: on
line diff
--- a/TaskManager/kernel/schedule/SchedTaskList.cc Mon Dec 14 18:34:46 2009 +0900 +++ b/TaskManager/kernel/schedule/SchedTaskList.cc Mon Dec 14 19:54:00 2009 +0900 @@ -2,6 +2,9 @@ #include <string.h> #include "SchedTaskList.h" #include "SchedTask.h" +#include "SysFunc.h" +#include "SchedTaskArray.h" +#include "SchedTaskArrayLoad.h" #include "SchedNop2Ready.h" #include "DmaManager.h" #include "error.h" @@ -58,8 +61,17 @@ TaskPtr nextTask = &list->tasks[0]; #endif nextSched = createSchedTask(scheduler, nextTask); - ((SchedTask*)nextSched)->init(list, nextTask, 1, - scheduler); + ((SchedTask*)nextSched)->init(list, nextTask, 1, scheduler); +#ifdef SIMPLE_TASK + if (nextTask->command==TaskArray1) { + // compatibility + return new SchedTaskArray(scheduler, nextSched); + } + if (nextTask->command==TaskArray) { + // Start Task Array + return (SchedTaskBase*)(new SchedTaskArrayLoad(scheduler, nextSched)); + } +#endif } return nextSched;