Subversion Repositories shark

Compare Revisions

Ignore whitespace Rev 799 → Rev 798

/shark/trunk/ports/first/modules/edfstar.c
188,7 → 188,6
EDFSTAR_level_des *lev;
 
lev = (EDFSTAR_level_des *)level_table[proc_table[p].task_level];
lev->deadline_timer[p] = NIL;
 
switch (proc_table[p].status) {
case EDFSTAR_IDLE:
379,13 → 378,13
if (proc_table[p].status != SLEEP) {
/* a periodic task cannot be activated when it is already active */
/* but aperiodic task can be reactivate before */
if (proc_table[p].status != EDFSTAR_IDLE) {
if (lev->flag[p] & EDFSTAR_FLAG_SPORADIC) {
if (lev->flag[p] & EDFSTAR_FLAG_SPORADIC) {
if (proc_table[p].status != EDFSTAR_IDLE) {
lev->nact[p]++;
return;
} else {
kern_raise(XACTIVATION,p);
}
}
} else {
kern_raise(XACTIVATION,p);
}
}
 
480,7 → 479,6
/* count the deadline miss */
lev->dline_miss[p]++;
kern_event_delete(lev->deadline_timer[p]);
lev->deadline_timer[p] = NIL;
}
 
} else {
490,15 → 488,10
#endif
/* the task has terminated his job before it consume the wcet. All OK! */
if (lev->flag[p] & EDFSTAR_FLAG_SPORADIC)
proc_table[p].status = SLEEP;
else
proc_table[p].status = EDFSTAR_IDLE;
proc_table[p].status = EDFSTAR_IDLE;
if (lev->flag[p] & EDFSTAR_FLAG_SPORADIC && lev->deadline_timer[p] != NIL) {
if (lev->flag[p] & EDFSTAR_FLAG_SPORADIC && lev->deadline_timer[p] != NIL)
kern_event_delete(lev->deadline_timer[p]);
lev->deadline_timer[p] = NIL;
}
/* and finally, a preemption check! */
EDFSTAR_check_preemption(lev);
541,7 → 534,6
if (lev->deadline_timer[p] != -1) {
kern_event_delete(lev->deadline_timer[p]);
lev->deadline_timer[p] = NIL;
}
 
/* and finally, a preemption check! (it will also call guest_end) */