Skip to contentSkip to conversation

For 2.6 xenomai, where is scheduler spot for realtime world and linux world?

Xenomai 曹子龙 1 participant 1 message Mar 6, 2017

lore
Share & tools
lore

曹子龙

author
#0 lore raw

HI:
thanks for your kindly reply and please regret me if my question seems foolish for this is my first questions.

for 2.6 xenomai, i know the system is divided into two worlds, the primary(rt) world and the secondary(linux) world, so may be there is a door like space-time traveler in science fiction movie. i mean maybe a c code line (or maybe assemble instuctions) that divided the two world in the source code, so, if this is true, where is the spot?

and i found a place in gatekeeper_thread, is this line? i mean, if some rt-thread is ready, the schedule call would not return and system goes to rt world,

but when no rt thread being ready, the the "xpod_schedule" call in rt domain would return back to the schedule of linux world? (precisely is "context_swich" inline assembly, because schedule call it), am i right?

thanks for your kindly reply again.

static int gatekeeper_thread(void *data)
857 {
858 struct task_struct *this_task = current;

 859         int cpu = (long)data;
               ........................
              ...........................          

874 for (;;) {
875 up(&sched->gksync); /* Make the request token available. */
876 schedule();
877 ............................