From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by el-out-1112.google.com with SMTP id z25so2010352ele.8 for ; Tue, 26 Feb 2008 16:57:50 -0800 (PST) Message-ID: <44c63dc40802261657m2930f166mb6eb2378ee843988@mail.gmail.com> Date: Wed, 27 Feb 2008 09:57:49 +0900 From: "minchan Kim" Subject: Re: [RFC][PATCH] radix-tree based page_cgroup. [7/7] per cpu fast lookup In-Reply-To: <20080227083714.fbe34483.kamezawa.hiroyu@jp.fujitsu.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20080225120758.27648297.kamezawa.hiroyu@jp.fujitsu.com> <20080225121849.191ac900.kamezawa.hiroyu@jp.fujitsu.com> <44c63dc40802260526x3283baf2tb4ab71b384a4ab58@mail.gmail.com> <20080227083714.fbe34483.kamezawa.hiroyu@jp.fujitsu.com> Sender: owner-linux-mm@kvack.org Return-Path: To: KAMEZAWA Hiroyuki Cc: "balbir@linux.vnet.ibm.com" , "hugh@veritas.com" , "yamamoto@valinux.co.jp" , taka@valinux.co.jp, Andi Kleen , "nickpiggin@yahoo.com.au" , "linux-mm@kvack.org" List-ID: On Wed, Feb 27, 2008 at 8:37 AM, KAMEZAWA Hiroyuki wrote: > On Tue, 26 Feb 2008 22:26:40 +0900 > > "minchan Kim" wrote: > > > > > > -struct page_cgroup *get_page_cgroup(struct page *page, gfp_t gfpmask) > > > +struct page_cgroup *__get_page_cgroup(struct page *page, gfp_t gfpmask) > > > { > > > struct page_cgroup_root *root; > > > struct page_cgroup *pc, *base_addr; > > > @@ -96,8 +110,14 @@ retry: > > > pc = radix_tree_lookup(&root->root_node, idx); > > > rcu_read_unlock(); > > > > > > + if (pc) { > > > + if (!in_interrupt()) > > > + save_result(pc, idx); > > > + } > > > + > > > > I didn't look through mem_control's patches yet. > > Please understand me if my question might be foolish. > > > > why do you prevent when it happen in interrupt context ? > > Do you have any reason ? > > > looking up isn't done under irq disable but under preempt disable. I can't understand your point. Is that check is really necessary if save_result function use get_cpu_var and put_cpu_var in save_result ? > Thanks, > -Kame > > -- Thanks, barrios -- 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