Forum Discussion
Altera_Forum
Honored Contributor
21 years agoscheduling policy
We're running uClinux based on linux version 2.6.x under the Nios II IDE v1.0.0 build 393. In experimenting with POSIX threads, I've been attempting to activate timeslicing for an app...
Altera_Forum
Honored Contributor
21 years ago<div class='quotetop'>QUOTE </div>
--- Quote Start --- Apparently, one needs to pass the root process ID of 0 in order to change the policy. Whatever, a subsequent call to sched_getparam passing it the calling process returns the changed schedule policy value, and a subsequent sched_setparam call with getpid() also works[/b] --- Quote End --- Here 0 means current calling process instead of root process. <div class='quotetop'>QUOTE </div> --- Quote Start --- ...so linux is not preempting the first thread to run the second, and so on, which indicates to me that the scheduling policy change didn't work[/b] --- Quote End --- why do you expect the second to preempt the first one? All the five thread you have are of the same scheduler policy and the same priority.