Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752766AbZKPShj (ORCPT ); Mon, 16 Nov 2009 13:37:39 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752177AbZKPShj (ORCPT ); Mon, 16 Nov 2009 13:37:39 -0500 Received: from acsinet11.oracle.com ([141.146.126.233]:48571 "EHLO acsinet11.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751024AbZKPShh (ORCPT ); Mon, 16 Nov 2009 13:37:37 -0500 Date: Mon, 16 Nov 2009 13:36:13 -0500 From: Chris Mason To: Milan Broz Cc: Mel Gorman , Andrew Morton , Frans Pop , Jiri Kosina , Sven Geggus , Karol Lewandowski , Tobias Oetiker , linux-kernel@vger.kernel.org, "linux-mm@kvack.org" , KOSAKI Motohiro , Pekka Enberg , Rik van Riel , Christoph Lameter , Stephan von Krawczynski , "Rafael J. Wysocki" , Kernel Testers List , device-mapper development , Alasdair G Kergon Subject: Re: [PATCH 0/7] Reduce GFP_ATOMIC allocation failures, candidate fix V3 Message-ID: <20091116183613.GG27677@think> Mail-Followup-To: Chris Mason , Milan Broz , Mel Gorman , Andrew Morton , Frans Pop , Jiri Kosina , Sven Geggus , Karol Lewandowski , Tobias Oetiker , linux-kernel@vger.kernel.org, "linux-mm@kvack.org" , KOSAKI Motohiro , Pekka Enberg , Rik van Riel , Christoph Lameter , Stephan von Krawczynski , "Rafael J. Wysocki" , Kernel Testers List , device-mapper development , Alasdair G Kergon References: <1258054211-2854-1-git-send-email-mel@csn.ul.ie> <20091112202748.GC2811@think> <20091112220005.GD2811@think> <20091113024642.GA7771@think> <4B018157.3080707@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <4B018157.3080707@redhat.com> User-Agent: Mutt/1.5.20 (2009-06-14) X-Source-IP: acsmt354.oracle.com [141.146.40.154] X-Auth-Type: Internal IP X-CT-RefId: str=0001.0A090201.4B019BA3.00BC:SCFMA4539814,ss=1,fgs=0 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1924 Lines: 44 On Mon, Nov 16, 2009 at 05:44:07PM +0100, Milan Broz wrote: > On 11/13/2009 03:46 AM, Chris Mason wrote: > > On Thu, Nov 12, 2009 at 05:00:05PM -0500, Chris Mason wrote: > > > > [ ...] > > > >> > >> The punch line is that the btrfs guy thinks we can solve all of this with > >> just one more thread. If we change dm-crypt to have a thread dedicated > >> to sync IO and a thread dedicated to async IO the system should smooth > >> out. > > Please, can you cc DM maintainers with these kind of patches? dm-devel list at least. > Well, my current patch is a hack. If I had come up with a proven theory (hopefully Mel can prove it ;), it definitely would have gone through the dm-devel lists. > Note that the crypt requests can be already processed synchronously or asynchronously, > depending on used crypto module (async it is in the case of some hw acceleration). > > Adding another queue make the situation more complicated and because the crypt > requests can be queued in crypto layer I am not sure that this solution will help > in this situation at all. > (Try to run that with AES-NI acceleration for example.) The problem is that async threads still imply a kind of ordering. If there's a fifo serviced by one thread or 10, the latency ramifications are very similar for a new entry on the list. We have to wait for a large portion of the low-prio items in order to service a high prio item. With a queue dedicated to sync requests and one dedicated to async, you'll get better read latencies. Btrfs has a similar problem around the crc helper threads and it ends up solving things with two different lists (high and low prio) processed by one thread. -chris -- 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/