From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753039Ab0ASOHl (ORCPT ); Tue, 19 Jan 2010 09:07:41 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752943Ab0ASOHk (ORCPT ); Tue, 19 Jan 2010 09:07:40 -0500 Received: from mail-bw0-f219.google.com ([209.85.218.219]:36134 "EHLO mail-bw0-f219.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752919Ab0ASOHi (ORCPT ); Tue, 19 Jan 2010 09:07:38 -0500 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=subject:from:to:cc:in-reply-to:references:content-type:date :message-id:mime-version:x-mailer:content-transfer-encoding; b=JWvlVTfzh2+ykqgcfAx1IF5a5R8WwbjBXkDJ5YytSxVEWyr/cGu6qLK4VZhJyhogbs yDemIfYp8JbJbHfyH4ShPrpo48aek1PBngTezu3N4hYwD9CsmVQ/mqaM8IG2SMS5UWXu dQnr/QXOJ8J2HizFseO+qfsy6+dDu6vMOke9c= Subject: Re: [PATCH v6] add MAP_UNLOCKED mmap flag From: Minchan Kim To: Gleb Natapov Cc: Pekka Enberg , Alan Cox , linux-mm@kvack.org, kosaki.motohiro@jp.fujitsu.com, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, akpm@linux-foundation.org, andrew.c.morrow@gmail.com, "Paul E. McKenney" In-Reply-To: <20100119075205.GI14345@redhat.com> References: <20100118133755.GG30698@redhat.com> <84144f021001180609r4d7fbbd0p972d5bc0e227d09a@mail.gmail.com> <20100118141938.GI30698@redhat.com> <84144f021001180805q4d1203b8qab8ccb1de87b2866@mail.gmail.com> <20100118170816.GA22111@redhat.com> <84144f021001181009m52f7eaebp2bd746f92de08da9@mail.gmail.com> <20100118181942.GD22111@redhat.com> <20100118191031.0088f49a@lxorguk.ukuu.org.uk> <20100119071734.GG14345@redhat.com> <84144f021001182337o274c8ed3q8ce60581094bc2b9@mail.gmail.com> <20100119075205.GI14345@redhat.com> Content-Type: text/plain; charset="UTF-8" Date: Tue, 19 Jan 2010 23:07:23 +0900 Message-ID: <1263910043.2163.24.camel@barrios-desktop> Mime-Version: 1.0 X-Mailer: Evolution 2.28.1 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 2010-01-19 at 09:52 +0200, Gleb Natapov wrote: > In my case (virtualization) I want to test/profile guest under heavy swapping > of a guests memory, so I intentionally create memory shortage by creating You mean "guest memory" that is area emulated DRAM in qemu? It is anonymous vma. > guest much large then host memory, but I want system to swap out only > guest's memory. Couldn't you use MADV_SEQUENTIAL on only guest memory area? It doesn't make side effect about readahead since it's anon area. And it would make do best effort to swap out guest's memory. -- Kind regards, Minchan Kim