Skip to content

Commit

Permalink
Merge pull request #131 from maiabozaid/master
Browse files Browse the repository at this point in the history
making the idle function efficient by using WFE instead empty while
  • Loading branch information
jlbirccyn authored Sep 5, 2023
2 parents 31966c9 + 921a622 commit 3f2cafc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion machines/cortex/tpl_machine_cortex.c
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,10 @@ FUNC(uint8, OS_CODE) tpl_check_stack_footprint(CONST(tpl_proc_id, OS_APPL_DATA)
*/
void idle_function(void)
{
while(1);
while(1)
{
__WFE();
}
}

void tpl_init_machine()
Expand Down

0 comments on commit 3f2cafc

Please sign in to comment.