Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753343AbZLAEOU (ORCPT ); Mon, 30 Nov 2009 23:14:20 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753061AbZLAEOS (ORCPT ); Mon, 30 Nov 2009 23:14:18 -0500 Received: from fgwmail5.fujitsu.co.jp ([192.51.44.35]:56323 "EHLO fgwmail5.fujitsu.co.jp" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752871AbZLAEOR (ORCPT ); Mon, 30 Nov 2009 23:14:17 -0500 X-SecurityPolicyCheck-FJ: OK by FujitsuOutboundMailChecker v1.3.1 From: KOSAKI Motohiro To: Hugh Dickins Subject: Re: [PATCH 2/9] ksm: let shared pages be swappable Cc: kosaki.motohiro@jp.fujitsu.com, KAMEZAWA Hiroyuki , Andrew Morton , Izik Eidus , Andrea Arcangeli , Chris Wright , linux-kernel@vger.kernel.org, linux-mm@kvack.org In-Reply-To: References: <20091130180452.5BF6.A69D9226@jp.fujitsu.com> Message-Id: <20091201125801.5C16.A69D9226@jp.fujitsu.com> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit X-Mailer: Becky! ver. 2.50.07 [ja] Date: Tue, 1 Dec 2009 13:14:20 +0900 (JST) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1067 Lines: 24 > > btw, I'm not sure why bellow kmem_cache_zalloc() is necessary. Why can't we > > use stack? > > Well, I didn't use stack: partly because I'm so ashamed of the pseudo-vmas > on the stack in mm/shmem.c, which have put shmem_getpage() into reports > of high stack users (I've unfinished patches to deal with that); and > partly because page_referenced_ksm() and try_to_unmap_ksm() are on > the page reclaim path, maybe way down deep on a very deep stack. > > But it's not something you or I should be worrying about: as the comment > says, this is just a temporary hack, to present a patch which gets KSM > swapping working in an understandable way, while leaving some corrections > and refinements to subsequent patches. This pseudo-vma is removed in the > very next patch. I see. thanks for kindly explanation :) -- 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/