From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752187AbaE0NJg (ORCPT ); Tue, 27 May 2014 09:09:36 -0400 Received: from bombadil.infradead.org ([198.137.202.9]:47212 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751936AbaE0NJf (ORCPT ); Tue, 27 May 2014 09:09:35 -0400 Date: Tue, 27 May 2014 15:09:26 +0200 From: Peter Zijlstra To: Vlastimil Babka Cc: Konstantin Khlebnikov , "linux-mm@kvack.org" , Linux Kernel Mailing List , Christoph Lameter , Thomas Gleixner , Andrew Morton , Hugh Dickins , Mel Gorman , Roland Dreier , Sean Hefty , Hal Rosenstock , Mike Marciniszyn Subject: Re: [RFC][PATCH 0/5] VM_PINNED Message-ID: <20140527130926.GE5444@laptop.programming.kicks-ass.net> References: <20140526145605.016140154@infradead.org> <20140526203232.GC5444@laptop.programming.kicks-ass.net> <20140527102909.GO30445@twins.programming.kicks-ass.net> <20140527105438.GW13658@twins.programming.kicks-ass.net> <53847C17.2080609@suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <53847C17.2080609@suse.cz> User-Agent: Mutt/1.5.21 (2012-12-30) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, May 27, 2014 at 01:50:47PM +0200, Vlastimil Babka wrote: > > What if VM_PINNED will require VM_LOCKED? > > I.e. user must mlock it before pining and cannot munlock vma while it's pinned. > > Mlocking makes sense, as pages won't be uselessly scanned on > non-evictable LRU, no? (Or maybe I just don't see that something else > prevents then from being there already). We can add VM_PINNED logic to page_check_reference() and try_to_unmap_one() to avoid the scanning if that's a problem. But that's additional bits.