Re: [PATCH -v5 5/5] x86,smp: limit spinlock delay on virtual machines

2013-02-07 Thread Rik van Riel
On 02/07/2013 06:25 AM, Stefano Stabellini wrote: On Wed, 6 Feb 2013, Rik van Riel wrote: Modern Intel and AMD CPUs will trap to the host when the guest is spinning on a spinlock, allowing the host to schedule in something else. This effectively means the host is taking care of spinlock backoff

Re: [PATCH -v5 5/5] x86,smp: limit spinlock delay on virtual machines

2013-02-07 Thread Raghavendra K T
On 02/07/2013 04:55 PM, Stefano Stabellini wrote: On Wed, 6 Feb 2013, Rik van Riel wrote: Modern Intel and AMD CPUs will trap to the host when the guest is spinning on a spinlock, allowing the host to schedule in something else. This effectively means the host is taking care of spinlock backoff

Re: [PATCH -v5 5/5] x86,smp: limit spinlock delay on virtual machines

2013-02-07 Thread Stefano Stabellini
On Wed, 6 Feb 2013, Rik van Riel wrote: > Modern Intel and AMD CPUs will trap to the host when the guest > is spinning on a spinlock, allowing the host to schedule in > something else. > > This effectively means the host is taking care of spinlock > backoff for virtual machines. It also means that

Re: [PATCH -v5 5/5] x86,smp: limit spinlock delay on virtual machines

2013-02-07 Thread Ingo Molnar
* Rik van Riel wrote: > --- a/arch/x86/kernel/cpu/hypervisor.c > +++ b/arch/x86/kernel/cpu/hypervisor.c > @@ -76,6 +76,8 @@ void __init init_hypervisor_platform(void) > > init_hypervisor(&boot_cpu_data); > > + init_guest_spinlock_delay(); > + > if (x86_hyper->init_platform) >

[PATCH -v5 5/5] x86,smp: limit spinlock delay on virtual machines

2013-02-06 Thread Rik van Riel
Modern Intel and AMD CPUs will trap to the host when the guest is spinning on a spinlock, allowing the host to schedule in something else. This effectively means the host is taking care of spinlock backoff for virtual machines. It also means that doing the spinlock backoff in the guest anyway can