* [PATCH] mm/compaction: remove local variable is_lru
@ 2016-06-17 9:32 ` Ganesh Mahendran
0 siblings, 0 replies; 9+ messages in thread
From: Ganesh Mahendran @ 2016-06-17 9:32 UTC (permalink / raw)
To: linux-mm, linux-kernel
Cc: akpm, vbabka, iamjoonsoo.kim, mhocko, hillf.zj, minchan,
Ganesh Mahendran
local varialbe is_lru was used for tracking non-lru pages(such as
balloon pages).
But commit
112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
introduced a common framework for non-lru page migration and moved
the compound pages check before non-lru movable pages check.
So there is no need to use local variable is_lru.
Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
---
mm/compaction.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/mm/compaction.c b/mm/compaction.c
index fbb7b38..780be7f 100644
--- a/mm/compaction.c
+++ b/mm/compaction.c
@@ -724,7 +724,6 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
/* Time to isolate some pages for migration */
for (; low_pfn < end_pfn; low_pfn++) {
- bool is_lru;
if (skip_on_failure && low_pfn >= next_skip_pfn) {
/*
@@ -807,8 +806,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
* It's possible to migrate LRU and non-lru movable pages.
* Skip any other type of page
*/
- is_lru = PageLRU(page);
- if (!is_lru) {
+ if (!PageLRU(page)) {
/*
* __PageMovable can return false positive so we need
* to verify it under page_lock.
--
1.9.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH] mm/compaction: remove local variable is_lru
@ 2016-06-17 9:32 ` Ganesh Mahendran
0 siblings, 0 replies; 9+ messages in thread
From: Ganesh Mahendran @ 2016-06-17 9:32 UTC (permalink / raw)
To: linux-mm, linux-kernel
Cc: akpm, vbabka, iamjoonsoo.kim, mhocko, hillf.zj, minchan,
Ganesh Mahendran
local varialbe is_lru was used for tracking non-lru pages(such as
balloon pages).
But commit
112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
introduced a common framework for non-lru page migration and moved
the compound pages check before non-lru movable pages check.
So there is no need to use local variable is_lru.
Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
---
mm/compaction.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/mm/compaction.c b/mm/compaction.c
index fbb7b38..780be7f 100644
--- a/mm/compaction.c
+++ b/mm/compaction.c
@@ -724,7 +724,6 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
/* Time to isolate some pages for migration */
for (; low_pfn < end_pfn; low_pfn++) {
- bool is_lru;
if (skip_on_failure && low_pfn >= next_skip_pfn) {
/*
@@ -807,8 +806,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
* It's possible to migrate LRU and non-lru movable pages.
* Skip any other type of page
*/
- is_lru = PageLRU(page);
- if (!is_lru) {
+ if (!PageLRU(page)) {
/*
* __PageMovable can return false positive so we need
* to verify it under page_lock.
--
1.9.1
--
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 related [flat|nested] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
2016-06-17 9:32 ` Ganesh Mahendran
@ 2016-06-17 9:49 ` Hillf Danton
-1 siblings, 0 replies; 9+ messages in thread
From: Hillf Danton @ 2016-06-17 9:49 UTC (permalink / raw)
To: 'Ganesh Mahendran', linux-mm, linux-kernel
Cc: akpm, vbabka, iamjoonsoo.kim, mhocko, minchan
>
> local varialbe is_lru was used for tracking non-lru pages(such as
> balloon pages).
>
> But commit
> 112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
> introduced a common framework for non-lru page migration and moved
> the compound pages check before non-lru movable pages check.
>
> So there is no need to use local variable is_lru.
>
> Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
> ---
Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com>
> mm/compaction.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/mm/compaction.c b/mm/compaction.c
> index fbb7b38..780be7f 100644
> --- a/mm/compaction.c
> +++ b/mm/compaction.c
> @@ -724,7 +724,6 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
>
> /* Time to isolate some pages for migration */
> for (; low_pfn < end_pfn; low_pfn++) {
> - bool is_lru;
>
> if (skip_on_failure && low_pfn >= next_skip_pfn) {
> /*
> @@ -807,8 +806,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
> * It's possible to migrate LRU and non-lru movable pages.
> * Skip any other type of page
> */
> - is_lru = PageLRU(page);
> - if (!is_lru) {
> + if (!PageLRU(page)) {
> /*
> * __PageMovable can return false positive so we need
> * to verify it under page_lock.
> --
> 1.9.1
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
@ 2016-06-17 9:49 ` Hillf Danton
0 siblings, 0 replies; 9+ messages in thread
From: Hillf Danton @ 2016-06-17 9:49 UTC (permalink / raw)
To: 'Ganesh Mahendran', linux-mm, linux-kernel
Cc: akpm, vbabka, iamjoonsoo.kim, mhocko, minchan
>
> local varialbe is_lru was used for tracking non-lru pages(such as
> balloon pages).
>
> But commit
> 112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
> introduced a common framework for non-lru page migration and moved
> the compound pages check before non-lru movable pages check.
>
> So there is no need to use local variable is_lru.
>
> Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
> ---
Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com>
> mm/compaction.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/mm/compaction.c b/mm/compaction.c
> index fbb7b38..780be7f 100644
> --- a/mm/compaction.c
> +++ b/mm/compaction.c
> @@ -724,7 +724,6 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
>
> /* Time to isolate some pages for migration */
> for (; low_pfn < end_pfn; low_pfn++) {
> - bool is_lru;
>
> if (skip_on_failure && low_pfn >= next_skip_pfn) {
> /*
> @@ -807,8 +806,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
> * It's possible to migrate LRU and non-lru movable pages.
> * Skip any other type of page
> */
> - is_lru = PageLRU(page);
> - if (!is_lru) {
> + if (!PageLRU(page)) {
> /*
> * __PageMovable can return false positive so we need
> * to verify it under page_lock.
> --
> 1.9.1
--
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] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
2016-06-17 9:32 ` Ganesh Mahendran
@ 2016-06-17 9:50 ` Michal Hocko
-1 siblings, 0 replies; 9+ messages in thread
From: Michal Hocko @ 2016-06-17 9:50 UTC (permalink / raw)
To: Ganesh Mahendran
Cc: linux-mm, linux-kernel, akpm, vbabka, iamjoonsoo.kim, hillf.zj, minchan
On Fri 17-06-16 17:32:51, Ganesh Mahendran wrote:
> local varialbe is_lru was used for tracking non-lru pages(such as
> balloon pages).
>
> But commit
> 112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
this commit sha is not stable because it is from the linux-next tree.
> introduced a common framework for non-lru page migration and moved
> the compound pages check before non-lru movable pages check.
>
> So there is no need to use local variable is_lru.
>
> Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
Other than that the patch looks ok and maybe it would be worth folding
into the mm-migrate-support-non-lru-movable-page-migration.patch
> ---
> mm/compaction.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/mm/compaction.c b/mm/compaction.c
> index fbb7b38..780be7f 100644
> --- a/mm/compaction.c
> +++ b/mm/compaction.c
> @@ -724,7 +724,6 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
>
> /* Time to isolate some pages for migration */
> for (; low_pfn < end_pfn; low_pfn++) {
> - bool is_lru;
>
> if (skip_on_failure && low_pfn >= next_skip_pfn) {
> /*
> @@ -807,8 +806,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
> * It's possible to migrate LRU and non-lru movable pages.
> * Skip any other type of page
> */
> - is_lru = PageLRU(page);
> - if (!is_lru) {
> + if (!PageLRU(page)) {
> /*
> * __PageMovable can return false positive so we need
> * to verify it under page_lock.
> --
> 1.9.1
>
--
Michal Hocko
SUSE Labs
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
@ 2016-06-17 9:50 ` Michal Hocko
0 siblings, 0 replies; 9+ messages in thread
From: Michal Hocko @ 2016-06-17 9:50 UTC (permalink / raw)
To: Ganesh Mahendran
Cc: linux-mm, linux-kernel, akpm, vbabka, iamjoonsoo.kim, hillf.zj, minchan
On Fri 17-06-16 17:32:51, Ganesh Mahendran wrote:
> local varialbe is_lru was used for tracking non-lru pages(such as
> balloon pages).
>
> But commit
> 112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
this commit sha is not stable because it is from the linux-next tree.
> introduced a common framework for non-lru page migration and moved
> the compound pages check before non-lru movable pages check.
>
> So there is no need to use local variable is_lru.
>
> Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
Other than that the patch looks ok and maybe it would be worth folding
into the mm-migrate-support-non-lru-movable-page-migration.patch
> ---
> mm/compaction.c | 4 +---
> 1 file changed, 1 insertion(+), 3 deletions(-)
>
> diff --git a/mm/compaction.c b/mm/compaction.c
> index fbb7b38..780be7f 100644
> --- a/mm/compaction.c
> +++ b/mm/compaction.c
> @@ -724,7 +724,6 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
>
> /* Time to isolate some pages for migration */
> for (; low_pfn < end_pfn; low_pfn++) {
> - bool is_lru;
>
> if (skip_on_failure && low_pfn >= next_skip_pfn) {
> /*
> @@ -807,8 +806,7 @@ isolate_migratepages_block(struct compact_control *cc, unsigned long low_pfn,
> * It's possible to migrate LRU and non-lru movable pages.
> * Skip any other type of page
> */
> - is_lru = PageLRU(page);
> - if (!is_lru) {
> + if (!PageLRU(page)) {
> /*
> * __PageMovable can return false positive so we need
> * to verify it under page_lock.
> --
> 1.9.1
>
--
Michal Hocko
SUSE Labs
--
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] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
2016-06-17 9:50 ` Michal Hocko
@ 2016-06-17 12:50 ` Vlastimil Babka
-1 siblings, 0 replies; 9+ messages in thread
From: Vlastimil Babka @ 2016-06-17 12:50 UTC (permalink / raw)
To: Michal Hocko, Ganesh Mahendran
Cc: linux-mm, linux-kernel, akpm, iamjoonsoo.kim, hillf.zj, minchan
On 06/17/2016 11:50 AM, Michal Hocko wrote:
> On Fri 17-06-16 17:32:51, Ganesh Mahendran wrote:
>> local varialbe is_lru was used for tracking non-lru pages(such as
>> balloon pages).
>>
>> But commit
>> 112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
>
> this commit sha is not stable because it is from the linux-next tree.
>
>> introduced a common framework for non-lru page migration and moved
>> the compound pages check before non-lru movable pages check.
>>
>> So there is no need to use local variable is_lru.
>>
>> Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
>
> Other than that the patch looks ok and maybe it would be worth folding
> into the mm-migrate-support-non-lru-movable-page-migration.patch
Agreed.
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
@ 2016-06-17 12:50 ` Vlastimil Babka
0 siblings, 0 replies; 9+ messages in thread
From: Vlastimil Babka @ 2016-06-17 12:50 UTC (permalink / raw)
To: Michal Hocko, Ganesh Mahendran
Cc: linux-mm, linux-kernel, akpm, iamjoonsoo.kim, hillf.zj, minchan
On 06/17/2016 11:50 AM, Michal Hocko wrote:
> On Fri 17-06-16 17:32:51, Ganesh Mahendran wrote:
>> local varialbe is_lru was used for tracking non-lru pages(such as
>> balloon pages).
>>
>> But commit
>> 112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
>
> this commit sha is not stable because it is from the linux-next tree.
>
>> introduced a common framework for non-lru page migration and moved
>> the compound pages check before non-lru movable pages check.
>>
>> So there is no need to use local variable is_lru.
>>
>> Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
>
> Other than that the patch looks ok and maybe it would be worth folding
> into the mm-migrate-support-non-lru-movable-page-migration.patch
Agreed.
--
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] 9+ messages in thread
* Re: [PATCH] mm/compaction: remove local variable is_lru
2016-06-17 12:50 ` Vlastimil Babka
(?)
@ 2016-06-18 1:48 ` Ganesh Mahendran
-1 siblings, 0 replies; 9+ messages in thread
From: Ganesh Mahendran @ 2016-06-18 1:48 UTC (permalink / raw)
To: Vlastimil Babka, akpm
Cc: Michal Hocko, linux-mm, linux-kernel, iamjoonsoo.kim, hillf.zj, minchan
On Fri, Jun 17, 2016 at 02:50:12PM +0200, Vlastimil Babka wrote:
> On 06/17/2016 11:50 AM, Michal Hocko wrote:
> >On Fri 17-06-16 17:32:51, Ganesh Mahendran wrote:
> >>local varialbe is_lru was used for tracking non-lru pages(such as
> >>balloon pages).
> >>
> >>But commit
> >>112ea7b668d3 ("mm: migrate: support non-lru movable page migration")
> >
> >this commit sha is not stable because it is from the linux-next tree.
> >
> >>introduced a common framework for non-lru page migration and moved
> >>the compound pages check before non-lru movable pages check.
> >>
> >>So there is no need to use local variable is_lru.
> >>
> >>Signed-off-by: Ganesh Mahendran <opensource.ganesh@gmail.com>
> >
> >Other than that the patch looks ok and maybe it would be worth folding
> >into the mm-migrate-support-non-lru-movable-page-migration.patch
>
> Agreed.
Thanks.
Hi, Andrew:
Please help to fold this patch into:
mm-migrate-support-non-lru-movable-page-migration.patch
---
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2016-06-18 1:48 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-06-17 9:32 [PATCH] mm/compaction: remove local variable is_lru Ganesh Mahendran
2016-06-17 9:32 ` Ganesh Mahendran
2016-06-17 9:49 ` Hillf Danton
2016-06-17 9:49 ` Hillf Danton
2016-06-17 9:50 ` Michal Hocko
2016-06-17 9:50 ` Michal Hocko
2016-06-17 12:50 ` Vlastimil Babka
2016-06-17 12:50 ` Vlastimil Babka
2016-06-18 1:48 ` Ganesh Mahendran
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.