Re: [PATCH 6/7] mm/balloon_compaction: use common page ballooning

2014-08-20 Thread Rafael Aquini
e(struct page *page, struct > page *newpage, > } > } > > - if (unlikely(__is_movable_balloon_page(page))) { > + if (unlikely(PageBalloon(page))) { > /* >* A ballooned page does not need any special attention from >* physical to virtual reverse mapping procedures. > diff --git a/mm/vmscan.c b/mm/vmscan.c > index 2836b53..f90f93e 100644 > --- a/mm/vmscan.c > +++ b/mm/vmscan.c > @@ -1160,7 +1160,7 @@ unsigned long reclaim_clean_pages_from_list(struct zone > *zone, > > list_for_each_entry_safe(page, next, page_list, lru) { > if (page_is_file_cache(page) && !PageDirty(page) && > - !isolated_balloon_page(page)) { > + !PageBalloon(page)) { > ClearPageActive(page); > list_move(>lru, _pages); > } > Acked-by: Rafael Aquini -- 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.html Please read the FAQ at http://www.tux.org/lkml/

Re: [PATCH 5/7] mm: introduce common page state for ballooned memory

2014-08-20 Thread Rafael Aquini
On Wed, Aug 20, 2014 at 07:04:58PM +0400, Konstantin Khlebnikov wrote: > This patch adds page state PageBallon() and functions __Set/ClearPageBalloon. > Like PageBuddy() PageBalloon() looks like page-flag but actually this is > special > state of page->_mapcount counter. There is no conflict

Re: [PATCH 3/7] mm/balloon_compaction: isolate balloon pages without lru_lock

2014-08-20 Thread Rafael Aquini
able(page))) { > - if (locked && balloon_page_isolate(page)) { > + if (balloon_page_isolate(page)) { > /* Successfully isolated */ > goto

Re: [PATCH 2/7] mm/balloon_compaction: keep ballooned pages away from normal migration path

2014-08-20 Thread Rafael Aquini
7 @@ static int __unmap_and_move(struct page *page, struct > page *newpage, > } > } > > - if (unlikely(balloon_page_movable(page))) { > + if (unlikely(__is_movable_balloon_page(page))) { > /* >* A ballooned page does not need any special attention

Re: [PATCH 1/7] mm/balloon_compaction: ignore anonymous pages

2014-08-20 Thread Rafael Aquini
alloon_compaction.h > @@ -128,7 +128,7 @@ static inline bool page_flags_cleared(struct page *page) > static inline bool __is_movable_balloon_page(struct page *page) > { > struct address_space *mapping = page->mapping; > - return mapping_balloon(mapping); > + return !Page

Re: [PATCH 1/7] mm/balloon_compaction: ignore anonymous pages

2014-08-20 Thread Rafael Aquini
); } /* Acked-by: Rafael Aquini aqu...@redhat.com -- 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.html Please read the FAQ at http://www.tux.org/lkml/

Re: [PATCH 2/7] mm/balloon_compaction: keep ballooned pages away from normal migration path

2014-08-20 Thread Rafael Aquini
, } } - if (unlikely(balloon_page_movable(page))) { + if (unlikely(__is_movable_balloon_page(page))) { /* * A ballooned page does not need any special attention from * physical to virtual reverse mapping procedures. Acked-by: Rafael Aquini aqu

Re: [PATCH 3/7] mm/balloon_compaction: isolate balloon pages without lru_lock

2014-08-20 Thread Rafael Aquini
))) { - if (locked balloon_page_isolate(page)) { + if (balloon_page_isolate(page)) { /* Successfully isolated */ goto isolate_success; } Acked-by: Rafael

Re: [PATCH 5/7] mm: introduce common page state for ballooned memory

2014-08-20 Thread Rafael Aquini
On Wed, Aug 20, 2014 at 07:04:58PM +0400, Konstantin Khlebnikov wrote: This patch adds page state PageBallon() and functions __Set/ClearPageBalloon. Like PageBuddy() PageBalloon() looks like page-flag but actually this is special state of page-_mapcount counter. There is no conflict because

Re: [PATCH 6/7] mm/balloon_compaction: use common page ballooning

2014-08-20 Thread Rafael Aquini
); list_move(page-lru, clean_pages); } Acked-by: Rafael Aquini aqu...@redhat.com -- 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

Re: [PATCH 7/7] mm/balloon_compaction: general cleanup

2014-08-20 Thread Rafael Aquini
On Wed, Aug 20, 2014 at 07:05:09PM +0400, Konstantin Khlebnikov wrote: * move special branch for balloon migraion into migrate_pages * remove special mapping for balloon and its flag AS_BALLOON_MAP * embed struct balloon_dev_info into struct virtio_balloon * cleanup balloon_page_dequeue, kill

Re: [PATCH 2/3] ipc/sem.c: increase SEMMSL, SEMMNI, SEMOPM

