mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-10-01 22:37:14 +00:00
It's possible that the up_count_spinlock is not release during system enter S3. The case is like following: BSP AP stop_cpus cpu_dead cpu_set_current_state spinlock_abtain up_count-- wait_for up_count == 1 enter S3 spinlock_release Especially, considering the real spinlock release could be delayed by cache. Actually, the most content protected by up_count_spinlock is per cpu data and could be changed without lock. Only left is up_count. This patchset remove the up_count_spinlock and use atomic API for up_count changing. Tracked-On: #1691 Signed-off-by: Yin Fengwei <fengwei.yin@intel.com> Reviewed-by: Eddie Dong <eddie.dong@intel.com> Acked-by: Anthony Xu <anthony.xu@intel.com>