* [PATCH] mm: vmscan: fix typo in isolating lru pages
@ 2011-12-29 12:38 Hillf Danton
2011-12-29 17:21 ` KOSAKI Motohiro
` (2 more replies)
0 siblings, 3 replies; 5+ messages in thread
From: Hillf Danton @ 2011-12-29 12:38 UTC (permalink / raw)
To: linux-mm
Cc: David Rientjes, Hugh Dickins, Andrew Morton, KAMEZAWA Hiroyuki,
Michal Hocko, LKML
It is not the tag page but the cursor page that we should process, and it looks
a typo.
Signed-off-by: Hillf Danton <dhillf@gmail.com>
Cc: Michal Hocko <mhocko@suse.cz>
Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: David Rientjes <rientjes@google.com>
Cc: Hugh Dickins <hughd@google.com>
---
--- a/mm/vmscan.c Thu Dec 29 20:20:16 2011
+++ b/mm/vmscan.c Thu Dec 29 20:23:30 2011
@@ -1231,13 +1231,13 @@ static unsigned long isolate_lru_pages(u
mem_cgroup_lru_del(cursor_page);
list_move(&cursor_page->lru, dst);
- isolated_pages = hpage_nr_pages(page);
+ isolated_pages = hpage_nr_pages(cursor_page);
nr_taken += isolated_pages;
nr_lumpy_taken += isolated_pages;
if (PageDirty(cursor_page))
nr_lumpy_dirty += isolated_pages;
scan++;
- pfn += isolated_pages-1;
+ pfn += isolated_pages - 1;
} else {
/*
* Check if the page is freed already.
--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] mm: vmscan: fix typo in isolating lru pages
2011-12-29 12:38 [PATCH] mm: vmscan: fix typo in isolating lru pages Hillf Danton
@ 2011-12-29 17:21 ` KOSAKI Motohiro
2011-12-29 23:07 ` Andrew Morton
2012-01-05 6:09 ` KAMEZAWA Hiroyuki
2 siblings, 0 replies; 5+ messages in thread
From: KOSAKI Motohiro @ 2011-12-29 17:21 UTC (permalink / raw)
To: Hillf Danton
Cc: linux-mm, David Rientjes, Hugh Dickins, Andrew Morton,
KAMEZAWA Hiroyuki, Michal Hocko, LKML
(12/29/11 7:38 AM), Hillf Danton wrote:
> It is not the tag page but the cursor page that we should process, and it looks
> a typo.
>
> Signed-off-by: Hillf Danton<dhillf@gmail.com>
> Cc: Michal Hocko<mhocko@suse.cz>
> Cc: KAMEZAWA Hiroyuki<kamezawa.hiroyu@jp.fujitsu.com>
> Cc: Andrew Morton<akpm@linux-foundation.org>
> Cc: David Rientjes<rientjes@google.com>
> Cc: Hugh Dickins<hughd@google.com>
> ---
>
> --- a/mm/vmscan.c Thu Dec 29 20:20:16 2011
> +++ b/mm/vmscan.c Thu Dec 29 20:23:30 2011
> @@ -1231,13 +1231,13 @@ static unsigned long isolate_lru_pages(u
>
> mem_cgroup_lru_del(cursor_page);
> list_move(&cursor_page->lru, dst);
> - isolated_pages = hpage_nr_pages(page);
> + isolated_pages = hpage_nr_pages(cursor_page);
> nr_taken += isolated_pages;
> nr_lumpy_taken += isolated_pages;
> if (PageDirty(cursor_page))
> nr_lumpy_dirty += isolated_pages;
> scan++;
> - pfn += isolated_pages-1;
> + pfn += isolated_pages - 1;
> } else {
> /*
> * Check if the page is freed already.
Looks correct.
Acked-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com>
--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] mm: vmscan: fix typo in isolating lru pages
2011-12-29 12:38 [PATCH] mm: vmscan: fix typo in isolating lru pages Hillf Danton
2011-12-29 17:21 ` KOSAKI Motohiro
@ 2011-12-29 23:07 ` Andrew Morton
2011-12-31 14:25 ` Hillf Danton
2012-01-05 6:09 ` KAMEZAWA Hiroyuki
2 siblings, 1 reply; 5+ messages in thread
From: Andrew Morton @ 2011-12-29 23:07 UTC (permalink / raw)
To: Hillf Danton
Cc: linux-mm, David Rientjes, Hugh Dickins, KAMEZAWA Hiroyuki,
Michal Hocko, LKML, Andrea Arcangeli
On Thu, 29 Dec 2011 20:38:41 +0800
Hillf Danton <dhillf@gmail.com> wrote:
> It is not the tag page but the cursor page that we should process, and it looks
> a typo.
>
> Signed-off-by: Hillf Danton <dhillf@gmail.com>
> Cc: Michal Hocko <mhocko@suse.cz>
> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
> Cc: Andrew Morton <akpm@linux-foundation.org>
> Cc: David Rientjes <rientjes@google.com>
> Cc: Hugh Dickins <hughd@google.com>
> ---
>
> --- a/mm/vmscan.c Thu Dec 29 20:20:16 2011
> +++ b/mm/vmscan.c Thu Dec 29 20:23:30 2011
> @@ -1231,13 +1231,13 @@ static unsigned long isolate_lru_pages(u
>
> mem_cgroup_lru_del(cursor_page);
> list_move(&cursor_page->lru, dst);
> - isolated_pages = hpage_nr_pages(page);
> + isolated_pages = hpage_nr_pages(cursor_page);
> nr_taken += isolated_pages;
> nr_lumpy_taken += isolated_pages;
> if (PageDirty(cursor_page))
> nr_lumpy_dirty += isolated_pages;
> scan++;
> - pfn += isolated_pages-1;
> + pfn += isolated_pages - 1;
> } else {
> /*
> * Check if the page is freed already.
This problem looks pretty benign in mainline. But Andrea's "mm:
vmscan: check if we isolated a compound page during lumpy scan" came
along and uses isolated_pages rather a lot more, including using it to
advance across the pfn array.
I jiggled your patch to suit current mainline then reworked everything
else so we end up with this result.
--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] mm: vmscan: fix typo in isolating lru pages
2011-12-29 23:07 ` Andrew Morton
@ 2011-12-31 14:25 ` Hillf Danton
0 siblings, 0 replies; 5+ messages in thread
From: Hillf Danton @ 2011-12-31 14:25 UTC (permalink / raw)
To: Andrew Morton
Cc: linux-mm, David Rientjes, Hugh Dickins, KAMEZAWA Hiroyuki,
Michal Hocko, LKML, Andrea Arcangeli, KOSAKI Motohiro,
Johannes Weiner, Mel Gorman
On Fri, Dec 30, 2011 at 7:07 AM, Andrew Morton
<akpm@linux-foundation.org> wrote:
> On Thu, 29 Dec 2011 20:38:41 +0800
> Hillf Danton <dhillf@gmail.com> wrote:
>
>> It is not the tag page but the cursor page that we should process, and it looks
>> a typo.
>>
>> Signed-off-by: Hillf Danton <dhillf@gmail.com>
>> Cc: Michal Hocko <mhocko@suse.cz>
>> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
>> Cc: Andrew Morton <akpm@linux-foundation.org>
>> Cc: David Rientjes <rientjes@google.com>
>> Cc: Hugh Dickins <hughd@google.com>
>> ---
>>
>> --- a/mm/vmscan.c Thu Dec 29 20:20:16 2011
>> +++ b/mm/vmscan.c Thu Dec 29 20:23:30 2011
>> @@ -1231,13 +1231,13 @@ static unsigned long isolate_lru_pages(u
>>
>> mem_cgroup_lru_del(cursor_page);
>> list_move(&cursor_page->lru, dst);
>> - isolated_pages = hpage_nr_pages(page);
>> + isolated_pages = hpage_nr_pages(cursor_page);
>> nr_taken += isolated_pages;
>> nr_lumpy_taken += isolated_pages;
>> if (PageDirty(cursor_page))
>> nr_lumpy_dirty += isolated_pages;
>> scan++;
>> - pfn += isolated_pages-1;
>> + pfn += isolated_pages - 1;
>> } else {
>> /*
>> * Check if the page is freed already.
>
> This problem looks pretty benign in mainline. But Andrea's "mm:
> vmscan: check if we isolated a compound page during lumpy scan" came
> along and uses isolated_pages rather a lot more, including using it to
> advance across the pfn array.
>
> I jiggled your patch to suit current mainline then reworked everything
> else so we end up with this result.
>
Hi folks
Thanks for your comments, ack and nack, in 2011.
Happy New Year
Hillf Danton
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [PATCH] mm: vmscan: fix typo in isolating lru pages
2011-12-29 12:38 [PATCH] mm: vmscan: fix typo in isolating lru pages Hillf Danton
2011-12-29 17:21 ` KOSAKI Motohiro
2011-12-29 23:07 ` Andrew Morton
@ 2012-01-05 6:09 ` KAMEZAWA Hiroyuki
2 siblings, 0 replies; 5+ messages in thread
From: KAMEZAWA Hiroyuki @ 2012-01-05 6:09 UTC (permalink / raw)
To: Hillf Danton
Cc: linux-mm, David Rientjes, Hugh Dickins, Andrew Morton,
Michal Hocko, LKML
On Thu, 29 Dec 2011 20:38:41 +0800
Hillf Danton <dhillf@gmail.com> wrote:
> It is not the tag page but the cursor page that we should process, and it looks
> a typo.
>
> Signed-off-by: Hillf Danton <dhillf@gmail.com>
> Cc: Michal Hocko <mhocko@suse.cz>
> Cc: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
> Cc: Andrew Morton <akpm@linux-foundation.org>
> Cc: David Rientjes <rientjes@google.com>
> Cc: Hugh Dickins <hughd@google.com>
Nice.
Reviewed-by: KAMEZAWA Hiroyuki <kamezawa.hiroyu@jp.fujitsu.com>
--
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: <a href=mailto:"dont@kvack.org"> email@kvack.org </a>
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2012-01-05 6:10 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-29 12:38 [PATCH] mm: vmscan: fix typo in isolating lru pages Hillf Danton
2011-12-29 17:21 ` KOSAKI Motohiro
2011-12-29 23:07 ` Andrew Morton
2011-12-31 14:25 ` Hillf Danton
2012-01-05 6:09 ` KAMEZAWA Hiroyuki
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox