How to schedule a node on a different processor?

Gedare Bloom gedare at rtems.org
Tue Aug 18 16:10:44 UTC 2020


On Tue, Aug 18, 2020 at 9:21 AM Richi Dubey <richidubey at gmail.com> wrote:
>
> Hi,
>
> This question is wrt the use of Scheduler_SMP_Preempt here. This function eventually calls Allocate_Processor and while tracing with gdb, everything is going as I planned, i.e. the correct node is getting preempted and the caller to it is getting allocated the CPU. But, the test fails here, because eventually the heir is not changed.
>
> Do I have to explicitly change the heir when I am trying to schedule a node/thread on a different processor? Is doing SMP_Preempt not enough? Please suggest.
>
The heir should get set (in SMP scheduling) by call to
_Thread_Dispatch_update_heir() from Allocate_Processor. Probably you
need to look at your allocate_processor hook.

> Thanks,
> Richi.
>
> _______________________________________________
> devel mailing list
> devel at rtems.org
> http://lists.rtems.org/mailman/listinfo/devel


More information about the devel mailing list