Subversion Repositories shark

Compare Revisions

Ignore whitespace Rev 828 → Rev 829

/shark/trunk/ports/first/modules/grubstar.c
773,12 → 773,11
int GRUBSTAR_get_remain_capacity(LEVEL l, int budget)
{
struct timespec actual,ty;
TIME tx;
int tx;
GRUBSTAR_level_des *lev = (GRUBSTAR_level_des *)(level_table[l]);
kern_gettime(&actual);
SUBTIMESPEC(&actual, &lev->cap_lasttime, &ty);
SUBTIMESPEC(&actual, &schedule_time, &ty);
tx = TIMESPEC2USEC(&ty);
 
// the remain capacity is from the first dispatch so is less then
// actual capacity
return (lev->b[budget].avail-tx);
833,7 → 832,7
/* force a hard reservation event */
avail_budget=lev->b[lev->tb[exec]].avail;
lev->b[lev->tb[exec]].flags = GRUBSTAR_NOACTIVE;
 
//kern_printf("(GS DS %d)", exec);
/* save the unused capacity */
spare=avail_budget+lev->b[lev->tb[exec]].avail;
if (spare<=0) spare=0;