diff for duplicates of <1462309298.21143.9.camel@linux.intel.com> diff --git a/a/1.txt b/N1/1.txt index b93199e..e33bb97 100644 --- a/a/1.txt +++ b/N1/1.txt @@ -2,8 +2,8 @@ This is a clean up patch to reorganize the processing of anonymous pages in shrink_page_list. We delay the processing of swapping anonymous pages in shrink_page_list -and put them together on a separate list.A A This prepares for batching -of pages to be swapped.A A The processing of the list of anonymous pages +and put them together on a separate list. This prepares for batching +of pages to be swapped. The processing of the list of anonymous pages to be swapped is consolidated in the function shrink_anon_page_list. Functionally, there is no change in the logic of how pages are processed, @@ -12,17 +12,17 @@ pages in shrink_page_list. Signed-off-by: Tim Chen <tim.c.chen@linux.intel.com> --- -A mm/vmscan.c | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++---- -A 1 file changed, 77 insertions(+), 5 deletions(-) + mm/vmscan.c | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++---- + 1 file changed, 77 insertions(+), 5 deletions(-) diff --git a/mm/vmscan.c b/mm/vmscan.c index 5542005..132ba02 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c @@ -1083,6 +1083,58 @@ static void pg_finish(struct page *page, -A } -A } -A + } + } + +static unsigned long shrink_anon_page_list(struct list_head *page_list, + struct zone *zone, + struct scan_control *sc, @@ -43,7 +43,7 @@ A + + --n; + if (list_empty(swap_pages)) -+ A A A A A A A return nr_reclaimed; ++ return nr_reclaimed; + + page = lru_to_page(swap_pages); + @@ -75,31 +75,31 @@ A + + + -A /* -A * shrink_page_list() returns the number of reclaimed pages -A */ + /* + * shrink_page_list() returns the number of reclaimed pages + */ @@ -1099,6 +1151,8 @@ static unsigned long shrink_page_list(struct list_head *page_list, -A { -A LIST_HEAD(ret_pages); -A LIST_HEAD(free_pages); + { + LIST_HEAD(ret_pages); + LIST_HEAD(free_pages); + LIST_HEAD(swap_pages); + LIST_HEAD(swap_pages_clean); -A int pgactivate = 0; -A unsigned long nr_unqueued_dirty = 0; -A unsigned long nr_dirty = 0; + int pgactivate = 0; + unsigned long nr_unqueued_dirty = 0; + unsigned long nr_dirty = 0; @@ -1106,6 +1160,8 @@ static unsigned long shrink_page_list(struct list_head *page_list, -A unsigned long nr_reclaimed = 0; -A unsigned long nr_writeback = 0; -A unsigned long nr_immediate = 0; + unsigned long nr_reclaimed = 0; + unsigned long nr_writeback = 0; + unsigned long nr_immediate = 0; + unsigned long nr_swap = 0; + unsigned long nr_swap_clean = 0; -A -A cond_resched(); -A + + cond_resched(); + @@ -1271,12 +1327,17 @@ static unsigned long shrink_page_list(struct list_head *page_list, -A pg_dispose = PG_KEEP_LOCKED; -A goto finish; -A } + pg_dispose = PG_KEEP_LOCKED; + goto finish; + } - if (!add_to_swap(page, page_list)) { - pg_dispose = PG_ACTIVATE_LOCKED; - goto finish; @@ -109,20 +109,20 @@ A } + } else { + list_add(&page->lru, &swap_pages); + ++nr_swap; -A } + } - lazyfree = true; - may_enter_fs = 1; + + pg_dispose = PG_NEXT; + goto finish; + -A } -A -A pg_dispose = handle_pgout(page_list, zone, sc, ttu_flags, + } + + pg_dispose = handle_pgout(page_list, zone, sc, ttu_flags, @@ -1288,6 +1349,17 @@ finish: -A -A } -A + + } + + nr_reclaimed += shrink_anon_page_list(page_list, zone, sc, + &swap_pages_clean, &ret_pages, + &free_pages, ttu_flags, @@ -134,14 +134,8 @@ A + &pgactivate, nr_swap, + false); + -A mem_cgroup_uncharge_list(&free_pages); -A try_to_unmap_flush(); -A free_hot_cold_page_list(&free_pages, true); ---A + mem_cgroup_uncharge_list(&free_pages); + try_to_unmap_flush(); + free_hot_cold_page_list(&free_pages, true); +-- 2.5.5 - --- -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> diff --git a/a/content_digest b/N1/content_digest index b392441..573d987 100644 --- a/a/content_digest +++ b/N1/content_digest @@ -20,8 +20,8 @@ "pages in shrink_page_list.\n" "\n" "We delay the processing of swapping anonymous pages in shrink_page_list\n" - "and put them together on a separate list.A A This prepares for batching\n" - "of pages to be swapped.A A The processing of the list of anonymous pages\n" + "and put them together on a separate list.\302\240\302\240This prepares for batching\n" + "of pages to be swapped.\302\240\302\240The processing of the list of anonymous pages\n" "to be swapped is consolidated in the function shrink_anon_page_list.\n" "\n" "Functionally, there is no change in the logic of how pages are processed,\n" @@ -30,17 +30,17 @@ "\n" "Signed-off-by: Tim Chen <tim.c.chen@linux.intel.com>\n" "---\n" - "A mm/vmscan.c | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++----\n" - "A 1 file changed, 77 insertions(+), 5 deletions(-)\n" + "\302\240mm/vmscan.c | 82 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++----\n" + "\302\2401 file changed, 77 insertions(+), 5 deletions(-)\n" "\n" "diff --git a/mm/vmscan.c b/mm/vmscan.c\n" "index 5542005..132ba02 100644\n" "--- a/mm/vmscan.c\n" "+++ b/mm/vmscan.c\n" "@@ -1083,6 +1083,58 @@ static void pg_finish(struct page *page,\n" - "A \t}\n" - "A }\n" - "A \n" + "\302\240\t}\n" + "\302\240}\n" + "\302\240\n" "+static unsigned long shrink_anon_page_list(struct list_head *page_list,\n" "+\tstruct zone *zone,\n" "+\tstruct scan_control *sc,\n" @@ -61,7 +61,7 @@ "+\n" "+\t\t--n;\n" "+\t\tif (list_empty(swap_pages))\n" - "+\t\tA A A A A A A return nr_reclaimed;\n" + "+\t\t\302\240\302\240\302\240\302\240\302\240\302\240\302\240return nr_reclaimed;\n" "+\n" "+\t\tpage = lru_to_page(swap_pages);\n" "+\n" @@ -93,31 +93,31 @@ "+\n" "+\n" "+\n" - "A /*\n" - "A * shrink_page_list() returns the number of reclaimed pages\n" - "A */\n" + "\302\240/*\n" + "\302\240 * shrink_page_list() returns the number of reclaimed pages\n" + "\302\240 */\n" "@@ -1099,6 +1151,8 @@ static unsigned long shrink_page_list(struct list_head *page_list,\n" - "A {\n" - "A \tLIST_HEAD(ret_pages);\n" - "A \tLIST_HEAD(free_pages);\n" + "\302\240{\n" + "\302\240\tLIST_HEAD(ret_pages);\n" + "\302\240\tLIST_HEAD(free_pages);\n" "+\tLIST_HEAD(swap_pages);\n" "+\tLIST_HEAD(swap_pages_clean);\n" - "A \tint pgactivate = 0;\n" - "A \tunsigned long nr_unqueued_dirty = 0;\n" - "A \tunsigned long nr_dirty = 0;\n" + "\302\240\tint pgactivate = 0;\n" + "\302\240\tunsigned long nr_unqueued_dirty = 0;\n" + "\302\240\tunsigned long nr_dirty = 0;\n" "@@ -1106,6 +1160,8 @@ static unsigned long shrink_page_list(struct list_head *page_list,\n" - "A \tunsigned long nr_reclaimed = 0;\n" - "A \tunsigned long nr_writeback = 0;\n" - "A \tunsigned long nr_immediate = 0;\n" + "\302\240\tunsigned long nr_reclaimed = 0;\n" + "\302\240\tunsigned long nr_writeback = 0;\n" + "\302\240\tunsigned long nr_immediate = 0;\n" "+\tunsigned long nr_swap = 0;\n" "+\tunsigned long nr_swap_clean = 0;\n" - "A \n" - "A \tcond_resched();\n" - "A \n" + "\302\240\n" + "\302\240\tcond_resched();\n" + "\302\240\n" "@@ -1271,12 +1327,17 @@ static unsigned long shrink_page_list(struct list_head *page_list,\n" - "A \t\t\t\tpg_dispose = PG_KEEP_LOCKED;\n" - "A \t\t\t\tgoto finish;\n" - "A \t\t\t}\n" + "\302\240\t\t\t\tpg_dispose = PG_KEEP_LOCKED;\n" + "\302\240\t\t\t\tgoto finish;\n" + "\302\240\t\t\t}\n" "-\t\t\tif (!add_to_swap(page, page_list)) {\n" "-\t\t\t\tpg_dispose = PG_ACTIVATE_LOCKED;\n" "-\t\t\t\tgoto finish;\n" @@ -127,20 +127,20 @@ "+\t\t\t} else {\n" "+\t\t\t\tlist_add(&page->lru, &swap_pages);\n" "+\t\t\t\t++nr_swap;\n" - "A \t\t\t}\n" + "\302\240\t\t\t}\n" "-\t\t\tlazyfree = true;\n" "-\t\t\tmay_enter_fs = 1;\n" "+\n" "+\t\t\tpg_dispose = PG_NEXT;\n" "+\t\t\tgoto finish;\n" "+\n" - "A \t\t}\n" - "A \n" - "A \t\tpg_dispose = handle_pgout(page_list, zone, sc, ttu_flags,\n" + "\302\240\t\t}\n" + "\302\240\n" + "\302\240\t\tpg_dispose = handle_pgout(page_list, zone, sc, ttu_flags,\n" "@@ -1288,6 +1349,17 @@ finish:\n" - "A \n" - "A \t}\n" - "A \n" + "\302\240\n" + "\302\240\t}\n" + "\302\240\n" "+\tnr_reclaimed += shrink_anon_page_list(page_list, zone, sc,\n" "+\t\t\t\t\t\t&swap_pages_clean, &ret_pages,\n" "+\t\t\t\t\t\t&free_pages, ttu_flags,\n" @@ -152,16 +152,10 @@ "+\t\t\t\t\t\t&pgactivate, nr_swap,\n" "+\t\t\t\t\t\tfalse);\n" "+\n" - "A \tmem_cgroup_uncharge_list(&free_pages);\n" - "A \ttry_to_unmap_flush();\n" - "A \tfree_hot_cold_page_list(&free_pages, true);\n" - "--A \n" - "2.5.5\n" - "\n" - "--\n" - "To unsubscribe, send a message with 'unsubscribe linux-mm' in\n" - "the body to majordomo@kvack.org. For more info on Linux MM,\n" - "see: http://www.linux-mm.org/ .\n" - "Don't email: <a href=mailto:\"dont@kvack.org\"> email@kvack.org </a>" + "\302\240\tmem_cgroup_uncharge_list(&free_pages);\n" + "\302\240\ttry_to_unmap_flush();\n" + "\302\240\tfree_hot_cold_page_list(&free_pages, true);\n" + "--\302\240\n" + 2.5.5 -2b47a040594f0608f9ff3186dfc8bec2438777c1efc82510ee0724e1ecce2071 +99ac8c8089521871183f7b19430bd52874165bcdfbc5c319f5a1e156ec496a19
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.