/shark/trunk/ports/first/include/cbsstar.h |
---|
21,11 → 21,11 |
/* |
------------ |
CVS : $Id: cbsstar.h,v 1.1 2003-09-10 15:56:28 giacomo Exp $ |
CVS : $Id: cbsstar.h,v 1.2 2003-10-07 10:49:54 giacomo Exp $ |
File: $File$ |
Revision: $Revision: 1.1 $ |
Last update: $Date: 2003-09-10 15:56:28 $ |
Revision: $Revision: 1.2 $ |
Last update: $Date: 2003-10-07 10:49:54 $ |
------------ |
This file contains the budget support for the multiapplication |
179,4 → 179,6 |
int CBSSTAR_get_local_scheduler_id_from_pid(LEVEL l, PID p); |
int CBSSTAR_get_last_reclaiming(LEVEL l); |
#endif |
/shark/trunk/ports/first/include/fsf_server.h |
---|
14,6 → 14,7 |
#define SERVER_get_local_scheduler_level_from_budget CBSSTAR_get_local_scheduler_level_from_budget |
#define SERVER_get_local_scheduler_level_from_pid CBSSTAR_get_local_scheduler_level_from_pid |
#define SERVER_getbudgetinfo CBSSTAR_getbudgetinfo |
#define SERVER_get_last_reclaiming CBSSTAR_get_last_reclaiming |
#endif |
28,6 → 29,7 |
#define SERVER_get_local_scheduler_level_from_budget GRUBSTAR_get_local_scheduler_level_from_budget |
#define SERVER_get_local_scheduler_level_from_pid GRUBSTAR_get_local_scheduler_level_from_pid |
#define SERVER_getbudgetinfo GRUBSTAR_getbudgetinfo |
#define SERVER_get_last_reclaiming GRUBSTAR_get_last_reclaiming |
#endif |
/shark/trunk/ports/first/include/edfstar.h |
---|
20,11 → 20,11 |
/** |
------------ |
CVS : $Id: edfstar.h,v 1.1 2003-09-10 15:56:28 giacomo Exp $ |
CVS : $Id: edfstar.h,v 1.2 2003-10-07 10:49:54 giacomo Exp $ |
File: $File$ |
Revision: $Revision: 1.1 $ |
Last update: $Date: 2003-09-10 15:56:28 $ |
Revision: $Revision: 1.2 $ |
Last update: $Date: 2003-10-07 10:49:54 $ |
------------ |
Title: |
140,6 → 140,7 |
int EDFSTAR_getbudget(LEVEL l, PID p); |
int EDFSTAR_setbudget(LEVEL l, PID p, int budget); |
int EDFSTAR_budget_has_thread(LEVEL l, int budget); |
#endif |
/shark/trunk/ports/first/modules/cbsstar.c |
---|
608,6 → 608,13 |
} |
int CBSSTAR_get_last_reclaiming(LEVEL l) |
{ |
return 0; |
} |
int CBSSTAR_is_active(LEVEL l, int budget) |
{ |
CBSSTAR_level_des *lev = (CBSSTAR_level_des *)(level_table[l]); |
/shark/trunk/ports/first/modules/grubstar.c |
---|
263,7 → 263,7 |
b->avail -= tx - lev->last_reclaiming; |
#ifdef GRUBSTAR_DEBUG |
kern_printf("(GS:Cap p%d av=%d Uf=%u U=%u, tx=%d)", p, b->avail,lev->Uf, lev->U,tx); |
kern_printf("(GS:Cap p%d av=%d Uf=%u U=%u, tx=%d)", p, b->avail,lev->Uf, lev->U,(int)tx); |
#endif |
if (b->avail <= 0) b->flags = GRUBSTAR_NOACTIVE; |
/shark/trunk/ports/first/first-server.c |
---|
195,6 → 195,18 |
case FSF_SCHEDULER_RM: |
hard_task_def_arg(*(HARD_TASK_MODEL *)(local_scheduler_arg),arg); |
hard_task_def_level(*(HARD_TASK_MODEL *)(local_scheduler_arg),local_scheduler_level); |
*thread = task_create("RMSTAR", thread_code, local_scheduler_arg, NULL); |
if (*thread == NIL) |
return FSF_ERR_CREATE_THREAD; |
RMSTAR_setbudget(local_scheduler_level, *thread, (int)(server)); |
task_activate(*thread); |
break; |
default: |
return FSF_ERR_INVALID_SERVER; |
break; |