login
Login
/
Register
Search
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2008
»
June
»
4
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
view
thread
!MAILaRCHIVE_VOTE_RePLACE
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From:
KAMEZAWA Hiroyuki <kamezawa.hiroyu@...>
To: Paul Menage <menage@...>
Cc: linux-mm@kvack.org <linux-mm@...>, LKML <linux-kernel@...>, balbir@linux.vnet.ibm.com <balbir@...>, xemul@openvz.org <xemul@...>, yamamoto@valinux.co.jp <yamamoto@...>
Subject:
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
Date: Wednesday, June 4, 2008 - 5:18 am
On Wed, 4 Jun 2008 01:59:31 -0700 "Paul Menage" <menage@google.com> wrote:
quoted text
> On Tue, Jun 3, 2008 at 10:01 PM, KAMEZAWA Hiroyuki > <kamezawa.hiroyu@jp.fujitsu.com> wrote: > > int ret; > > char *buf, *end; > > @@ -133,13 +145,101 @@ ssize_t res_counter_write(struct res_cou > > if (*end != '__PLACEHOLDER__0_') > > goto out_free; > > } > > - spin_lock_irqsave(&counter->lock, flags); > > - val = res_counter_member(counter, member); > > - *val = tmp; > > - spin_unlock_irqrestore(&counter->lock, flags); > > - ret = nbytes; > > + if (set_strategy) { > > + ret = set_strategy(res, tmp, member); > > + if (!ret) > > + ret = nbytes; > > + } else { > > + spin_lock_irqsave(&counter->lock, flags); > > + val = res_counter_member(counter, member); > > + *val = tmp; > > + spin_unlock_irqrestore(&counter->lock, flags); > > + ret = nbytes; > > + } > > I think that the hierarchy/reclaim handling that you currently have in > the memory controller should be here; the memory controller should > just be able to pass a reference to try_to_free_mem_cgroup_pages() and > have everything else handled by res_counter. >
Sounds reasonable. I'll re-design the whole AMAP. I think I can do more. Thanks, -Kame --
unsubscribe notice
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/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[RFC][PATCH 0/2] memcg: hierarchy support (v3)
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 12:58 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, Balbir Singh
, (Mon Jun 9, 5:30 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, KAMEZAWA Hiroyuki
, (Mon Jun 9, 5:55 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, Balbir Singh
, (Mon Jun 9, 6:33 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, Paul Menage
, (Wed Jun 4, 4:59 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 5:15 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, Paul Menage
, (Wed Jun 4, 5:15 am)
Re: [RFC][PATCH 0/2] memcg: hierarchy support (v3)
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 5:31 am)
[RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 1:03 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, Randy Dunlap
, (Wed Jun 11, 7:24 pm)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, KAMEZAWA Hiroyuki
, (Thu Jun 12, 1:00 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, Balbir Singh
, (Mon Jun 9, 6:56 am)
Re: Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
,
, (Mon Jun 9, 8:09 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, Daisuke Nishimura
, (Wed Jun 4, 8:32 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 8:04 pm)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, Paul Menage
, (Wed Jun 4, 4:59 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 5:26 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, Daisuke Nishimura
, (Wed Jun 4, 8:53 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, Li Zefan
, (Wed Jun 4, 2:42 am)
Re: [RFC][PATCH 2/2] memcg: hardwall hierarhcy for memcg
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 2:54 am)
[RFC][PATCH 1/2] memcg: res_counter hierarchy
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 1:01 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, Randy Dunlap
, (Wed Jun 11, 7:24 pm)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, KAMEZAWA Hiroyuki
, (Thu Jun 12, 12:59 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, Balbir Singh
, (Mon Jun 9, 5:48 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, KAMEZAWA Hiroyuki
, (Mon Jun 9, 6:20 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, Balbir Singh
, (Mon Jun 9, 6:37 am)
Re: Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
,
, (Mon Jun 9, 8:02 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, Paul Menage
, (Wed Jun 4, 4:59 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 5:18 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, YAMAMOTO Takashi
, (Wed Jun 4, 3:20 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 3:32 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, Li Zefan
, (Wed Jun 4, 2:54 am)
Re: [RFC][PATCH 1/2] memcg: res_counter hierarchy
, KAMEZAWA Hiroyuki
, (Wed Jun 4, 3:03 am)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Greg Kroah-Hartman
[PATCH 001/196] Chinese: Add the known_regression URI to the HOWTO
Linus Torvalds
Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3
Andrew Morton
2.6.25-mm1
Vladislav Bolkhovitin
Re: Integration of SCST in the mainstream Linux kernel
git
:
linux-netdev
:
David Miller
[GIT]: Networking
David Miller
Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock().
Gerrit Renker
[PATCH 0/37] dccp: Feature negotiation - last call for comments
Natalie Protasevich
[BUG] New Kernel Bugs
openbsd-misc
:
Colocation donated by:
Who's online
There are currently
1 user
and
528 guests
online.
Online users
strcmp
Syndicate