From mboxrd@z Thu Jan 1 00:00:00 1970 From: Peter Zijlstra Subject: Re: RFC: get_user_pages_locked|unlocked to leverage VM_FAULT_RETRY Date: Thu, 2 Oct 2014 14:50:52 +0200 Message-ID: <20141002125052.GF2849@worktop.programming.kicks-ass.net> References: <20140926172535.GC4590@redhat.com> <20141001153611.GC2843@worktop.programming.kicks-ass.net> <20141002123117.GB2342@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Andres Lagar-Cavilla , Gleb Natapov , Radim Krcmar , Paolo Bonzini , Rik van Riel , Mel Gorman , Andy Lutomirski , Andrew Morton , Sasha Levin , Jianyu Zhan , Paul Cassella , Hugh Dickins , Peter Feiner , kvm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, "Dr. David Alan Gilbert" To: Andrea Arcangeli Return-path: Content-Disposition: inline In-Reply-To: <20141002123117.GB2342@redhat.com> Sender: owner-linux-mm@kvack.org List-Id: kvm.vger.kernel.org On Thu, Oct 02, 2014 at 02:31:17PM +0200, Andrea Arcangeli wrote: > On Wed, Oct 01, 2014 at 05:36:11PM +0200, Peter Zijlstra wrote: > > For all these and the other _fast() users, is there an actual limit to > > the nr_pages passed in? Because we used to have the 64 pages limit from > > DIO, but without that we get rather long IRQ-off latencies. > > Ok, I would tend to think this is an issue to solve in gup_fast > implementation, I wouldn't blame or modify the callers for it. > > I don't think there's anything that prevents gup_fast to enable irqs > after certain number of pages have been taken, nop; and disable the > irqs again. > Agreed, I once upon a time had a patch set converting the 2 (x86 and powerpc) gup_fast implementations at the time, but somehow that never got anywhere. Just saying we should probably do that before we add callers with unlimited nr_pages. -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Don't email: email@kvack.org From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752567AbaJBMu6 (ORCPT ); Thu, 2 Oct 2014 08:50:58 -0400 Received: from casper.infradead.org ([85.118.1.10]:56314 "EHLO casper.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752294AbaJBMu5 (ORCPT ); Thu, 2 Oct 2014 08:50:57 -0400 Date: Thu, 2 Oct 2014 14:50:52 +0200 From: Peter Zijlstra To: Andrea Arcangeli Cc: Andres Lagar-Cavilla , Gleb Natapov , Radim Krcmar , Paolo Bonzini , Rik van Riel , Mel Gorman , Andy Lutomirski , Andrew Morton , Sasha Levin , Jianyu Zhan , Paul Cassella , Hugh Dickins , Peter Feiner , kvm@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mm@kvack.org, "Dr. David Alan Gilbert" Subject: Re: RFC: get_user_pages_locked|unlocked to leverage VM_FAULT_RETRY Message-ID: <20141002125052.GF2849@worktop.programming.kicks-ass.net> References: <20140926172535.GC4590@redhat.com> <20141001153611.GC2843@worktop.programming.kicks-ass.net> <20141002123117.GB2342@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20141002123117.GB2342@redhat.com> User-Agent: Mutt/1.5.22.1 (2013-10-16) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Oct 02, 2014 at 02:31:17PM +0200, Andrea Arcangeli wrote: > On Wed, Oct 01, 2014 at 05:36:11PM +0200, Peter Zijlstra wrote: > > For all these and the other _fast() users, is there an actual limit to > > the nr_pages passed in? Because we used to have the 64 pages limit from > > DIO, but without that we get rather long IRQ-off latencies. > > Ok, I would tend to think this is an issue to solve in gup_fast > implementation, I wouldn't blame or modify the callers for it. > > I don't think there's anything that prevents gup_fast to enable irqs > after certain number of pages have been taken, nop; and disable the > irqs again. > Agreed, I once upon a time had a patch set converting the 2 (x86 and powerpc) gup_fast implementations at the time, but somehow that never got anywhere. Just saying we should probably do that before we add callers with unlimited nr_pages.