Hi,

we started an application which monitors task switches
using Xenomai 2.5.3.

For monitoring primary domain switches we hooked
in our code by using rt_task_add_hook(T_HOOK_SWITCH)
(storing a timestamp and the Xenomai task ID in an array,
which is read later by user space appl from shared memory).

It seems, that our code is not called when Xenomai switches to the ROOT task.

We already had this issue with Xenomai 2.4.10
and solved it by applying the attached patch.

How can we catch these Xenomai scheduler events in 2.5.3?

What is the reason for filtering them out?

Best regards,

        Olli
Index: xenomai-2.4.10/ksrc/nucleus/pod.c
===================================================================
--- xenomai-2.4.10.orig/ksrc/nucleus/pod.c	2009-08-11 15:53:55.000000000 +0200
+++ xenomai-2.4.10/ksrc/nucleus/pod.c	2010-01-27 12:41:05.000000000 +0100
@@ -2561,7 +2561,7 @@
 		nkpod->schedhook(runthread, XNRUNNING);
 #endif /* __XENO_SIM__ */
 
-	if (!emptyq_p(&nkpod->tswitchq) && !xnthread_test_state(runthread, XNROOT)) {
+	if (!emptyq_p(&nkpod->tswitchq)) {
 		trace_mark(xn_nucleus, thread_callout,
 			   "thread %p thread_name %s hook %s",
 			   runthread, xnthread_name(runthread), "SWITCH");
_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to