From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail172.messagelabs.com (mail172.messagelabs.com [216.82.254.3]) by kanga.kvack.org (Postfix) with ESMTP id 103718D003B for ; Tue, 19 Apr 2011 21:03:59 -0400 (EDT) Received: from wpaz37.hot.corp.google.com (wpaz37.hot.corp.google.com [172.24.198.101]) by smtp-out.google.com with ESMTP id p3K13uJ4010289 for ; Tue, 19 Apr 2011 18:03:56 -0700 Received: from qwa26 (qwa26.prod.google.com [10.241.193.26]) by wpaz37.hot.corp.google.com with ESMTP id p3K13sCT019803 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NOT) for ; Tue, 19 Apr 2011 18:03:55 -0700 Received: by qwa26 with SMTP id 26so136043qwa.28 for ; Tue, 19 Apr 2011 18:03:54 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20110420095429.45FD.A69D9226@jp.fujitsu.com> References: <20110420092003.45EB.A69D9226@jp.fujitsu.com> <20110420095429.45FD.A69D9226@jp.fujitsu.com> Date: Tue, 19 Apr 2011 18:03:54 -0700 Message-ID: Subject: Re: [PATCH 0/3] pass the scan_control into shrinkers From: Ying Han Content-Type: multipart/alternative; boundary=000e0cd68ee0dd080f04a14f324a Sender: owner-linux-mm@kvack.org List-ID: To: KOSAKI Motohiro Cc: Nick Piggin , Minchan Kim , Daisuke Nishimura , Balbir Singh , Tejun Heo , Pavel Emelyanov , KAMEZAWA Hiroyuki , Andrew Morton , Li Zefan , Mel Gorman , Christoph Lameter , Johannes Weiner , Rik van Riel , Hugh Dickins , Michal Hocko , Dave Hansen , Zhu Yanhai , linux-mm@kvack.org --000e0cd68ee0dd080f04a14f324a Content-Type: text/plain; charset=ISO-8859-1 On Tue, Apr 19, 2011 at 5:54 PM, KOSAKI Motohiro < kosaki.motohiro@jp.fujitsu.com> wrote: > > On Tue, Apr 19, 2011 at 5:20 PM, KOSAKI Motohiro < > > kosaki.motohiro@jp.fujitsu.com> wrote: > > > > > > This patch changes the shrink_slab and shrinker APIs by consolidating > > > existing > > > > parameters into scan_control struct. This simplifies any further > attempts > > > to > > > > pass extra info to the shrinker. Instead of modifying all the > shrinker > > > files > > > > each time, we just need to extend the scan_control struct. > > > > > > > > > > Ugh. No, please no. > > > Current scan_control has a lot of vmscan internal information. Please > > > export only you need one, not all. > > > > > > Otherwise, we can't change any vmscan code while any shrinker are using > it. > > > > > > > So, are you suggesting maybe add another struct for this purpose? > > Yes. And please explain which member do you need. > For now, I added the "nr_slab_to_reclaim" and also consolidate the gfp_mask. More importantly this makes any further change (pass stuff from reclaim to the shrinkers) easier w/o modifying each file of the shrinker. So make it into a new struct sounds reasonable to me. How about something called "slab_control". --Ying --000e0cd68ee0dd080f04a14f324a Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable

On Tue, Apr 19, 2011 at 5:54 PM, KOSAKI = Motohiro <kosaki.motohiro@jp.fujitsu.com> wrote:
> On Tue, Apr 19, 2011 at 5:20 PM, KOS= AKI Motohiro <
> kosaki.motohiro@jp.f= ujitsu.com> wrote:
>
> > > This patch changes the shrink_slab and shrinker APIs by cons= olidating
> > existing
> > > parameters into scan_control struct. This simplifies any fur= ther attempts
> > to
> > > pass extra info to the shrinker. Instead of modifying all th= e shrinker
> > files
> > > each time, we just need to extend the scan_control struct. > > >
> >
> > Ugh. No, please no.
> > Current scan_control has a lot of vmscan internal information. Pl= ease
> > export only you need one, not all.
> >
> > Otherwise, we can't change any vmscan code while any shrinker= are using it.
> >
>
> So, are you suggesting maybe add another struct for this purpose?

Yes. And please explain which member do you need.

For now, I added the "nr_slab_to_reclaim" = and also consolidate the gfp_mask.=A0More importantly this makes any furthe= r change (pass stuff from reclaim to the shrinkers) easier w/o modifying ea= ch file of the shrinker.=A0

So make it into a new struct sounds reasonable to me. H= ow about something called "slab_control".

--Ying

--000e0cd68ee0dd080f04a14f324a-- -- 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/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: email@kvack.org