[PATCH] Documentation/memory-barriers: fix a error that mistakes a CPU notion in Section Transitivity

2013-08-27 Thread larmbr
The memory-barriers document may has a error in Section TRANSITIVITY. For transitivity, see a example below, given that * CPU 2's load from X follows CPU 1's store to X, and CPU 2's load from Y preceds CPU 3's store to Y. CPU 1 CPU 2 CPU 3

[PATCH] Documentation/memory-barriers: fix a error that mistakes a CPU notion in Section Transitivity

2013-08-27 Thread larmbr
The memory-barriers document may has a error in Section TRANSITIVITY. For transitivity, see a example below, given that * CPU 2's load from X follows CPU 1's store to X, and CPU 2's load from Y preceds CPU 3's store to Y. CPU 1 CPU 2 CPU 3

[PATCH RESEND] mm/vmscan : use vmcan_swappiness( ) basing on MEMCG config to elimiate unnecessary runtime cost

2013-08-26 Thread larmbr
Currently, we get the vm_swappiness via vmscan_swappiness(), which calls global_reclaim() to check if this is a global reclaim. Besides, the current implementation of global_reclaim() always returns true for the !CONFIG_MEGCG case, and judges the other case by checking whether

[PATCH RESEND] mm/vmscan : use vmcan_swappiness( ) basing on MEMCG config to elimiate unnecessary runtime cost

2013-08-26 Thread larmbr
Currently, we get the vm_swappiness via vmscan_swappiness(), which calls global_reclaim() to check if this is a global reclaim. Besides, the current implementation of global_reclaim() always returns true for the !CONFIG_MEGCG case, and judges the other case by checking whether

[PATCH] mm/vmscan: make global_reclaim() inline

2013-08-21 Thread larmbr
Though Gcc is likely to inline them, we should better explictly do it manually, and also, this serve to document this fact. Signed-off-by: Zhan Jianyu --- mm/vmscan.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mm/vmscan.c b/mm/vmscan.c index 1de652d..1946d7d

[PATCH] mm/vmscan : use vmcan_swappiness( ) basing on MEMCG config to elimiate unnecessary runtime cost

2013-08-21 Thread larmbr
Currently, we get the vm_swappiness via vmscan_swappiness(), which calls global_reclaim() to check if this is a global reclaim. Besides, the current implementation of global_reclaim() always returns true for the !CONFIG_MEGCG case, and judges the other case by checking whether

[PATCH] mm/vmscan : use vmcan_swappiness( ) basing on MEMCG config to elimiate unnecessary runtime cost

2013-08-21 Thread larmbr
Currently, we get the vm_swappiness via vmscan_swappiness(), which calls global_reclaim() to check if this is a global reclaim. Besides, the current implementation of global_reclaim() always returns true for the !CONFIG_MEGCG case, and judges the other case by checking whether

[PATCH] mm/vmscan: make global_reclaim() inline

2013-08-21 Thread larmbr
Though Gcc is likely to inline them, we should better explictly do it manually, and also, this serve to document this fact. Signed-off-by: Zhan Jianyu nasa4...@gmail.com --- mm/vmscan.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mm/vmscan.c b/mm/vmscan.c index