Re: [PATCH v2 05/11] Add a __GFP_KMEMCG flag

2012-08-10 Thread Kamezawa Hiroyuki
gt; > Signed-off-by: Glauber Costa > CC: Christoph Lameter > CC: Pekka Enberg > CC: Michal Hocko > CC: Kamezawa Hiroyuki > CC: Johannes Weiner > CC: Suleiman Souhlal > CC: Rik van Riel > CC: Mel Gorman Okay, so, only memcg-aware allocations are accounted. It seems

Re: [PATCH v2 04/11] kmem accounting basic infrastructure

2012-08-10 Thread Kamezawa Hiroyuki
URCE_MAX - 1page - that no one > will ever hit, or equal to the user memory) > > Signed-off-by: Glauber Costa > CC: Michal Hocko > CC: Johannes Weiner > Reviewed-by: Kamezawa Hiroyuki Could you add a patch for documentation of this new interface and a text explaining the behav

Re: [PATCH v2 02/11] memcg: Reclaim when more than one page needed.

2012-08-10 Thread Kamezawa Hiroyuki
(2012/08/11 0:42), Michal Hocko wrote: On Thu 09-08-12 17:01:10, Glauber Costa wrote: [...] @@ -2317,18 +2318,18 @@ static int mem_cgroup_do_charge(struct mem_cgroup *memcg, gfp_t gfp_mask, } else mem_over_limit = mem_cgroup_from_res_counter(fail_res, res); /* -

Re: [RESEND RFC 3/3] memory-hotplug: bug fix race between isolation and allocation

2012-07-27 Thread Kamezawa Hiroyuki
(2012/07/23 9:48), Minchan Kim wrote: > Like below, memory-hotplug makes race between page-isolation > and page-allocation so it can hit BUG_ON in __offline_isolated_pages. > > CPU A CPU B > > start_isolate_page_range > set_migratetype_isolate > spin_lock_i

Re: [PATCH] Cgroup: Fix memory accounting scalability in shrink_page_list

2012-07-19 Thread Kamezawa Hiroyuki
6,6 +1027,7 @@ keep_lumpy: list_splice(&ret_pages, page_list); count_vm_events(PGACTIVATE, pgactivate); + mem_cgroup_uncharge_end(); I guess placing mem_cgroup_uncharge_end() just after the loop may be better looking. Anyway, Acked-by: KAMEZAWA Hiroyuki But please show

Re: [PATCH] hugetlb/cgroup: Simplify pre_destroy callback

2012-07-19 Thread Kamezawa Hiroyuki
(2012/07/19 18:41), Aneesh Kumar K.V wrote: Li Zefan writes: on 2012/7/19 10:55, Aneesh Kumar K.V wrote: Andrew Morton writes: On Wed, 18 Jul 2012 11:04:09 +0530 "Aneesh Kumar K.V" wrote: From: "Aneesh Kumar K.V" Since we cannot fail in hugetlb_cgroup_move_parent, we don't really nee

Re: [PATCH v2] mm/memcg: use exist interface to get css from memcg

2012-07-19 Thread Kamezawa Hiroyuki
(2012/07/19 18:29), Michal Hocko wrote: On Wed 18-07-12 19:08:54, Wanpeng Li wrote: use exist interface mem_cgroup_css instead of &mem->css. This interface has been added to enable mem->css outside of mm/memcontrol.c (where we define struct mem_cgroup). There is one user left (hwpoison_filter_

Re: [PATCH 3/3 v3] memory-hotplug: fix kswapd looping forever problem

2012-07-19 Thread Kamezawa Hiroyuki
From: Andrew Morton Subject: memory-hotplug-fix-kswapd-looping-forever-problem-fix simplify nr_zone_isolate_freepages(), rework zone_watermark_ok_safe() comment, simplify set_pageblock_isolate() and restore_pageblock_isolate(). Cc: Aaditya Kumar Cc: KAMEZAWA Hiroyuki Cc: Mel Gorman Cc

Re: [patch 03/10] mm: memcg: push down PageSwapCache check into uncharge entry functions

2012-07-19 Thread Kamezawa Hiroyuki
gned-off-by: Johannes Weiner > Acked-by: Michal Hocko Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info

Re: [PATCH 5/7] memcg: add per cgroup dirty pages accounting

2012-07-18 Thread Kamezawa Hiroyuki
(2012/07/11 18:32), Sha Zhengju wrote: On 07/10/2012 05:02 AM, Greg Thelen wrote: On Thu, Jun 28 2012, Sha Zhengju wrote: From: Sha Zhengju This patch adds memcg routines to count dirty pages, which allows memory controller to maintain an accurate view of the amount of its dirty memory and c

Re: [PATCH RFC] mm/memcg: calculate max hierarchy limit number instead of min

2012-07-18 Thread Kamezawa Hiroyuki
(2012/07/11 22:24), Wanpeng Li wrote: > From: Wanpeng Li > > Since hierachical_memory_limit shows "of bytes of memory limit with > regard to hierarchy under which the memory cgroup is", the count should > calculate max hierarchy limit when use_hierarchy in order to show hierarchy > subtree limit.

Re: [PATCH] mm/memcg: complete documentation for tcp memcg files

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/06 18:15), Wanpeng Li wrote: > From: Wanpeng Li > > Signed-off-by: Wanpeng Li Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majo

Re: [PATCH] mm/memcg: mem_cgroup_relize_xxx_limit can guarantee memcg->res.limit <= memcg->memsw.limit

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/06 12:21), Wanpeng Li wrote: > From: Wanpeng Li > > Signed-off-by: Wanpeng Li Acked-by: KAMEZAWA Hiroyuki Could you merge all 'commentary fixes' into a patch ? > --- > mm/memcontrol.c |4 ++-- > 1 files changed, 2 insertions(+), 2 delet

Re: [PATCH] mm/memcg: return -EBUSY when oom-kill-disable modified and memcg use_hierarchy, has children

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/05 19:55), Wanpeng Li wrote: > From: Wanpeng Li > > When oom-kill-disable modified by the user and current memcg use_hierarchy, > the change can occur, provided the current memcg has no children. If it > has children, return -EBUSY is enough. > > Signed-off-by: Wanpeng Li I'm sorry wh

Re: [PATCH] mm/memcg: replace inexistence move_lock_page_cgroup() by move_lock_mem_cgroup() in comment

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/05 15:28), Wanpeng Li wrote: > From: Wanpeng Li > > Signed-off-by: Wanpeng Li Acked-by: KAMEZAWA Hiroyuki > --- > mm/memcontrol.c |4 ++-- > 1 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/mm/memcontrol.c b/mm/memcontrol.c > in

Re: [PATCH 6/7] memcg: add per cgroup writeback pages accounting

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/09 13:14), Fengguang Wu wrote: On Mon, Jul 09, 2012 at 11:36:11AM +0800, Sha Zhengju wrote: On 07/08/2012 10:53 PM, Fengguang Wu wrote: @@ -2245,7 +2252,10 @@ int test_set_page_writeback(struct page *page) { struct address_space *mapping = page_mapping(page); int ret;

Re: [patch 11/11] mm: memcg: only check anon swapin page charges for swap cache

2012-07-08 Thread Kamezawa Hiroyuki
their swapin. > > Adjust the comment, though: '4969c11 mm: fix swapin race condition' > added a stable PageSwapCache check under the page lock in the > do_swap_page() before calling the memory controller, so it's > unuse_pte()'s pte_same() that may fail. > > Signed-

Re: [patch 10/11] mm: memcg: only check swap cache pages for repeated charging

2012-07-08 Thread Kamezawa Hiroyuki
is is SwapCache handling is done by commit d13d144309d... I should notice this Thank you very much ! Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info a

Re: [patch 09/11] mm: memcg: split swapin charge function into private and public part

2012-07-08 Thread Kamezawa Hiroyuki
t shmem use the > internal version directly and allow future patches to move around > checks that are only required when swapping in anon pages. > > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel&quo

Re: [patch 08/11] mm: memcg: remove needless !mm fixup to init_mm when charging

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/05 9:45), Johannes Weiner wrote: > It does not matter to __mem_cgroup_try_charge() if the passed mm is > NULL or init_mm, it will charge the root memcg in either case. > > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: s

Re: [patch 07/11] mm: memcg: remove unneeded shmem charge type

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/05 9:44), Johannes Weiner wrote: > shmem page charges have not needed a separate charge type to tell them > from regular file pages since 08e552c 'memcg: synchronized LRU'. > > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from th

Re: [patch 06/11] mm: memcg: move swapin charge functions above callsites

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/05 9:44), Johannes Weiner wrote: > Charging cache pages may require swapin in the shmem case. Save the > forward declaration and just move the swapin functions above the cache > charging functions. > > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki --

Re: [patch 05/11] mm: memcg: only check for PageSwapCache when uncharging anon

2012-07-08 Thread Kamezawa Hiroyuki
re to be not in swapcache. > > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.ht

Re: [patch 04/11] mm: memcg: push down PageSwapCache check into uncharge entry functions

2012-07-08 Thread Kamezawa Hiroyuki
(2012/07/05 9:44), Johannes Weiner wrote: > Not all uncharge paths need to check if the page is swapcache, some of > them can know for sure. > > Push down the check into all callsites of uncharge_common() so that > the patch that removes some of them is more obvious. > > Signed-off-by: Johannes W

Re: [patch 03/11] mm: shmem: do not try to uncharge known swapcache pages

2012-07-08 Thread Kamezawa Hiroyuki
e uncharge code. > > Signed-off-by: Johannes Weiner > --- Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info

Re: [patch 02/11] mm: swapfile: clean up unuse_pte race handling

2012-07-08 Thread Kamezawa Hiroyuki
uot;, the condition is always true when this > code is reached. > > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majord...@vger.kernel.org More majordomo

Re: [patch 01/11] mm: memcg: fix compaction/migration failing due to memcg limits

2012-07-08 Thread Kamezawa Hiroyuki
atever page is still in use after > successful or failed migration gets to keep the charge of the page > that was going to be replaced. > > Reported-by: David Rientjes > Signed-off-by: Johannes Weiner Acked-by: KAMEZAWA Hiroyuki -- To unsubscribe from this list: send the line "

Re: [PATCH] Document huge memory/cache overhead of memory controller in Kconfig

2008-02-21 Thread KAMEZAWA Hiroyuki
On Thu, 21 Feb 2008 16:33:33 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > > Another issue is that it will slightly increase TLB/cache > > cost of the memory controller, but I think that would be a fair > > trade off for it being zero cost when disabled but compiled > > in. > > > > Doing it wit

Re: [PATCH] Document huge memory/cache overhead of memory controller in Kconfig

2008-02-20 Thread KAMEZAWA Hiroyuki
On Wed, 20 Feb 2008 21:45:13 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > > But for computers, limits is an expected and understood term, and for > > filesystems it's quotas. So in this case, I *still* think you should > > be using the term "Memory Quota Controller" instead. It just makes it

Re: [BUG] Linux 2.6.25-rc2 - Regression from 2.6.24-rc1-git1 softlockup while bootup on powerpc

2008-02-19 Thread KAMEZAWA Hiroyuki
On Tue, 19 Feb 2008 09:58:38 +0100 Jens Axboe <[EMAIL PROTECTED]> wrote: > > when I inserted printk here > > == > > for (i = 0; i < nr; i++) > > func(ioc, cics[i]); > > printk("%d %lx\n", nr, index); > > == > > index was always "1" and nr was always 32. > > > > So, cics[31]->k

Re: [BUG] Linux 2.6.25-rc2 - Regression from 2.6.24-rc1-git1 softlockup while bootup on powerpc

2008-02-19 Thread KAMEZAWA Hiroyuki
On Tue, 19 Feb 2008 09:36:34 +0100 Jens Axboe <[EMAIL PROTECTED]> wrote: > On Tue, Feb 19 2008, KAMEZAWA Hiroyuki wrote: > > On Sun, 17 Feb 2008 20:29:13 +0100 > > Jens Axboe <[EMAIL PROTECTED]> wrote: > > > > > It's odd stuff. Could you perh

Re: [BUG] Linux 2.6.25-rc2 - Regression from 2.6.24-rc1-git1 softlockup while bootup on powerpc

2008-02-19 Thread KAMEZAWA Hiroyuki
On Tue, 19 Feb 2008 09:36:34 +0100 Jens Axboe <[EMAIL PROTECTED]> wrote: > On Tue, Feb 19 2008, KAMEZAWA Hiroyuki wrote: > > On Sun, 17 Feb 2008 20:29:13 +0100 > > Jens Axboe <[EMAIL PROTECTED]> wrote: > > > > > It's odd stuff. Could you perh

Re: [BUG] Linux 2.6.25-rc2 - Regression from 2.6.24-rc1-git1 softlockup while bootup on powerpc

2008-02-19 Thread KAMEZAWA Hiroyuki
ics[]->key can be NULL. In that case, cics[]->dead_key has key value. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> Index: linux-2.6.25-rc2/block/cfq-iosched.c === --- linux-2.6.25-rc2.orig/block/cfq-iosc

Re: [PATCH] memcgroup: remove a useless VM_BUG_ON()

2008-02-18 Thread KAMEZAWA Hiroyuki
likely(!PageLRU(page))) > continue; > -- > 1.5.4.rc3 > Acked-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> Thanks, -Kame -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/

Re: [RFC][PATCH 0/7] CGroup API: More structured API for CGroups control files

2008-02-15 Thread KAMEZAWA Hiroyuki
On Fri, 15 Feb 2008 12:44:18 -0800 Paul Menage <[EMAIL PROTECTED]> wrote: > > This set of patches makes the Control Groups API more structured and > self-describing. > > 1) Allows control files to be associated with data types such as > "u64", "string", "map", etc. These types show up in a new c

Re: [RFC][PATCH 4/5] memory_pressure_notify() caller

2008-01-14 Thread KAMEZAWA Hiroyuki
On Tue, 15 Jan 2008 11:37:48 +0900 KOSAKI Motohiro <[EMAIL PROTECTED]> wrote: > Hi KAME, > > > > + notify_threshold = (zone->pages_high + > > > + zone->lowmem_reserve[MAX_NR_ZONES-1]) * 2; > > > + > > Why MAX_NR_ZONES-1 ? > > this is intent to max lowmem_reserve. > Ah, my p

Re: [RFC][PATCH 3/5] add /dev/mem_notify device

2008-01-14 Thread KAMEZAWA Hiroyuki
On Tue, 15 Jan 2008 10:01:21 +0900 KOSAKI Motohiro <[EMAIL PROTECTED]> wrote: > + if (pressure) { > + nr_wakeup = max_t(int, atomic_read(&nr_watcher_task)>>4, 100); > + atomic_long_set(&last_mem_notify, jiffies); > + wake_up_locked_nr(&mem_wait, nr_wakeup);

Re: [RFC][PATCH 4/5] memory_pressure_notify() caller

2008-01-14 Thread KAMEZAWA Hiroyuki
On Tue, 15 Jan 2008 10:02:30 +0900 KOSAKI Motohiro <[EMAIL PROTECTED]> wrote: > + > + notify_threshold = (zone->pages_high + > + zone->lowmem_reserve[MAX_NR_ZONES-1]) * 2; > + Why MAX_NR_ZONES-1 ? > + if (unlikely((prev_free <= notify_threshold) && > +

Re: [patch 05/19] split LRU lists into anon & file sets

2008-01-09 Thread KAMEZAWA Hiroyuki
On Thu, 10 Jan 2008 08:56:31 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > > > The control_type feature is gone. We still have cached page > > > accounting, but we do not allow control of only RSS pages anymore. We > > > need to control both RSS+cached pages. I do not understand your > > > quest

Re: [patch 05/19] split LRU lists into anon & file sets

2008-01-09 Thread KAMEZAWA Hiroyuki
On Thu, 10 Jan 2008 07:51:33 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > > > #define PAGE_CGROUP_FLAG_CACHE (0x1) /* charged as cache */ > > > #define PAGE_CGROUP_FLAG_ACTIVE (0x2)/* page is active in this > > > cgroup */ > > > +#define PAGE_CGROUP_FLAG_FILE(0x4) /* page is fi

