Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754423AbaG2VyF (ORCPT ); Tue, 29 Jul 2014 17:54:05 -0400 Received: from mail-wg0-f46.google.com ([74.125.82.46]:33886 "EHLO mail-wg0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754405AbaG2VyE (ORCPT ); Tue, 29 Jul 2014 17:54:04 -0400 Date: Tue, 29 Jul 2014 23:54:00 +0200 From: Frederic Weisbecker To: Peter Zijlstra Cc: LKML , Ingo Molnar , Nicolas Pitre , "Paul E. McKenney" , Steven Rostedt , Thomas Gleixner , Viresh Kumar Subject: Re: [PATCH 05/10] smp: Fast path check on IPI list Message-ID: <20140729215359.GB14520@localhost.localdomain> References: <1406569056-30217-1-git-send-email-fweisbec@gmail.com> <1406569056-30217-6-git-send-email-fweisbec@gmail.com> <20140729120739.GX3935@laptop> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20140729120739.GX3935@laptop> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jul 29, 2014 at 02:07:39PM +0200, Peter Zijlstra wrote: > On Mon, Jul 28, 2014 at 07:37:31PM +0200, Frederic Weisbecker wrote: > > When we enqueue a remote irq work, we trigger the same IPI as those > > raised by smp_call_function_*() family. > > > > So when we receive such IPI, we check both irq_work and smp_call_function > > queues. Thus if we trigger a remote irq work, we'll likely find the > > smp_call_function queue empty unless we collide with concurrent enqueuers > > but the probability is low. > > > > Meanwhile, checking the smp_call_function queue can be costly because > > we use llist_del_all() which relies on cmpxchg(). > > xchg() Ah, right! -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/