linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] memcg: make global var to be read_mostly
@ 2008-05-09  5:56 KAMEZAWA Hiroyuki
  2008-05-09  5:58 ` Balbir Singh
  0 siblings, 1 reply; 3+ messages in thread
From: KAMEZAWA Hiroyuki @ 2008-05-09  5:56 UTC (permalink / raw)
  To: LKML
  Cc: linux-mm@kvack.org, Andrew Morton, balbir@linux.vnet.ibm.com,
	xemul@openvz.org, lizf, yamamoto@valinux.co.jp

An easy cut out from memcg: performance improvement patch set.
Tested on: x86-64/linux-2.6.26-rc1-git6

Thanks,
-Kame

==
mem_cgroup_subsys and page_cgroup_cache should be read_mostly and
MEM_CGROUP_RECLAIM_RETRIES can be just a fixed number.

Changelog:
  * makes MEM_CGROUP_RECLAIM_RETRIES to be a macro

Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>



Index: linux-2.6.26-rc1/mm/memcontrol.c
===================================================================
--- linux-2.6.26-rc1.orig/mm/memcontrol.c
+++ linux-2.6.26-rc1/mm/memcontrol.c
@@ -35,9 +35,9 @@
 
 #include <asm/uaccess.h>
 
-struct cgroup_subsys mem_cgroup_subsys;
-static const int MEM_CGROUP_RECLAIM_RETRIES = 5;
-static struct kmem_cache *page_cgroup_cache;
+struct cgroup_subsys mem_cgroup_subsys __read_mostly;
+static struct kmem_cache *page_cgroup_cache __read_mostly;
+#define MEM_CGROUP_RECLAIM_RETRIES	5
 
 /*
  * Statistics for memory cgroup.

--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] memcg: make global var to be read_mostly
  2008-05-09  5:56 [PATCH] memcg: make global var to be read_mostly KAMEZAWA Hiroyuki
@ 2008-05-09  5:58 ` Balbir Singh
  2008-05-12  9:28   ` Pavel Emelyanov
  0 siblings, 1 reply; 3+ messages in thread
From: Balbir Singh @ 2008-05-09  5:58 UTC (permalink / raw)
  To: KAMEZAWA Hiroyuki
  Cc: LKML, linux-mm@kvack.org, Andrew Morton, xemul@openvz.org, lizf,
	yamamoto@valinux.co.jp

KAMEZAWA Hiroyuki wrote:
> An easy cut out from memcg: performance improvement patch set.
> Tested on: x86-64/linux-2.6.26-rc1-git6
> 
> Thanks,
> -Kame
> 
> ==
> mem_cgroup_subsys and page_cgroup_cache should be read_mostly and
> MEM_CGROUP_RECLAIM_RETRIES can be just a fixed number.
> 
> Changelog:
>   * makes MEM_CGROUP_RECLAIM_RETRIES to be a macro
> 
> Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
> 
> 

Acked-by: Balbir Singh <balbir@linux.vnet.ibm.com>

-- 
	Warm Regards,
	Balbir Singh
	Linux Technology Center
	IBM, ISTL

--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] memcg: make global var to be read_mostly
  2008-05-09  5:58 ` Balbir Singh
@ 2008-05-12  9:28   ` Pavel Emelyanov
  0 siblings, 0 replies; 3+ messages in thread
From: Pavel Emelyanov @ 2008-05-12  9:28 UTC (permalink / raw)
  To: balbir
  Cc: KAMEZAWA Hiroyuki, LKML, linux-mm@kvack.org, Andrew Morton, lizf,
	yamamoto@valinux.co.jp

Balbir Singh wrote:
> KAMEZAWA Hiroyuki wrote:
>> An easy cut out from memcg: performance improvement patch set.
>> Tested on: x86-64/linux-2.6.26-rc1-git6
>>
>> Thanks,
>> -Kame
>>
>> ==
>> mem_cgroup_subsys and page_cgroup_cache should be read_mostly and
>> MEM_CGROUP_RECLAIM_RETRIES can be just a fixed number.
>>
>> Changelog:
>>   * makes MEM_CGROUP_RECLAIM_RETRIES to be a macro
>>
>> Signed-off-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
>>
>>
> 
> Acked-by: Balbir Singh <balbir@linux.vnet.ibm.com>
> 

Acked-by: Pavel Emelyanov <xemul@openvz.org>

--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2008-05-12  9:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-09  5:56 [PATCH] memcg: make global var to be read_mostly KAMEZAWA Hiroyuki
2008-05-09  5:58 ` Balbir Singh
2008-05-12  9:28   ` Pavel Emelyanov

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).