Re: [patch 05/19] split LRU lists into anon & file sets

2008-01-09 Thread KAMEZAWA Hiroyuki
On Tue, 08 Jan 2008 15:59:44 -0500 Rik van Riel <[EMAIL PROTECTED]> wrote: > + rotate_sum = zone->recent_rotated_file + zone->recent_rotated_anon; > + > + /* Keep a floating average of RECENT references. */ > + if (unlikely(rotate_sum > min(anon, file))) { > + spin_lock_irq

Re: [patch 05/19] split LRU lists into anon & file sets

2008-01-08 Thread KAMEZAWA Hiroyuki
I like this patch set thank you. On Tue, 08 Jan 2008 15:59:44 -0500 Rik van Riel <[EMAIL PROTECTED]> wrote: > Index: linux-2.6.24-rc6-mm1/mm/memcontrol.c > === > --- linux-2.6.24-rc6-mm1.orig/mm/memcontrol.c 2008-01-07 11:55:09.00

Re: [patch 03/19] define page_file_cache() function

2008-01-08 Thread KAMEZAWA Hiroyuki
On Tue, 8 Jan 2008 17:28:56 -0500 Rik van Riel <[EMAIL PROTECTED]> wrote: > On Tue, 8 Jan 2008 14:18:40 -0800 (PST) > Christoph Lameter <[EMAIL PROTECTED]> wrote: > > > On Tue, 8 Jan 2008, Rik van Riel wrote: > > > > > Define page_file_cache() function to answer the question: > > > is page bac

Re: [patch 07/19] (NEW) add some sanity checks to get_scan_ratio

2008-01-08 Thread KAMEZAWA Hiroyuki
On Tue, 08 Jan 2008 15:59:46 -0500 Rik van Riel <[EMAIL PROTECTED]> wrote: > The access ratio based scan rate determination in get_scan_ratio > works ok in most situations, but needs to be corrected in some > corner cases: > - if we run out of swap space, do not bother scanning the anon LRUs > - i

Re: [patch 00/19] VM pageout scalability improvements

2008-01-07 Thread KAMEZAWA Hiroyuki
On Thu, 3 Jan 2008 12:00:00 -0500 Rik van Riel <[EMAIL PROTECTED]> wrote: > On Thu, 03 Jan 2008 11:52:08 -0500 > Lee Schermerhorn <[EMAIL PROTECTED]> wrote: > > > Also, I should point out that the full noreclaim series includes a > > couple of other patches NOT posted here by Rik: > > > > 1) tre

