cobalt/process: Fix incomplete backport of __handle_taskexit_event change
PATCH 1/1 cobalt/process: Fix incomplete backport of __handle_taskexit_event change
From: Jan Kiszka <[email protected]>
Commit f7d83e55135c which tried to backport commit 393ece85166a from master missed that there is no interrupt protection via xnlock_get_irqsave in 3.0. But we need in order to protect xnsched_run when running over the secondary domain as we always do here. In fact, xnsched_run will complain via a warning about this.
Signed-off-by Jan Kiszka <[email protected]>
--- kernel/cobalt/posix/process.c | 3 +++ 1 file changed, 3 insertions(+)
kernel/cobalt/posix/process.c +3 -0
@@ -1041,6 +1041,7 @@ static void __handle_taskexit_event(struct task_struct *p) {struct cobalt_ppd *sys_ppd;struct xnthread *thread; +spl_t s;/* * We are called for both kernel and user shadows over the
@@ -1055,7 +1056,9 @@ static void __handle_taskexit_event(struct task_struct *p)if (xnthread_test_state (thread,XNSSTEP ))unregister_debugged_thread (thread); +splhigh (s);xnsched_run (); +splexit (s);xnthread_run_handler_stack (thread, exit_thread);
Signature · 6 lines
2.16.4 -- Siemens AG, Corporate Technology, CT RDA IOT SES-DE Corporate Competence Center Embedded Linux