2014-08-15 Thread Rafael Aquini
essary. > > Or he can disable sysv entirely (as e.g. done by Android). > > Signed-off-by: Manfred Spraul > --- Acked-by: Rafael Aquini > include/uapi/linux/sem.h | 18 +++--- > 1 file changed, 15 insertions(+), 3 deletions(-) > > diff --git a/include/ua

Re: [PATCH 3/3] ipc namespace: copy settings from parent namespace

2014-08-15 Thread Rafael Aquini
> namespace, which is less surprising. > > The patch updates > - SysV msg > - SysV sem > - SysV shm > - POSIX mqueues > > Cc: se...@hallyn.com > Cc: ebied...@xmission.com > Cc: contain...@lists.linux-foundation.org > Cc: mtk.manpa...@gmail.com > >

Re: [PATCH 1/3] ipc/msg: increase MSGMNI, remove scaling

2014-08-15 Thread Rafael Aquini
hat calls msgrcv() is forced. > > Signed-off-by: Manfred Spraul > --- Acked-by: Rafael Aquini > include/linux/ipc_namespace.h | 20 -- > include/uapi/linux/msg.h | 28 + > ipc/Makefile | 2 +- > ipc/ipc_sysctl.c

Re: [PATCH 1/3] ipc/msg: increase MSGMNI, remove scaling

2014-08-15 Thread Rafael Aquini
...@colorfullife.com --- Acked-by: Rafael Aquini aqu...@redhat.com include/linux/ipc_namespace.h | 20 -- include/uapi/linux/msg.h | 28 + ipc/Makefile | 2 +- ipc/ipc_sysctl.c | 86 +--- ipc

Re: [PATCH 3/3] ipc namespace: copy settings from parent namespace

2014-08-15 Thread Rafael Aquini
, which is less surprising. The patch updates - SysV msg - SysV sem - SysV shm - POSIX mqueues Cc: se...@hallyn.com Cc: ebied...@xmission.com Cc: contain...@lists.linux-foundation.org Cc: mtk.manpa...@gmail.com Signed-off-by: Manfred Spraul manf...@colorfullife.com --- Acked-by: Rafael

Re: [PATCH 2/3] ipc/sem.c: increase SEMMSL, SEMMNI, SEMOPM