Re: [patch 07/19] split anon & file LRUs for memcontrol code

2008-01-07 Thread KAMEZAWA Hiroyuki
On Wed, 02 Jan 2008 17:41:51 -0500 linux-kernel@vger.kernel.org wrote: > Index: linux-2.6.24-rc6-mm1/mm/vmscan.c > === > --- linux-2.6.24-rc6-mm1.orig/mm/vmscan.c 2008-01-02 15:55:55.0 > -0500 > +++ linux-2.6.24-rc6-mm1/m

Re: [patch 06/19] split LRU lists into anon & file sets

2008-01-07 Thread KAMEZAWA Hiroyuki
On Wed, 02 Jan 2008 17:41:50 -0500 linux-kernel@vger.kernel.org wrote: > static void shrink_active_list(unsigned long nr_pages, struct zone *zone, > - struct scan_control *sc, int priority) > + struct scan_control *sc, int priority, int fil

Re: [RFC] [PATCH] Memory controller remove control_type feature

2007-12-20 Thread KAMEZAWA Hiroyuki
On Fri, 21 Dec 2007 00:23:58 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > > > Based on the discussion at http://lkml.org/lkml/2007/12/20/383, it was > felt that control_type might not be a good thing to implement right away. > We can add this flexibility at a later point when required. > > S

