Re: [PATCH V12 07/14] riscv: qspinlock: Add virt_spin_lock() support for VM guest

2024-01-03 Thread Leonardo Bras
On Mon, Dec 25, 2023 at 07:58:40AM -0500, guo...@kernel.org wrote: > From: Guo Ren > > Add a static key controlling whether virt_spin_lock() should be > called or not. When running on bare metal set the new key to > false. > > The VM guests should fall back to a Test-and-Set spinlock, > because

[PATCH V12 07/14] riscv: qspinlock: Add virt_spin_lock() support for VM guest

2023-12-25 Thread guoren
From: Guo Ren Add a static key controlling whether virt_spin_lock() should be called or not. When running on bare metal set the new key to false. The VM guests should fall back to a Test-and-Set spinlock, because fair locks have horrible lock 'holder' preemption issues. The virt_spin_lock_key wo