2014-08-15 Thread Rafael Aquini
...@colorfullife.com --- Acked-by: Rafael Aquini aqu...@redhat.com include/uapi/linux/sem.h | 18 +++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/include/uapi/linux/sem.h b/include/uapi/linux/sem.h index 541fce0..dd73b90 100644 --- a/include/uapi/linux/sem.h +++ b

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Fri, Aug 15, 2014 at 07:36:16AM +0400, Konstantin Khlebnikov wrote: > Don't hurry. The code in this state for years. > I'm working on patches for this, if everything goes well I'll show it today. > As usual I couldn't stop myself from cleaning the mess, so it will be > bigger than yours. >

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
was forcing compaction concurrently verything looked alright. Sasha, could you give this a try to see if that reported KASAN warning fades away, please? Cheers, -- Rafael ---8<--- From: Rafael Aquini Subject: [PATCH v2] mm: balloon_compaction: enhance balloon_page_movable() checkpoint against ra

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Thu, Aug 14, 2014 at 06:43:50PM -0300, Rafael Aquini wrote: > On Thu, Aug 14, 2014 at 10:07:40PM +0400, Andrey Ryabinin wrote: > > We discussed this with Konstantin and he suggested a better solution for > > this. > > If I understood him correctly the main idea was to stor

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
e won't need to check > mapping->flags. > Here goes what I thought doing, following that suggestion of Konstantin and yours. (I didn't tested it yet) Comments are welcomed. Cheers, -- Rafael 8< From: Rafael Aquini Subject: mm: balloon_compaction: enhance balloon_p

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Thu, Aug 14, 2014 at 10:07:40PM +0400, Andrey Ryabinin wrote: > 2014-08-14 19:13 GMT+04:00 Rafael Aquini : > > It still a harmless condition as before, but considering what goes above > > I'm now convinced & confident the patch proposed by Andrey is the real fix >

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Wed, Aug 13, 2014 at 12:35:02PM -0300, Rafael Aquini wrote: > On Sun, Aug 10, 2014 at 12:49:47PM +0400, Andrey Ryabinin wrote: > > 2014-08-10 5:45 GMT+04:00 Sasha Levin : > > > Hi all, > > > > > > While fuzzing with trinity inside a KVM tools guest running

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Wed, Aug 13, 2014 at 12:35:02PM -0300, Rafael Aquini wrote: On Sun, Aug 10, 2014 at 12:49:47PM +0400, Andrey Ryabinin wrote: 2014-08-10 5:45 GMT+04:00 Sasha Levin sasha.le...@oracle.com: Hi all, While fuzzing with trinity inside a KVM tools guest running the latest -next

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Thu, Aug 14, 2014 at 10:07:40PM +0400, Andrey Ryabinin wrote: 2014-08-14 19:13 GMT+04:00 Rafael Aquini aqu...@redhat.com: It still a harmless condition as before, but considering what goes above I'm now convinced confident the patch proposed by Andrey is the real fix

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
to check mapping-flags. Here goes what I thought doing, following that suggestion of Konstantin and yours. (I didn't tested it yet) Comments are welcomed. Cheers, -- Rafael 8 From: Rafael Aquini aqu...@redhat.com Subject: mm: balloon_compaction: enhance balloon_page_movable

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Thu, Aug 14, 2014 at 06:43:50PM -0300, Rafael Aquini wrote: On Thu, Aug 14, 2014 at 10:07:40PM +0400, Andrey Ryabinin wrote: We discussed this with Konstantin and he suggested a better solution for this. If I understood him correctly the main idea was to store bit identifying ballon

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
was forcing compaction concurrently verything looked alright. Sasha, could you give this a try to see if that reported KASAN warning fades away, please? Cheers, -- Rafael ---8--- From: Rafael Aquini aqu...@redhat.com Subject: [PATCH v2] mm: balloon_compaction: enhance balloon_page_movable() checkpoint

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-14 Thread Rafael Aquini
On Fri, Aug 15, 2014 at 07:36:16AM +0400, Konstantin Khlebnikov wrote: Don't hurry. The code in this state for years. I'm working on patches for this, if everything goes well I'll show it today. As usual I couldn't stop myself from cleaning the mess, so it will be bigger than yours. Sorry, I

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-13 Thread Rafael Aquini
On Sun, Aug 10, 2014 at 12:49:47PM +0400, Andrey Ryabinin wrote: > 2014-08-10 5:45 GMT+04:00 Sasha Levin : > > Hi all, > > > > While fuzzing with trinity inside a KVM tools guest running the latest -next > > kernel with the KASAN patchset, I've stumbled on the following spew: > > > > > > [

Re: mm: compaction: buffer overflow in isolate_migratepages_range

2014-08-13 Thread Rafael Aquini
On Sun, Aug 10, 2014 at 12:49:47PM +0400, Andrey Ryabinin wrote: 2014-08-10 5:45 GMT+04:00 Sasha Levin sasha.le...@oracle.com: Hi all, While fuzzing with trinity inside a KVM tools guest running the latest -next kernel with the KASAN patchset, I've stumbled on the following spew: [

[PATCH v2] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-26 Thread Rafael Aquini
make sysinfo(2) returned data consistent with our current API documentation states. Signed-off-by: Rafael Aquini --- Changelog from v1: - updated commit log message to include historical context (kosaki-san) drivers/base/node.c | 2 +- fs/proc/meminfo.c | 2 +- mm/page_alloc.c | 3

[PATCH v2] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-26 Thread Rafael Aquini
documentation states. Signed-off-by: Rafael Aquini aqu...@redhat.com --- Changelog from v1: - updated commit log message to include historical context (kosaki-san) drivers/base/node.c | 2 +- fs/proc/meminfo.c | 2 +- mm/page_alloc.c | 3 ++- 3 files changed, 4 insertions(+), 3

Re: [PATCH] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-25 Thread Rafael Aquini
On Wed, Jun 25, 2014 at 01:27:53PM -0700, Motohiro Kosaki wrote: > > > > -Original Message- > > From: Rafael Aquini [mailto:aqu...@redhat.com] > > Sent: Wednesday, June 25, 2014 4:16 PM > > To: Motohiro Kosaki > > Cc: linux...@kvack.org; Andrew Morton

Re: [PATCH] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-25 Thread Rafael Aquini
On Wed, Jun 25, 2014 at 12:41:17PM -0700, Motohiro Kosaki wrote: > > > > -Original Message- > > From: Rafael Aquini [mailto:aqu...@redhat.com] > > Sent: Wednesday, June 25, 2014 2:40 PM > > To: linux...@kvack.org > > Cc: Andrew Morton; Rik van Riel; M

[PATCH] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-25 Thread Rafael Aquini
This patch leverages the addition of explicit accounting for pages used by shmem/tmpfs -- "4b02108 mm: oom analysis: add shmem vmstat" -- in order to make the users of sysinfo(2) and si_meminfo*() friends aware of that vmstat entry consistently across the interfaces. Signed-off-by: Raf

[PATCH] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-25 Thread Rafael Aquini
This patch leverages the addition of explicit accounting for pages used by shmem/tmpfs -- 4b02108 mm: oom analysis: add shmem vmstat -- in order to make the users of sysinfo(2) and si_meminfo*() friends aware of that vmstat entry consistently across the interfaces. Signed-off-by: Rafael Aquini

Re: [PATCH] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-25 Thread Rafael Aquini
On Wed, Jun 25, 2014 at 12:41:17PM -0700, Motohiro Kosaki wrote: -Original Message- From: Rafael Aquini [mailto:aqu...@redhat.com] Sent: Wednesday, June 25, 2014 2:40 PM To: linux...@kvack.org Cc: Andrew Morton; Rik van Riel; Mel Gorman; Johannes Weiner; Motohiro Kosaki JP

Re: [PATCH] mm: export NR_SHMEM via sysinfo(2) / si_meminfo() interfaces

2014-06-25 Thread Rafael Aquini
On Wed, Jun 25, 2014 at 01:27:53PM -0700, Motohiro Kosaki wrote: -Original Message- From: Rafael Aquini [mailto:aqu...@redhat.com] Sent: Wednesday, June 25, 2014 4:16 PM To: Motohiro Kosaki Cc: linux...@kvack.org; Andrew Morton; Rik van Riel; Mel Gorman; Johannes Weiner

Re: [PATCH 0/8] mm: add page cache limit and reclaim feature

2014-06-16 Thread Rafael Aquini
On Mon, Jun 16, 2014 at 01:14:22PM +0200, Michal Hocko wrote: > On Mon 16-06-14 17:24:38, Xishi Qiu wrote: > > When system(e.g. smart phone) running for a long time, the cache often takes > > a large memory, maybe the free memory is less than 50M, then OOM will happen > > if APP allocate a large

Re: [PATCH 0/8] mm: add page cache limit and reclaim feature

2014-06-16 Thread Rafael Aquini
On Mon, Jun 16, 2014 at 01:14:22PM +0200, Michal Hocko wrote: On Mon 16-06-14 17:24:38, Xishi Qiu wrote: When system(e.g. smart phone) running for a long time, the cache often takes a large memory, maybe the free memory is less than 50M, then OOM will happen if APP allocate a large order

Re: [PATCH] mm/vmscan.c: use DIV_ROUND_UP for calculation of zone's balance_gap and correct comments.

2014-05-19 Thread Rafael Aquini
; Besides, the gap value is calculated against the per-zone "managed pages", > not "present pages". This patch also corrects the comment and do some > rephrasing. > > Signed-off-by: Jianyu Zhan > --- Acked-by: Rafael Aquini > include/linux/swap.h | 8 +++

Re: [PATCH] mm/vmscan.c: use DIV_ROUND_UP for calculation of zone's balance_gap and correct comments.

2014-05-19 Thread Rafael Aquini
is calculated against the per-zone managed pages, not present pages. This patch also corrects the comment and do some rephrasing. Signed-off-by: Jianyu Zhan nasa4...@gmail.com --- Acked-by: Rafael Aquini aqu...@redhat.com include/linux/swap.h | 8 mm/vmscan.c | 10

Re: commit 0bf1457f0cfca7b " mm: vmscan: do not swap anon pages just because free+file is low" causes heavy performance regression on paging

2014-04-22 Thread Rafael Aquini
); > + > + if (unlikely(file + free <= high_wmark_pages(zone))) { > + scan_balance = SCAN_ANON; > + goto out; > + } > + } > + > + /* >* There is enough inactive page cache, do not reclaim >

Re: commit 0bf1457f0cfca7b " mm: vmscan: do not swap anon pages just because free+file is low" causes heavy performance regression on paging

2014-04-22 Thread Rafael Aquini
On Tue, Apr 22, 2014 at 10:40:17AM -0400, Rik van Riel wrote: > On 04/22/2014 07:57 AM, Christian Borntraeger wrote: > > On 22/04/14 12:55, Christian Borntraeger wrote: > >> While preparing/testing some KVM on s390 patches for the next merge window > >> (target is kvm/next which is based on

Re: commit 0bf1457f0cfca7b mm: vmscan: do not swap anon pages just because free+file is low causes heavy performance regression on paging

2014-04-22 Thread Rafael Aquini
On Tue, Apr 22, 2014 at 10:40:17AM -0400, Rik van Riel wrote: On 04/22/2014 07:57 AM, Christian Borntraeger wrote: On 22/04/14 12:55, Christian Borntraeger wrote: While preparing/testing some KVM on s390 patches for the next merge window (target is kvm/next which is based on 3.15-rc1) I

Re: commit 0bf1457f0cfca7b mm: vmscan: do not swap anon pages just because free+file is low causes heavy performance regression on paging

2014-04-22 Thread Rafael Aquini
. */ -- 1.9.2 Acked-by: Rafael Aquini aqu...@redhat.com -- 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.html Please read the FAQ at http

