Skip to content

Commit

Permalink
use best_effort_wfe_or_timeout instead of wfe (#1404)
Browse files Browse the repository at this point in the history
  • Loading branch information
kilograham authored Jul 7, 2024
1 parent 778221b commit 74b9ea4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/rp2_common/pico_multicore/multicore.c
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,7 @@ bool multicore_fifo_pop_timeout_us(uint64_t timeout_us, uint32_t *out) {
// If nothing there yet, we wait for an event first,
// to try and avoid too much busy waiting
while (!multicore_fifo_rvalid()) {
__wfe();
if (time_reached(end_time)) return false;
if (best_effort_wfe_or_timeout(end_time)) return false;
}

*out = sio_hw->fifo_rd;
Expand Down

0 comments on commit 74b9ea4

Please sign in to comment.