diff options
author | Stephen Tang <sytang@pound.cs.unc.edu> | 2017-04-03 16:06:55 -0400 |
---|---|---|
committer | Stephen Tang <sytang@pound.cs.unc.edu> | 2017-04-03 16:06:55 -0400 |
commit | 30717dcd6cc52d75fe6f25c00dfeaa41f501be7a (patch) | |
tree | cbfe4649fdb7ce3e51745169e3f2d19fd33c12d0 | |
parent | cae5ba2badcf13937b83564a5ab2231cc554b42c (diff) |
Trying to push to repository again
-rw-r--r-- | arch/arm/include/asm/unistd.h | 2 | ||||
-rw-r--r-- | include/litmus/rt_param.h | 3 | ||||
-rw-r--r-- | litmus/sched_mc2.c | 8 |
3 files changed, 6 insertions, 7 deletions
diff --git a/arch/arm/include/asm/unistd.h b/arch/arm/include/asm/unistd.h index 5291b703ed3f..e6cb57406270 100644 --- a/arch/arm/include/asm/unistd.h +++ b/arch/arm/include/asm/unistd.h | |||
@@ -19,7 +19,7 @@ | |||
19 | * This may need to be greater than __NR_last_syscall+1 in order to | 19 | * This may need to be greater than __NR_last_syscall+1 in order to |
20 | * account for the padding in the syscall table | 20 | * account for the padding in the syscall table |
21 | */ | 21 | */ |
22 | #define __NR_syscalls (388 + NR_litmus_syscalls + 0) | 22 | #define __NR_syscalls (392 + NR_litmus_syscalls + 0) |
23 | 23 | ||
24 | 24 | ||
25 | /* | 25 | /* |
diff --git a/include/litmus/rt_param.h b/include/litmus/rt_param.h index 18b9df47fb9d..468182ecde8e 100644 --- a/include/litmus/rt_param.h +++ b/include/litmus/rt_param.h | |||
@@ -121,9 +121,6 @@ struct reservation_config { | |||
121 | 121 | ||
122 | //Need to inform which mode reservation belongs to in mc2 | 122 | //Need to inform which mode reservation belongs to in mc2 |
123 | int mode; | 123 | int mode; |
124 | //convenient to have a line to the owning task for a | ||
125 | //reservation | ||
126 | struct task_struct *tsk; | ||
127 | }; | 124 | }; |
128 | 125 | ||
129 | /* regular sporadic task support */ | 126 | /* regular sporadic task support */ |
diff --git a/litmus/sched_mc2.c b/litmus/sched_mc2.c index 31d3019d9fce..ee04315c44a0 100644 --- a/litmus/sched_mc2.c +++ b/litmus/sched_mc2.c | |||
@@ -131,8 +131,10 @@ asmlinkage int sys_enact_mode(void) | |||
131 | && !res_reported){ //and C is throttled | 131 | && !res_reported){ //and C is throttled |
132 | mode = requested_mode; | 132 | mode = requested_mode; |
133 | _global_env = &_global_env_modes[mode]; | 133 | _global_env = &_global_env_modes[mode]; |
134 | //set res->reported for new global tasks | ||
134 | list_for_each(pos, &_global_env->active_reservations){ | 135 | list_for_each(pos, &_global_env->active_reservations){ |
135 | res = list_entry(pos, struct reservation, list); | 136 | res = list_entry(pos, struct reservation, list); |
137 | |||
136 | res->reported = 0; | 138 | res->reported = 0; |
137 | } | 139 | } |
138 | list_for_each(pos, &_global_env->depleted_reservations){ | 140 | list_for_each(pos, &_global_env->depleted_reservations){ |
@@ -142,6 +144,7 @@ asmlinkage int sys_enact_mode(void) | |||
142 | list_for_each(pos, &_global_env->inactive_reservations){ | 144 | list_for_each(pos, &_global_env->inactive_reservations){ |
143 | res = list_entry(pos, struct reservation, list); | 145 | res = list_entry(pos, struct reservation, list); |
144 | res->reported = 0; | 146 | res->reported = 0; |
147 | res->env->change_state(res->env, res, RESERVATION_ACTIVE); | ||
145 | } | 148 | } |
146 | //gmp_update_time(_global_env, now); | 149 | //gmp_update_time(_global_env, now); |
147 | } | 150 | } |
@@ -1609,7 +1612,7 @@ static long create_polling_reservation( | |||
1609 | 1612 | ||
1610 | 1613 | ||
1611 | pres->res.reported = 0; | 1614 | pres->res.reported = 0; |
1612 | pres->res.tsk = config->tsk; | 1615 | pres->res.tsk = current; |
1613 | 1616 | ||
1614 | if (err < 0) | 1617 | if (err < 0) |
1615 | kfree(pres); | 1618 | kfree(pres); |
@@ -1726,7 +1729,7 @@ static long create_table_driven_reservation( | |||
1726 | } | 1729 | } |
1727 | 1730 | ||
1728 | td_res->res.reported = 0; | 1731 | td_res->res.reported = 0; |
1729 | td_res->res.tsk = config->tsk; | 1732 | td_res->res.tsk = current; |
1730 | 1733 | ||
1731 | if (err < 0) { | 1734 | if (err < 0) { |
1732 | kfree(slots); | 1735 | kfree(slots); |
@@ -1858,7 +1861,6 @@ static long mc2_activate_plugin(void) | |||
1858 | 1861 | ||
1859 | mode = 0; | 1862 | mode = 0; |
1860 | requested_mode = 0; | 1863 | requested_mode = 0; |
1861 | raw_spinlock_t mode_lock; | ||
1862 | 1864 | ||
1863 | for(i = 0; i < NR_MODES; i++){ | 1865 | for(i = 0; i < NR_MODES; i++){ |
1864 | mode_sizes[i] = 0; | 1866 | mode_sizes[i] = 0; |