From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Zijlstra Subject: Re: [PATCH 11/13] x86/ticketlock: only do kick after doing unlock Date: Fri, 02 Sep 2011 16:49:28 +0200 Message-ID: <1314974968.1861.3.camel@twins> References: <8cd2c77886e2d3fcad8258aa62509b3b2fae5545.1314922370.git.jeremy.fitzhardinge@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 8BIT Return-path: In-Reply-To: <8cd2c77886e2d3fcad8258aa62509b3b2fae5545.1314922370.git.jeremy.fitzhardinge@citrix.com> Sender: kvm-owner@vger.kernel.org To: Jeremy Fitzhardinge Cc: "H. Peter Anvin" , Linus Torvalds , Ingo Molnar , the arch/x86 maintainers , Linux Kernel Mailing List , Nick Piggin , Avi Kivity , Marcelo Tosatti , KVM , Andi Kleen , Xen Devel , Srivatsa Vaddagiri , Jeremy Fitzhardinge List-Id: xen-devel@lists.xenproject.org On Thu, 2011-09-01 at 17:55 -0700, Jeremy Fitzhardinge wrote: > From: Srivatsa Vaddagiri > > We must release the lock before checking to see if the lock is in > slowpath or else there's a potential race where the lock enters the > slow path after the unlocker has checked the slowpath flag, but before > it has actually unlocked. > > Signed-off-by: Srivatsa Vaddagiri > Signed-off-by: Jeremy Fitzhardinge Wouldn't it be much better to fold it back so that this bug never happens when you bisect?