Re: [PATCH] Memory controller use rcu_read_lock() in mem_cgroup_cache_charge()

2007-12-20 Thread KAMEZAWA Hiroyuki
read_unlock(); > if (mem->control_type == MEM_CGROUP_TYPE_ALL) > - return mem_cgroup_charge_common(page, mm, gfp_mask, > + ret = mem_cgroup_charge_common(page, mm, gfp_mask, > MEM_CGROUP_CHARGE_TYPE_CACHE); > - else &

Re: [PATCH 0/2] memcgroup: work better with tmpfs

2007-12-18 Thread KAMEZAWA Hiroyuki
On Tue, 18 Dec 2007 22:19:22 + (GMT) Hugh Dickins <[EMAIL PROTECTED]> wrote: > 1. Why is spin_lock_irqsave rather than spin_lock needed on mz->lru_lock? > If it is needed, doesn't mem_cgroup_isolate_pages need to use it too? > When I wrote a patch to treat lru_lock (it was not per-zone yet.),

Re: [PATCH] ia64: Avoid unnecessary TLB flushes when allocating memory

2007-12-17 Thread KAMEZAWA Hiroyuki
On Tue, 18 Dec 2007 01:00:15 -0500 Kyle McMartin <[EMAIL PROTECTED]> wrote: > On Tue, Dec 18, 2007 at 10:05:45AM +0900, KAMEZAWA Hiroyuki wrote: > > On Thu, 13 Dec 2007 15:03:07 + > > > > > + if (mm != active_mm) { > > > +

Re: swapping in 2.6.24-rc5-git3

2007-12-17 Thread KAMEZAWA Hiroyuki
On Tue, 18 Dec 2007 10:38:13 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > > Is there a way to avoid it except turning off the swap? > > > Maybe...no. > Ah, sorry. If too much dirty page by ftp is trouble, tuning /proc/sys/vm/dirty_ratio /proc/sys/vm/dirty_writeb

Re: swapping in 2.6.24-rc5-git3

2007-12-17 Thread KAMEZAWA Hiroyuki
On Mon, 17 Dec 2007 14:17:26 +0100 Lukas Hejtmanek <[EMAIL PROTECTED]> wrote: > Hello, > > does /proc/sys/vm/swappiness still work as expected? > # /proc/sys/vm# cat swappiness > 0 > > but scp-ing 2GB file causes many processes are swapped out due to increase of > the file cache size. Why? Thi

Re: [PATCH] ia64: Avoid unnecessary TLB flushes when allocating memory

2007-12-17 Thread KAMEZAWA Hiroyuki
On Thu, 13 Dec 2007 15:03:07 + > + if (mm != active_mm) { > + /* Restore region IDs for mm */ > + if (mm && active_mm) { > + activate_context(mm); > + } else { > + flush_tlb_all(); > +

Re: [PATCH 0/6] Use two zonelists per node instead of multiple zonelists v11r2

2007-12-12 Thread KAMEZAWA Hiroyuki
On Wed, 12 Dec 2007 16:32:51 -0500 Lee Schermerhorn <[EMAIL PROTECTED]> wrote: > Just this afternoon, I hit a null pointer deref in > __mem_cgroup_remove_list() [called from mem_cgroup_uncharge() if I can > trust the stack trace] attempting to unmap a page for migration. I'm > just starting to in

Re: [PATCH][for -mm] fix accounting in vmscan.c for memory controller

2007-12-11 Thread KAMEZAWA Hiroyuki
On Tue, 11 Dec 2007 11:26:44 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > Without this, ALLOCSTALL and PGSCAN_DIRECT increases too much unless > there is no memory shortage. Sorry, Without this, ALLOCSTALL and PGSCAN_DIRECT increases too

Re: [PATCH][for -mm] fix accounting in vmscan.c for memory controller

2007-12-10 Thread KAMEZAWA Hiroyuki
On Tue, 11 Dec 2007 10:44:36 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > Looks good to me. > > Acked-by: Balbir Singh <[EMAIL PROTECTED]> > > TODO: > > 1. Should we have vm_events for the memory controller as well? >May be in the longer term > ALLOC_STALL is recoreded as failcnt, I th

[DOC][for -mm] update Documentation/controller/memory.txt

2007-12-10 Thread KAMEZAWA Hiroyuki
Balbir-san, could you review this update ? -- Documentation updates for memory controller. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> Index: linux-2.6.24-rc4-mm1/Documentation/controllers/memory.txt === --- linux-

[PATCH][for -mm] fix accounting in vmscan.c for memory controller

2007-12-10 Thread KAMEZAWA Hiroyuki
) pages. - under cgroup: use up to limit. I think 2 accountings, ALLOCSTALL and DIRECT should be accounted only under global lru scan. They are accounted against memory shortage at alloc_pages(). Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> mm/vmscan.c |6 -- 1 file chan

Re: What can we do to get ready for memory controller merge in 2.6.25

2007-12-05 Thread KAMEZAWA Hiroyuki
On Fri, 30 Nov 2007 19:11:14 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > I'd like to post some patches below in the next week. > - throttling the number of callers of try_to_free_mem_cgroup_pages() > - background reclaim and high/low watermark. > - some cleanu

Re: What can we do to get ready for memory controller merge in 2.6.25

2007-11-30 Thread KAMEZAWA Hiroyuki
On Fri, 30 Nov 2007 08:43:35 +0530 Balbir Singh <[EMAIL PROTECTED]> wrote: > KAMEZAWA-San posted some test results on background reclaim and per zone > reclaim > I'd like to post some patches below in the next week. - throttling the number of callers of try_to_free_mem_cgroup_pages() - backgr

Re: 2.6.24-rc3-mm2 (bugfix for memory cgroup per-zone-struct allocation.)

2007-11-29 Thread KAMEZAWA Hiroyuki
On Thu, 29 Nov 2007 16:25:33 -0500 Lee Schermerhorn <[EMAIL PROTECTED]> wrote: > > - pn = kmalloc_node(sizeof(*pn), GFP_KERNEL, node); > > + /* > > +* This routine is called against possible nodes. > > +* But it's BUG to call kmalloc() against offline node. > > +* > > +* TODO: t

Re: 2.6.24-rc3-mm2 (bugfix for memory cgroup per-zone-struct allocation.)

2007-11-28 Thread KAMEZAWA Hiroyuki
On Thu, 29 Nov 2007 12:23:29 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > I noticed CONFIG_NUMA + CONFIG_CGROUP_MEM_CONT + CONFIG_SLUB cannot boot > because of my patch. > (SLAB is ok.) > I'll post workaround soon. > == This is a fix. tested on my ia64/NUMA b

Re: [PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [3/10] per-zone active inactive counter

2007-11-28 Thread KAMEZAWA Hiroyuki
On Thu, 29 Nov 2007 12:33:28 +0900 (JST) [EMAIL PROTECTED] (YAMAMOTO Takashi) wrote: > > +static inline struct mem_cgroup_per_zone * > > +mem_cgroup_zoneinfo(struct mem_cgroup *mem, int nid, int zid) > > +{ > > + if (!mem->info.nodeinfo[nid]) > > can this be true? > > YAMAMOTO Takashi When I

Re: [PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [3/10] per-zone active inactive counter

2007-11-28 Thread KAMEZAWA Hiroyuki
On Thu, 29 Nov 2007 12:19:37 +0900 (JST) [EMAIL PROTECTED] (YAMAMOTO Takashi) wrote: > > @@ -651,10 +758,11 @@ > > /* Avoid race with charge */ > > atomic_set(&pc->ref_cnt, 0); > > if (clear_page_cgroup(page, pc) == pc) { > > + int active; > >

Re: 2.6.24-rc3-mm2

2007-11-28 Thread KAMEZAWA Hiroyuki
> +per-zone-and-reclaim-enhancements-for-memory-controller-take-3-add-scan_global_lru-macro.patch > +per-zone-and-reclaim-enhancements-for-memory-controller-take-3-nid-zid-helper-function-for-cgroup.patch > +per-zone-and-reclaim-enhancements-for-memory-controller-take-3-per-zone-active-inactive-co

Re: [PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [3/10] per-zone active inactive counter

2007-11-28 Thread KAMEZAWA Hiroyuki
On Thu, 29 Nov 2007 11:24:06 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > On Thu, 29 Nov 2007 10:37:02 +0900 > KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > > > Maybe zonelists of NODE_DATA() is not initialized. you are right. > > I think N_HIGH_MEM

Re: [PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [3/10] per-zone active inactive counter

2007-11-28 Thread KAMEZAWA Hiroyuki
On Thu, 29 Nov 2007 10:37:02 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > Maybe zonelists of NODE_DATA() is not initialized. you are right. > I think N_HIGH_MEMORY will be suitable here...(I'll consider node-hotplug > case later.) > > Thank you for test! >

Re: [PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [3/10] per-zone active inactive counter

2007-11-28 Thread KAMEZAWA Hiroyuki
On Wed, 28 Nov 2007 16:19:59 -0500 Lee Schermerhorn <[EMAIL PROTECTED]> wrote: > As soon as this loop hits the first non-existent node on my platform, I > get a NULL pointer deref down in __alloc_pages. Stack trace below. > > Perhaps N_POSSIBLE should be N_HIGH_MEMORY? That would require handli

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [9/10] per zone lru for cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
fo(page_cgroup); &mz->active_list &mz->inactive_list Changelog v1->v2 - merged to mem_cgroup_per_zone struct. - handle page migraiton. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> mm/memcontrol.c | 63 ++--

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [10/10] per-zone-lock for cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
oneinfo(page_cgroup); &mz->lru_lock Signed-off-by: KAMEZAWA hiroyuki <[EMAIL PROTECTED]> mm/memcontrol.c | 71 ++-- 1 file changed, 44 insertions(+), 27 deletions(-) Index: linux-2.6.24-rc3

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [8/10] modifies vmscan.c for isolate globa/cgroup lru activity

2007-11-26 Thread KAMEZAWA Hiroyuki
ority as zone->prev_priority. This value is used for calc reclaim_mapped. Changelog V1->V2: - merged calc_reclaim_mapped patch in previous version. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]>

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [7/10] calculate the number of pages to be scanned per cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
Define function for calculating the number of scan target on each Zone/LRU. Changelog V1->V2. - fixed types of variable. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> include/linux/memcontrol.h | 15 +++ mm/memcontrol.c

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [6/10] remember reclaim priority in memory cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
Functions to remember reclaim priority per cgroup (as zone->prev_priority) Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> include/linux/memcontrol.h | 23 +++ mm/memcontrol.c| 20 2 files changed, 43 insertions(+) Ind

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [5/10] calculate active/inactive imbalance per cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
calculate active/inactive imbalance per memory cgroup. Changelog V1 -> V2: - removed "total" (just count inactive and active) - fixed comment - fixed return type to be "long". Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> include/linux/memcontrol.h |

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [4/10] calculate mapper_ratio per cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
Define function for calculating mapped_ratio in memory cgroup. Changelog V1->V2 - Fixed possible divide-by-zero bug. - Use "long" to avoid 64bit division on 32 bit system. and does necessary type casts. - Added comments. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]&

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [3/10] per-zone active inactive counter

2007-11-26 Thread KAMEZAWA Hiroyuki
gt; Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> mm/memcontrol.c | 164 +--- 1 file changed, 157 insertions(+), 7 deletions(-) Index: linux-2.6.24-rc3-mm1/mm/memcontrol.c ==

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [2/10] nid/zid helper function for cgroup

2007-11-26 Thread KAMEZAWA Hiroyuki
Add macro to get node_id and zone_id of page_cgroup. Will be used in per-zone-xxx patches and others. Changelog: - returns zone_type instead of int. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> mm/memcontrol.c | 10 ++ 1 file changed, 10 insertions(+) Index: linux-

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [1/10] add scan_global_lru macro

2007-11-26 Thread KAMEZAWA Hiroyuki
add macro scan_global_lru(). This is used to detect which scan_control scans global lru or mem_cgroup lru. And compiled to be static value (1) when memory controller is not configured. This may make the meaning obvious. Acked-by: Balbir Singh <[EMAIL PROTECTED]> Signed-off-by: KAMEZAWA Hi

[PATCH][for -mm] per-zone and reclaim enhancements for memory controller take 3 [0/10] introduction

2007-11-26 Thread KAMEZAWA Hiroyuki
Hi, this is per-zone/reclaim support patch set for memory controller (cgroup). Major changes from previous one is -- tested with 2.6.24-rc3-mm1 + ia64/NUMA -- applied comments. I did small test on real NUMA machine. My machine was ia64/8CPU/2Node NUMA. I tried to complile the kernel under 800M

Re: 2.6.24-rc3-mm1 (sync is slow ?)

2007-11-25 Thread KAMEZAWA Hiroyuki
On Sat, 24 Nov 2007 19:04:34 +0100 Gabriel C <[EMAIL PROTECTED]> wrote: > >> It seems OK here from a quick test (i386, ext3-on-IDE). > >> > >> Maybe device driver/block breakage? > > Try revert > > http://git.kernel.org/?p=linux/kernel/git/jejb/scsi-misc-2.6.git;a=commitdiff_plain;h=8655a546c83fc

Re: 2.6.24-rc3-mm1 (sync is slow ?)

2007-11-21 Thread KAMEZAWA Hiroyuki
On Wed, 21 Nov 2007 00:49:09 -0800 Andrew Morton <[EMAIL PROTECTED]> wrote: > On Wed, 21 Nov 2007 17:42:15 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> > wrote: > > > Hi, Andrew > > > > I got following result in 'sync' command. > > It

Re: 2.6.24-rc3-mm1 (sync is slow ?)

2007-11-21 Thread KAMEZAWA Hiroyuki
On Wed, 21 Nov 2007 17:42:15 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > Hi, Andrew > > I got following result in 'sync' command. > It was too slow. (memory controller config is off ;) > I attaches my .config. > == > [2.6.24-rc3-mm1] > [EMAIL PRO

Re: 2.6.24-rc3-mm1

2007-11-20 Thread KAMEZAWA Hiroyuki
target `arch/ia64/lib/copy_page-export.o', needed by `arch/ia64/lib/built-in.o'. Stop. make: *** [arch/ia64/lib] Error 2 fix (for my config ?) is attached. = This was necessary to build. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> arch/ia64/lib/Makefile |2 +- 1

Re: [PATCH][2.6.24-rc2-mm1] memory hotplug x86_64 fix [3/3] fix section mismatch in init_memory_mapping

2007-11-15 Thread KAMEZAWA Hiroyuki
On Thu, 15 Nov 2007 16:59:35 -0800 Andrew Morton <[EMAIL PROTECTED]> wrote: > > Index: linux-2.6.24-rc2-mm1/arch/x86/mm/init_64.c > > === > > --- linux-2.6.24-rc2-mm1.orig/arch/x86/mm/init_64.c > > +++ linux-2.6.24-rc2-mm1/arch/x86/mm

Re: [PATCH][2.6.24-rc2-mm1] memory hotplug x86_64 fix [2/3] fix section mismatch in vmammap_allock_block

2007-11-15 Thread KAMEZAWA Hiroyuki
On Thu, 15 Nov 2007 16:53:30 -0800 Andrew Morton <[EMAIL PROTECTED]> wrote: > > - return __alloc_bootmem_node(NODE_DATA(node), size, size, > > + return __earlyonly_bootmem_alloc(node, size, size, > > __pa(MAX_DMA_ADDRESS)); > > } > > > > AFACIT th

[PATCH][2.6.24-rc2-mm1] memory hotplug x86_64 fix [2/3] fix section mismatch in vmammap_allock_block

2007-11-15 Thread KAMEZAWA Hiroyuki
__earlyonly_bootmem_alloc(). Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> mm/sparse-vmemmap.c | 12 +++- 1 file changed, 11 insertions(+), 1 deletion(-) Index: linux-2.6.24-rc2-mm1/mm/sparse-vmemmap.c === ---

[PATCH][2.6.24-rc2-mm1] memory hotplug x86_64 fix [3/3] fix section mismatch in init_memory_mapping

2007-11-15 Thread KAMEZAWA Hiroyuki
ng(). Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> arch/x86/mm/init_64.c |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) Index: linux-2.6.24-rc2-mm1/arch/x86/mm/init_64.c === --- linux-2.6.24-rc2-mm1.orig/arch/

[PATCH][2.6.24-rc2-mm1] memory hotplug x86_64 fix [0/3]

2007-11-15 Thread KAMEZAWA Hiroyuki
memory hotplug fix against 2.6.23-rc2-mm1. Changelog - Divided into 3 patches - dropped patch against mm/sparse.c ( This was my misunderstanding.) - merged Andy's suggestion. All patches are related to memory hotplug. [1/3] ... export memory_add_physaddr_to_nid to acpi memory hotplug [2/3] ..

[PATCH][2.6.24-rc2-mm1] memory hotplug x86_64 fix [1/3] memory_add_physaddr_to_nid export for acpi memhotplug.ko

2007-11-15 Thread KAMEZAWA Hiroyuki
Fix following reference error (when CONFIG_ACPI_HOTPLUG_MEMORY=m) == ERROR: "memory_add_physaddr_to_nid" [drivers/acpi/acpi_memhotplug.ko] undefined! == Changelog: - EXPORT_SYMBOL to EXPORT_SYMBOL_GPL. Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> arch/x86/mm/srat_

Re: 2.6.24-rc2-mm1 (memory hotplug x86_64/vmemmap fix)

2007-11-15 Thread KAMEZAWA Hiroyuki
On Thu, 15 Nov 2007 09:39:15 + Andy Whitcroft <[EMAIL PROTECTED]> wrote: > Can you explain "this is bug" for me. The routine was __init_refok and > therefore ! __init and therefore always present. The logic there must > guarentee it only calls the bootmem allocator in early boot, and the log

Re: 2.6.24-rc2-mm1 (memory hotplug x86_64/vmemmap fix)

2007-11-15 Thread KAMEZAWA Hiroyuki
On Thu, 15 Nov 2007 00:56:57 -0800 Andrew Morton <[EMAIL PROTECTED]> wrote: > eek. > > What I now need to do with this patch is > > - Work out which patches in -mm it is actually fixing. > > - If that is more than one patch then split this patch up into multiple ones. > > - Stage the one or mo

Re: 2.6.24-rc2-mm1 (memory hotplug x86_64/vmemmap fix)

2007-11-14 Thread KAMEZAWA Hiroyuki
ous and decided to add wrapper function to call bootmem, is this style acceptable ? Signed-off-by: KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> arch/x86/mm/init_64.c |2 +- arch/x86/mm/srat_64.c |1 + mm/sparse-vmemmap.c | 13 - mm/sparse.c | 12 ++-

Re: + add-remove_memory-for-ppc64-2.patch added to -mm tree

2007-10-31 Thread KAMEZAWA Hiroyuki
IFT); > + ret = offline_pages(start_pfn, end_pfn, 120 * HZ); > + if (ret) > + goto out; > + /* we can free mem_map at this point */ > +out: > + return ret; > +} > +EXPORT_SYMBOL_GPL(remove_memory); Then, remove_memory() is now generic. Ok. Acked-by: KAM

Re: [2.6 patch] drivers/base/node.c: cleanups

2007-10-24 Thread KAMEZAWA Hiroyuki
On Wed, 24 Oct 2007 09:52:56 -0700 (PDT) Christoph Lameter <[EMAIL PROTECTED]> wrote: > On Wed, 24 Oct 2007, Adrian Bunk wrote: > > > This patch contains the following cleanups: > > - make the following needlessly globalcode static: > > - register_node() > > - node_state_attr[] > > - #if 0 th

Re: [PATCH] Simplify /proc/cgroups

2007-10-17 Thread KAMEZAWA Hiroyuki
On Wed, 17 Oct 2007 19:56:36 -0700 (PDT) [EMAIL PROTECTED] (Paul Menage) wrote: > + seq_printf(m, "%s\t%d\t%d\n", > +ss->name, ss->root->subsys_bits, > +ss->root->number_of_cgroups); > } Because subsys_bits is unsigned long, then %l

Re: 2.6.23-mm1

2007-10-17 Thread KAMEZAWA Hiroyuki
On Wed, 17 Oct 2007 13:42:04 +0200 (CEST) Jiri Kosina <[EMAIL PROTECTED]> wrote: > On Wed, 17 Oct 2007, KAMEZAWA Hiroyuki wrote: > > > > Oh well, this causes more trouble that I have ever imagined ... I will > > > look into it, thanks a lot for the report. Andre

Re: 2.6.23-mm1

2007-10-17 Thread KAMEZAWA Hiroyuki
On Wed, 17 Oct 2007 11:10:23 +0200 (CEST) Jiri Kosina <[EMAIL PROTECTED]> wrote: > Hi, > > hm, I guess this is probably due to pie-randomization patch, right? (could > you please try reverting it, to see whether things get back to normal). > > Oh well, this causes more trouble that I have ever i

Re: 2.6.23-mm1

2007-10-17 Thread KAMEZAWA Hiroyuki
I noticed 32bit binary on x86_64 behavior is changed on 2.6.23-mm1. This is a result of pmap after process returns -ENOMEM.(see attached program) == on 2.6.23 == errno 12 3531: ./malloc 1000 6272K -[ anon ] 00621000100K r-x-- /lib/ld-2.5.so 0063a000

Re: [BUGFIX][PATCH][ for -mm] bugfix for memory cgroup controller [3/5] add helper function for assigning cgroup to page

2007-10-16 Thread KAMEZAWA Hiroyuki
On Fri, 12 Oct 2007 16:37:25 +0900 KAMEZAWA Hiroyuki <[EMAIL PROTECTED]> wrote: > This patch adds following functions. >- clear_page_cgroup(page, pc) >- page_cgroup_assign_new_page_group(page, pc) > > Mainly for cleanup. > > A manner "check page->

<    1   2   3   4   5   6   7   8   >