12,7 → 12,7 |
extern int total_loader_task; |
extern int total_loader_contract; |
|
mutex_t mutex_table[MAX_MUTEX]; |
mutex_object mutex_table[MAX_MUTEX]; |
int main_chunk; |
|
/* Runtime Calibration */ |
169,14 → 169,12 |
/* Set the zero_time and post the first activation event */ |
void start_simulation() { |
|
int i; |
int i, object; |
struct loader_task *l = loader_task_list; |
struct timespec end_time; |
PI_mutexattr_t a; |
|
PI_mutexattr_default(a); |
|
i = 0; |
object = 0; |
|
#ifdef __NEW_TRACER__ |
|
195,7 → 193,13 |
while (i < total_loader_task) { |
|
if (l->muxstatus == 1) { |
mutex_init(&mutex_table[l->resource],&a); |
fsf_init_shared_object(&(mutex_table[l->resource]).object,object); |
mutex_table[l->resource].operation.op_id=1; |
mutex_table[l->resource].operation.wcet.tv_sec=l->block[i].tv_sec; |
mutex_table[l->resource].operation.wcet.tv_nsec=l->block[i].tv_nsec; |
fsf_declare_shared_object_operation(&mutex_table[l->resource].object, |
&mutex_table[l->resource].object); |
|
l->muxstatus = 2; |
} |
|