message: Fix pte_osSemaphorePend deadlock
diff: @@ -340,12 +340,13 @@ pub unsafe extern "C" fn pte_osSemaphorePend(
  ) -> pte_osResult {
  //TODO: pTimeout
  let semaphore = &mut *handle;
  - let mut acquired = false;
  - while !acquired {
  + loop {
  + {
  let _guard = semaphore.lock.lock();
  if intrinsics::atomic_load(&semaphore.count) > 0 {
  intrinsics::atomic_xsub(&mut semaphore.count, 1);
  - acquired = true;
  + break;
  + }
  }
  Sys::sched_yield();
  }
  