quoted hunk ↗ jump to hunk
@@ -405,8 +405,10 @@ void klp_try_complete_transition(void)
for_each_possible_cpu(cpu) {
task = idle_task(cpu);
if (cpu_online(cpu)) {
- if (!klp_try_switch_task(task))
- complete = false;
+ int ret = klp_try_switch_task(task);
+ if (ret == -EBUSY)
+ wake_up_if_idle(cpu);
+ complete = !ret;
This is broken. You can basically change "complete" only to false (when it
applies). This could leave some tasks in the old patching state.
Anyway, I like the patch set a lot. It moves our infrastructure to a
proper (I hope so) API and it removes few quirks we have along the way.
I'll play with it some more.
Thanks
Miroslav