lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <tip-de7689cf8f3820b34088da3b22ce1a548dda2fc5@git.kernel.org>
Date:   Tue, 22 Nov 2016 04:35:13 -0800
From:   tip-bot for Juergen Gross <tipbot@...or.com>
To:     linux-tip-commits@...r.kernel.org
Cc:     jgross@...e.com, tglx@...utronix.de, hpa@...or.com,
        linux-kernel@...r.kernel.org, xinhui.pan@...ux.vnet.ibm.com,
        mingo@...nel.org, peterz@...radead.org,
        torvalds@...ux-foundation.org
Subject: [tip:locking/core] x86/xen: Support the vCPU preemption check

Commit-ID:  de7689cf8f3820b34088da3b22ce1a548dda2fc5
Gitweb:     http://git.kernel.org/tip/de7689cf8f3820b34088da3b22ce1a548dda2fc5
Author:     Juergen Gross <jgross@...e.com>
AuthorDate: Wed, 2 Nov 2016 05:08:37 -0400
Committer:  Ingo Molnar <mingo@...nel.org>
CommitDate: Tue, 22 Nov 2016 12:48:09 +0100

x86/xen: Support the vCPU preemption check

Support the vcpu_is_preempted() functionality under Xen. This will
enhance lock performance on overcommitted hosts (more runnable vCPUs
than physical CPUs in the system) as doing busy waits for preempted
vCPUs will hurt system performance far worse than early yielding.

A quick test (4 vCPUs on 1 physical CPU doing a parallel build job
with "make -j 8") reduced system time by about 5% with this patch.

Signed-off-by: Juergen Gross <jgross@...e.com>
Signed-off-by: Pan Xinhui <xinhui.pan@...ux.vnet.ibm.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@...radead.org>
Cc: David.Laight@...LAB.COM
Cc: Linus Torvalds <torvalds@...ux-foundation.org>
Cc: Peter Zijlstra <peterz@...radead.org>
Cc: Thomas Gleixner <tglx@...utronix.de>
Cc: benh@...nel.crashing.org
Cc: boqun.feng@...il.com
Cc: borntraeger@...ibm.com
Cc: bsingharora@...il.com
Cc: dave@...olabs.net
Cc: kernellwp@...il.com
Cc: konrad.wilk@...cle.com
Cc: linuxppc-dev@...ts.ozlabs.org
Cc: mpe@...erman.id.au
Cc: paulmck@...ux.vnet.ibm.com
Cc: paulus@...ba.org
Cc: pbonzini@...hat.com
Cc: rkrcmar@...hat.com
Cc: virtualization@...ts.linux-foundation.org
Cc: will.deacon@....com
Cc: xen-devel-request@...ts.xenproject.org
Cc: xen-devel@...ts.xenproject.org
Link: http://lkml.kernel.org/r/1478077718-37424-11-git-send-email-xinhui.pan@linux.vnet.ibm.com
Signed-off-by: Ingo Molnar <mingo@...nel.org>
---
 arch/x86/xen/spinlock.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/arch/x86/xen/spinlock.c b/arch/x86/xen/spinlock.c
index 3d6e006..74756bb 100644
--- a/arch/x86/xen/spinlock.c
+++ b/arch/x86/xen/spinlock.c
@@ -114,7 +114,6 @@ void xen_uninit_lock_cpu(int cpu)
 	per_cpu(irq_name, cpu) = NULL;
 }
 
-
 /*
  * Our init of PV spinlocks is split in two init functions due to us
  * using paravirt patching and jump labels patching and having to do
@@ -137,6 +136,8 @@ void __init xen_init_spinlocks(void)
 	pv_lock_ops.queued_spin_unlock = PV_CALLEE_SAVE(__pv_queued_spin_unlock);
 	pv_lock_ops.wait = xen_qlock_wait;
 	pv_lock_ops.kick = xen_qlock_kick;
+
+	pv_lock_ops.vcpu_is_preempted = xen_vcpu_stolen;
 }
 
 /*

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