Re: [PATCH] mm: Only force scan in reclaim when none of the LRUs are big enough.

2014-03-28 Thread Rafael Aquini
Should also give some improvements in regular (non-zswap) swap cases. > > Yes, hughd found significant speedup using regular swap, with several > memcgs under pressure; and it should also be effective in the non-memcg > case, whenever one or another zone LRU is forced too small. > > S

Re: [PATCH] mm: Only force scan in reclaim when none of the LRUs are big enough.

2014-03-28 Thread Rafael Aquini
-by: Rafael Aquini aqu...@redhat.com I apologize to everyone for holding on to this so long: I think it's a very helpful patch (which we've been using in Google for months now). Been sitting on my TODO list, now prompted to send by related patches https://lkml.org/lkml/2014/3/13/217 https

Re: [patch] mm: vmscan: do not swap anon pages just because free+file is low

2014-03-14 Thread Rafael Aquini
t; > To resolve this, do not force scan anon when file pages are low but > instead rely on the scan/rotation ratios to make the right prediction. > > Signed-off-by: Johannes Weiner > Cc: [3.12+] > --- Acked-by: Rafael Aquini > mm/vmscan.c | 16 +--- > 1 f

Re: [patch] mm: vmscan: do not swap anon pages just because free+file is low

2014-03-14 Thread Rafael Aquini
but instead rely on the scan/rotation ratios to make the right prediction. Signed-off-by: Johannes Weiner han...@cmpxchg.org Cc: sta...@kernel.org [3.12+] --- Acked-by: Rafael Aquini aqu...@redhat.com mm/vmscan.c | 16 +--- 1 file changed, 1 insertion(+), 15 deletions(-) diff

