Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S262766AbUFFCLs (ORCPT ); Sat, 5 Jun 2004 22:11:48 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S262837AbUFFCLs (ORCPT ); Sat, 5 Jun 2004 22:11:48 -0400 Received: from ozlabs.org ([203.10.76.45]:60579 "EHLO ozlabs.org") by vger.kernel.org with ESMTP id S262766AbUFFCLq (ORCPT ); Sat, 5 Jun 2004 22:11:46 -0400 Subject: Re: [PATCH] speedup flush_workqueue for singlethread_workqueue From: Rusty Russell To: Andrew Morton Cc: anil.s.keshavamurthy@intel.com, lkml - Kernel Mailing List In-Reply-To: <20040604153018.00768aab.akpm@osdl.org> References: <20040604153018.00768aab.akpm@osdl.org> Content-Type: text/plain Message-Id: <1086487875.11456.23.camel@bach> Mime-Version: 1.0 X-Mailer: Ximian Evolution 1.4.6 Date: Sun, 06 Jun 2004 12:11:15 +1000 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 849 Lines: 22 On Sat, 2004-06-05 at 08:30, Andrew Morton wrote: > "Anil" wrote: > > > > In the flush_workqueue function for a single_threaded_worqueue case the code seemed to loop the same cpu_workqueue_struct > > for each_online_cpu's. The attached patch checks this condition and bails out of for loop there by speeding up the flush_workqueue > > for a singlethreaded_workqueue. > > > OK, thanks. I think it's a bit clearer to do it as below. I haven't > tested it though. Me neither, but agree. Rusty. -- Anyone who quotes me in their signature is an idiot -- Rusty Russell - 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/