Use sched_setparam(), not up_reprioritize_rtr()
git-svn-id: https://nuttx.svn.sourceforge.net/svnroot/nuttx/trunk@1586 7fd9a85b-ad96-42d3-883c-3090e2eb8679
This commit is contained in:
parent
68fd971848
commit
91f3f1249f
|
@ -177,11 +177,14 @@ int sem_wait(FAR sem_t *sem)
|
|||
* will occur during up_block_task() processing.
|
||||
*
|
||||
* NOTE that we have to restore base_priority because
|
||||
* up_reprioritize_rtr() should set both.
|
||||
* sched_setparam() should set both.
|
||||
*/
|
||||
|
||||
struct sched_param sparam;
|
||||
int base_priority = htcb->base_priority;
|
||||
up_reprioritize_rtr(htcb, rtcb->sched_priority);
|
||||
|
||||
sparam.sched_priority = rtcb->sched_priority;
|
||||
(void)sched_setparam(htcb->pid, &sparam);
|
||||
htcb->base_priority = base_priority;
|
||||
}
|
||||
#endif
|
||||
|
|
Loading…
Reference in New Issue