Re: [PATCH 2/6] header file for DRBG

2014-03-10 Thread Rafael Aquini
On Sun, Mar 09, 2014 at 12:46:42AM +0100, Stephan Mueller wrote: > The header file includes the definition of: > > * DRBG data structures with > - struct drbg_state as main structure > - struct drbg_core referencing the backend ciphers > - struct drbg_state_ops callbach handlers

Re: [PATCH 2/6] header file for DRBG

2014-03-10 Thread Rafael Aquini
On Sun, Mar 09, 2014 at 12:46:42AM +0100, Stephan Mueller wrote: The header file includes the definition of: * DRBG data structures with - struct drbg_state as main structure - struct drbg_core referencing the backend ciphers - struct drbg_state_ops callbach handlers for

Re: [PATCH] fs/proc/meminfo: meminfo_proc_show(): fix typo in comment

2014-02-21 Thread Rafael Aquini
* Part of the reclaimable swap consists of items that are in use, > + * Part of the reclaimable slab consists of items that are in use, >* and cannot be freed. Cap this estimate at the low watermark. >*/ > available += global_page_state(NR_SLAB_RECLAIMABLE) - > --

Re: [PATCH] kref: oops on zero or negative refcount

2014-02-21 Thread Rafael Aquini
On Thu, Feb 20, 2014 at 01:17:44PM -0500, Rik van Riel wrote: > On 02/20/2014 01:14 PM, Dave Jones wrote: > > On Thu, Feb 20, 2014 at 06:44:59PM +0100, Mateusz Guzik wrote: > > > In use after free situations, it is possible for one thread to write to > > > memory that has just been reallocated

Re: [PATCH] kref: oops on zero or negative refcount

2014-02-21 Thread Rafael Aquini
On Thu, Feb 20, 2014 at 01:17:44PM -0500, Rik van Riel wrote: On 02/20/2014 01:14 PM, Dave Jones wrote: On Thu, Feb 20, 2014 at 06:44:59PM +0100, Mateusz Guzik wrote: In use after free situations, it is possible for one thread to write to memory that has just been reallocated to a new

Re: [PATCH] fs/proc/meminfo: meminfo_proc_show(): fix typo in comment

2014-02-21 Thread Rafael Aquini
, + * Part of the reclaimable slab consists of items that are in use, * and cannot be freed. Cap this estimate at the low watermark. */ available += global_page_state(NR_SLAB_RECLAIMABLE) - -- 1.8.1.4 Acked-by: Rafael Aquini aqu...@redhat.com -- To unsubscribe from

Re: [patch] drop_caches: add some documentation and info message

2014-02-08 Thread Rafael Aquini
gt; > diff --git a/fs/drop_caches.c b/fs/drop_caches.c > index 9fd702f5bfb2..02ae3386e08f 100644 > --- a/fs/drop_caches.c > +++ b/fs/drop_caches.c > @@ -5,6 +5,7 @@ > #include > #include > #include > +#include > #include > #includ

Re: [patch 02/10] fs: cachefiles: use add_to_page_cache_lru()

2014-02-08 Thread Rafael Aquini
On Mon, Feb 03, 2014 at 07:53:34PM -0500, Johannes Weiner wrote: > This code used to have its own lru cache pagevec up until a0b8cab3 > ("mm: remove lru parameter from __pagevec_lru_add and remove parts of > pagevec API"). Now it's just add_to_page_cache() followed by > lru_cache_add(), might as

Re: [patch 02/10] fs: cachefiles: use add_to_page_cache_lru()

2014-02-08 Thread Rafael Aquini
On Mon, Feb 03, 2014 at 07:53:34PM -0500, Johannes Weiner wrote: This code used to have its own lru cache pagevec up until a0b8cab3 (mm: remove lru parameter from __pagevec_lru_add and remove parts of pagevec API). Now it's just add_to_page_cache() followed by lru_cache_add(), might as well

Re: [patch] drop_caches: add some documentation and info message

