Skip to content

Commit

Permalink
os/pm: fix pm_sleep build error
Browse files Browse the repository at this point in the history
This commit resolve undefined reference to 'this_task' build error on pm_sleep.c with loadable_apps configuration without SMP.
  • Loading branch information
gSahitya-samsung authored and kishore-sn committed Jul 16, 2024
1 parent 2e284ac commit 8653efc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions os/pm/pm_sleep.c
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,8 @@
#include <tinyara/irq.h>
#include <tinyara/wdog.h>
#include <tinyara/clock.h>
#include <tinyara/sched.h>
#include <errno.h>

/************************************************************************
* Pre-processor Definitions
************************************************************************/
Expand Down Expand Up @@ -108,7 +108,7 @@ int pm_sleep(int milliseconds)
/* TODO - Since PM & Kernel are separate, we should not use tcb inside pm.
* We need to remove tcb in future.
*/
FAR struct tcb_s *rtcb = this_task();
FAR struct tcb_s *rtcb = sched_self();
/* initialize the timer's semaphore. It will be used to lock the
* thread before sleep and unlock after expire */
sem_init(&pm_sem, 0, 0);
Expand Down

0 comments on commit 8653efc

Please sign in to comment.