2014-02-08 Thread Rafael Aquini
) drop_slab(); + printk_ratelimited(KERN_INFO %s (%d): dropped kernel caches: %d\n, Just a nitpick here: s/printk_ratelimited(KERN_INFO ...)/pr_info_ratelimited(...) Acked-by: Rafael Aquini aqu...@redhat.com +current-comm

Re: [PATCH] mm: fix page leak at nfs_symlink()

2014-02-07 Thread Rafael Aquini
On Fri, Feb 07, 2014 at 10:39:24AM -0500, Jeff Layton wrote: > On Fri, 7 Feb 2014 13:19:54 -0200 > Rafael Aquini wrote: > > > Changes committed by "a0b8cab3 mm: remove lru parameter from > > __pagevec_lru_add and remove parts of pagevec API" have introduced >

[PATCH] mm: fix page leak at nfs_symlink()

2014-02-07 Thread Rafael Aquini
a refcount add_to_page_cache_lru() is grabbing. Signed-off-by: Jan Stancek Signed-off-by: Rafael Aquini --- fs/nfs/dir.c | 5 + 1 file changed, 5 insertions(+) diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index be38b57..4a48fe4 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c @@ -1846,6 +1846,11 @@ int n

[PATCH] mm: fix page leak at nfs_symlink()

2014-02-07 Thread Rafael Aquini
add_to_page_cache_lru() is grabbing. Signed-off-by: Jan Stancek jstan...@redhat.com Signed-off-by: Rafael Aquini aqu...@redhat.com --- fs/nfs/dir.c | 5 + 1 file changed, 5 insertions(+) diff --git a/fs/nfs/dir.c b/fs/nfs/dir.c index be38b57..4a48fe4 100644 --- a/fs/nfs/dir.c +++ b/fs/nfs/dir.c

Re: [PATCH] mm: fix page leak at nfs_symlink()

2014-02-07 Thread Rafael Aquini
On Fri, Feb 07, 2014 at 10:39:24AM -0500, Jeff Layton wrote: On Fri, 7 Feb 2014 13:19:54 -0200 Rafael Aquini aqu...@redhat.com wrote: Changes committed by a0b8cab3 mm: remove lru parameter from __pagevec_lru_add and remove parts of pagevec API have introduced a call

Re: [RFC PATCH] char: random: stir the output pools differently when the random_write lenght allows splitting the seed

2014-01-30 Thread Rafael Aquini
On Fri, Jan 10, 2014 at 01:32:10PM +0100, Clemens Ladisch wrote: > Stephan Mueller wrote: > > Am Freitag, 10. Januar 2014, 12:37:26 schrieb Clemens Ladisch: > >> Stephan Mueller wrote: > >>> Am Freitag, 10. Januar 2014, 09:13:57 schrieb Clemens Ladis

Re: [RFC PATCH] char: random: stir the output pools differently when the random_write lenght allows splitting the seed

2014-01-30 Thread Rafael Aquini
On Fri, Jan 10, 2014 at 01:32:10PM +0100, Clemens Ladisch wrote: Stephan Mueller wrote: Am Freitag, 10. Januar 2014, 12:37:26 schrieb Clemens Ladisch: Stephan Mueller wrote: Am Freitag, 10. Januar 2014, 09:13:57 schrieb Clemens Ladisch: Rafael Aquini wrote: This patch introduces changes

Re: [PATCH] mm: Improve documentation of page_order

2014-01-17 Thread Rafael Aquini
* In general, page_zone(page)->lock must be held by the caller to prevent > + * the page being allocated in parallel and returning garbage as the order. > + * If the caller does not hold page_zone(page), they must guarantee that > + * the page cannot be allocated or merged in parallel

Re: [PATCH] mm: Improve documentation of page_order

2014-01-17 Thread Rafael Aquini
does not hold page_zone(page), they must guarantee that + * the page cannot be allocated or merged in parallel. */ static inline unsigned long page_order(struct page *page) { Acked-by: Rafael Aquini aqu...@redhat.com -- To unsubscribe from this list: send the line unsubscribe linux-kernel

Re: [RFC PATCH] char: random: stir the output pools differently when the random_write lenght allows splitting the seed

2014-01-10 Thread Rafael Aquini
On Fri, Jan 10, 2014 at 12:37:26PM +0100, Clemens Ladisch wrote: > Stephan Mueller wrote: > > Am Freitag, 10. Januar 2014, 09:13:57 schrieb Clemens Ladisch: > >> Rafael Aquini wrote: > >>> This patch introduces changes to the random_write method so it can > >&g

Re: [RFC PATCH] char: random: stir the output pools differently when the random_write lenght allows splitting the seed

2014-01-10 Thread Rafael Aquini
On Fri, Jan 10, 2014 at 12:37:26PM +0100, Clemens Ladisch wrote: Stephan Mueller wrote: Am Freitag, 10. Januar 2014, 09:13:57 schrieb Clemens Ladisch: Rafael Aquini wrote: This patch introduces changes to the random_write method so it can split the given seed and completely stir

[RFC PATCH] char: random: stir the output pools differently when the random_write lenght allows splitting the seed

2014-01-09 Thread Rafael Aquini
tput pools with different halves of it, when seed lenght allows us doing so. Signed-off-by: Rafael Aquini --- Suggested by Stephan Mueller drivers/char/random.c | 38 -- 1 file changed, 32 insertions(+), 6 deletions(-) diff --git a/drivers/char/random.c b/drivers/cha

[RFC PATCH] char: random: stir the output pools differently when the random_write lenght allows splitting the seed

2014-01-09 Thread Rafael Aquini
halves of it, when seed lenght allows us doing so. Signed-off-by: Rafael Aquini aqu...@redhat.com --- Suggested by Stephan Mueller stephan.muel...@atsec.com drivers/char/random.c | 38 -- 1 file changed, 32 insertions(+), 6 deletions(-) diff --git a/drivers

Re: ipc whitespace cleanups

2013-12-23 Thread Rafael Aquini
ated by > scripts/checkpatch.pl -f --fix \ > --types=pointer_location,spacing,space_before_tab > - one manual fixup (keep structure members tab-aligned) > > diff -w is empty. > Tested with some msg and sem test apps. > > Signed-off-by: Manfred Spraul > Cc: Joe Perches >

Re: ipc whitespace cleanups

2013-12-23 Thread Rafael Aquini
=pointer_location,spacing,space_before_tab - one manual fixup (keep structure members tab-aligned) diff -w is empty. Tested with some msg and sem test apps. Signed-off-by: Manfred Spraul manf...@colorfullife.com Cc: Joe Perches j...@perches.com --- Acked-by: Rafael Aquini aqu...@redhat.com

Re: [PATCH] ipc: change kern_ipc_perm.deleted type to bool

2013-12-19 Thread Rafael Aquini
On Thu, Dec 19, 2013 at 03:23:02PM -0200, Rafael Aquini wrote: > struct kern_ipc_perm.deleted is meant to be used as a boolean toogle, and > the changes introduced by this patch are just to make the case explicit. > > Signed-off-by: Rafael Aquini s/toogle/toggle my bad, sorry. sh

[PATCH] ipc: change kern_ipc_perm.deleted type to bool

2013-12-19 Thread Rafael Aquini
struct kern_ipc_perm.deleted is meant to be used as a boolean toogle, and the changes introduced by this patch are just to make the case explicit. Signed-off-by: Rafael Aquini --- * a quick sidenote: this patch goes on top of the recently posted [PATCH v3] ipc: introduce ipc_valid_object

[PATCH] ipc: change kern_ipc_perm.deleted type to bool

2013-12-19 Thread Rafael Aquini
struct kern_ipc_perm.deleted is meant to be used as a boolean toogle, and the changes introduced by this patch are just to make the case explicit. Signed-off-by: Rafael Aquini aqu...@redhat.com --- * a quick sidenote: this patch goes on top of the recently posted [PATCH v3] ipc: introduce

Re: [PATCH] ipc: change kern_ipc_perm.deleted type to bool

2013-12-19 Thread Rafael Aquini
On Thu, Dec 19, 2013 at 03:23:02PM -0200, Rafael Aquini wrote: struct kern_ipc_perm.deleted is meant to be used as a boolean toogle, and the changes introduced by this patch are just to make the case explicit. Signed-off-by: Rafael Aquini aqu...@redhat.com s/toogle/toggle my bad, sorry

Re: [PATCH v3] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 04:38:24PM -0800, Davidlohr Bueso wrote: > On Wed, 2013-12-18 at 18:33 -0200, Rafael Aquini wrote: > > After the locking semantics for the SysV IPC API got improved, a couple of > > IPC_RMID race windows were opened because we en

[PATCH v3] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
sections. This patch introduces ipc_valid_object() to consolidate the way we cope with IPC_RMID races by using the same abstraction across the API implementation. Signed-off-by: Rafael Aquini Acked-by: Rik van Riel Acked-by: Greg Thelen --- Changelog: * v3: - code commentary changes as requested

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 07:46:27AM -0800, Davidlohr Bueso wrote: > On Wed, 2013-12-18 at 10:51 -0200, Rafael Aquini wrote: > > On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: > > > On 12/18/2013 12:28 AM, Rafael Aquini wrote: > > > >After the locking

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 07:46:27AM -0800, Davidlohr Bueso wrote: > On Wed, 2013-12-18 at 10:51 -0200, Rafael Aquini wrote: > > On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: > > > On 12/18/2013 12:28 AM, Rafael Aquini wrote: > > > >After the locking

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 10:50:59AM -0200, Rafael Aquini wrote: > On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: > > On 12/18/2013 12:28 AM, Rafael Aquini wrote: > > >After the locking semantics for the SysV IPC API got improved, a couple of > > >IPC_RM

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: > On 12/18/2013 12:28 AM, Rafael Aquini wrote: > >After the locking semantics for the SysV IPC API got improved, a couple of > >IPC_RMID race windows were opened because we ended up dropping the > >'kern_ip

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: On 12/18/2013 12:28 AM, Rafael Aquini wrote: After the locking semantics for the SysV IPC API got improved, a couple of IPC_RMID race windows were opened because we ended up dropping the 'kern_ipc_perm.deleted' check performed way

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 10:50:59AM -0200, Rafael Aquini wrote: On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: On 12/18/2013 12:28 AM, Rafael Aquini wrote: After the locking semantics for the SysV IPC API got improved, a couple of IPC_RMID race windows were opened because we

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 07:46:27AM -0800, Davidlohr Bueso wrote: On Wed, 2013-12-18 at 10:51 -0200, Rafael Aquini wrote: On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: On 12/18/2013 12:28 AM, Rafael Aquini wrote: After the locking semantics for the SysV IPC API got

Re: [PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 07:46:27AM -0800, Davidlohr Bueso wrote: On Wed, 2013-12-18 at 10:51 -0200, Rafael Aquini wrote: On Wed, Dec 18, 2013 at 01:11:29PM +0100, Manfred Spraul wrote: On 12/18/2013 12:28 AM, Rafael Aquini wrote: After the locking semantics for the SysV IPC API got

[PATCH v3] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
sections. This patch introduces ipc_valid_object() to consolidate the way we cope with IPC_RMID races by using the same abstraction across the API implementation. Signed-off-by: Rafael Aquini aqu...@redhat.com Acked-by: Rik van Riel r...@redhat.com Acked-by: Greg Thelen gthe...@google.com

Re: [PATCH v3] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-18 Thread Rafael Aquini
On Wed, Dec 18, 2013 at 04:38:24PM -0800, Davidlohr Bueso wrote: On Wed, 2013-12-18 at 18:33 -0200, Rafael Aquini wrote: After the locking semantics for the SysV IPC API got improved, a couple of IPC_RMID race windows were opened because we ended up dropping the 'kern_ipc_perm.deleted

[PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
sections. This patch introduces ipc_valid_object() to consolidate the way we cope with IPC_RMID races by using the same abstraction across the API implementation. Signed-off-by: Rafael Aquini Acked-by: Rik van Riel Acked-by: Greg Thelen --- Changelog: * v2: - drop assert_spin_locked() from

Re: [PATCH] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
On Tue, Dec 17, 2013 at 02:18:02PM -0800, Davidlohr Bueso wrote: > On Tue, 2013-12-17 at 19:46 -0200, Rafael Aquini wrote: > > On Tue, Dec 17, 2013 at 01:27:49PM -0800, Davidlohr Bueso wrote: > > > Ccing Manfred. > > > > > > On Tue, 2013-12-17 at 17:03 -0200

Re: [PATCH] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
On Tue, Dec 17, 2013 at 01:27:49PM -0800, Davidlohr Bueso wrote: > Ccing Manfred. > > On Tue, 2013-12-17 at 17:03 -0200, Rafael Aquini wrote: > > After the locking semantics for the SysV IPC API got improved, a couple of > > IPC_RMID race windows were opened because

[PATCH] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
sections. This patch introduces ipc_valid_object() to consolidate the way we cope with IPC_RMID races by using the same abstraction across the API implementation. Signed-off-by: Rafael Aquini --- ipc/msg.c | 7 --- ipc/sem.c | 8 ipc/shm.c | 16 ipc/util.h | 13

[PATCH] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
sections. This patch introduces ipc_valid_object() to consolidate the way we cope with IPC_RMID races by using the same abstraction across the API implementation. Signed-off-by: Rafael Aquini aqu...@redhat.com --- ipc/msg.c | 7 --- ipc/sem.c | 8 ipc/shm.c | 16

Re: [PATCH] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
On Tue, Dec 17, 2013 at 01:27:49PM -0800, Davidlohr Bueso wrote: Ccing Manfred. On Tue, 2013-12-17 at 17:03 -0200, Rafael Aquini wrote: After the locking semantics for the SysV IPC API got improved, a couple of IPC_RMID race windows were opened because we ended up dropping

Re: [PATCH] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
On Tue, Dec 17, 2013 at 02:18:02PM -0800, Davidlohr Bueso wrote: On Tue, 2013-12-17 at 19:46 -0200, Rafael Aquini wrote: On Tue, Dec 17, 2013 at 01:27:49PM -0800, Davidlohr Bueso wrote: Ccing Manfred. On Tue, 2013-12-17 at 17:03 -0200, Rafael Aquini wrote: After the locking

[PATCH v2] ipc: introduce ipc_valid_object() helper to sort out IPC_RMID races

2013-12-17 Thread Rafael Aquini
sections. This patch introduces ipc_valid_object() to consolidate the way we cope with IPC_RMID races by using the same abstraction across the API implementation. Signed-off-by: Rafael Aquini aqu...@redhat.com Acked-by: Rik van Riel r...@redhat.com Acked-by: Greg Thelen gthe...@google.com

Re: [PATCH v3 1/6] mm/migrate: add comment about permanent failure path

2013-12-16 Thread Rafael Aquini
+ * unlike -EAGAIN case, the failed page is > + * removed from migration page list and not > + * retried in the next outer loop. > + */ > nr_failed++; &

<    1   2   3   4   5   6   7   >