All of lore.kernel.org
 help / color / mirror / Atom feed
diff for duplicates of <98b0c783-28dc-62c4-5a94-74c9e27bebe0@suse.cz>

diff --git a/a/1.txt b/N1/1.txt
index 3b41fb5..28bc19c 100644
--- a/a/1.txt
+++ b/N1/1.txt
@@ -52,85 +52,4 @@ and some past mistake I've seen which would be *no_progress_loops++.
 
 Thanks!
 
-----8<----
->From 1623d5bd441160569ffad3808aeeec852048e558 Mon Sep 17 00:00:00 2001
-From: Vlastimil Babka <vbabka@suse.cz>
-Date: Thu, 22 Sep 2016 17:02:37 +0200
-Subject: [PATCH] mm, page_alloc: pull no_progress_loops update to
- should_reclaim_retry()
-
-The should_reclaim_retry() makes decisions based on no_progress_loops, so it
-makes sense to also update the counter there. It will be also consistent with
-should_compact_retry() and compaction_retries. No functional change.
-
-[hillf.zj@alibaba-inc.com: fix missing pointer dereferences]
-Signed-off-by: Vlastimil Babka <vbabka@suse.cz>
-Acked-by: Hillf Danton <hillf.zj@alibaba-inc.com>
----
- mm/page_alloc.c | 28 ++++++++++++++--------------
- 1 file changed, 14 insertions(+), 14 deletions(-)
-
-diff --git a/mm/page_alloc.c b/mm/page_alloc.c
-index 582820080601..6039ff40452c 100644
---- a/mm/page_alloc.c
-+++ b/mm/page_alloc.c
-@@ -3401,16 +3401,26 @@ bool gfp_pfmemalloc_allowed(gfp_t gfp_mask)
- static inline bool
- should_reclaim_retry(gfp_t gfp_mask, unsigned order,
- 		     struct alloc_context *ac, int alloc_flags,
--		     bool did_some_progress, int no_progress_loops)
-+		     bool did_some_progress, int *no_progress_loops)
- {
- 	struct zone *zone;
- 	struct zoneref *z;
- 
- 	/*
-+	 * Costly allocations might have made a progress but this doesn't mean
-+	 * their order will become available due to high fragmentation so
-+	 * always increment the no progress counter for them
-+	 */
-+	if (did_some_progress && order <= PAGE_ALLOC_COSTLY_ORDER)
-+		*no_progress_loops = 0;
-+	else
-+		(*no_progress_loops)++;
-+
-+	/*
- 	 * Make sure we converge to OOM if we cannot make any progress
- 	 * several times in the row.
- 	 */
--	if (no_progress_loops > MAX_RECLAIM_RETRIES)
-+	if (*no_progress_loops > MAX_RECLAIM_RETRIES)
- 		return false;
- 
- 	/*
-@@ -3425,7 +3435,7 @@ should_reclaim_retry(gfp_t gfp_mask, unsigned order,
- 		unsigned long reclaimable;
- 
- 		available = reclaimable = zone_reclaimable_pages(zone);
--		available -= DIV_ROUND_UP(no_progress_loops * available,
-+		available -= DIV_ROUND_UP((*no_progress_loops) * available,
- 					  MAX_RECLAIM_RETRIES);
- 		available += zone_page_state_snapshot(zone, NR_FREE_PAGES);
- 
-@@ -3641,18 +3651,8 @@ __alloc_pages_slowpath(gfp_t gfp_mask, unsigned int order,
- 	if (order > PAGE_ALLOC_COSTLY_ORDER && !(gfp_mask & __GFP_REPEAT))
- 		goto nopage;
- 
--	/*
--	 * Costly allocations might have made a progress but this doesn't mean
--	 * their order will become available due to high fragmentation so
--	 * always increment the no progress counter for them
--	 */
--	if (did_some_progress && order <= PAGE_ALLOC_COSTLY_ORDER)
--		no_progress_loops = 0;
--	else
--		no_progress_loops++;
--
- 	if (should_reclaim_retry(gfp_mask, order, ac, alloc_flags,
--				 did_some_progress > 0, no_progress_loops))
-+				 did_some_progress > 0, &no_progress_loops))
- 		goto retry;
- 
- 	/*
--- 
-2.10.0
\ No newline at end of file
+----8<----
\ No newline at end of file
diff --git a/a/content_digest b/N1/content_digest
index af08b78..878dd23 100644
--- a/a/content_digest
+++ b/N1/content_digest
@@ -109,88 +109,7 @@
   "\n",
   "Thanks!\n",
   "\n",
-  "----8<----\n",
-  ">From 1623d5bd441160569ffad3808aeeec852048e558 Mon Sep 17 00:00:00 2001\n",
-  "From: Vlastimil Babka <vbabka\@suse.cz>\n",
-  "Date: Thu, 22 Sep 2016 17:02:37 +0200\n",
-  "Subject: [PATCH] mm, page_alloc: pull no_progress_loops update to\n",
-  " should_reclaim_retry()\n",
-  "\n",
-  "The should_reclaim_retry() makes decisions based on no_progress_loops, so it\n",
-  "makes sense to also update the counter there. It will be also consistent with\n",
-  "should_compact_retry() and compaction_retries. No functional change.\n",
-  "\n",
-  "[hillf.zj\@alibaba-inc.com: fix missing pointer dereferences]\n",
-  "Signed-off-by: Vlastimil Babka <vbabka\@suse.cz>\n",
-  "Acked-by: Hillf Danton <hillf.zj\@alibaba-inc.com>\n",
-  "---\n",
-  " mm/page_alloc.c | 28 ++++++++++++++--------------\n",
-  " 1 file changed, 14 insertions(+), 14 deletions(-)\n",
-  "\n",
-  "diff --git a/mm/page_alloc.c b/mm/page_alloc.c\n",
-  "index 582820080601..6039ff40452c 100644\n",
-  "--- a/mm/page_alloc.c\n",
-  "+++ b/mm/page_alloc.c\n",
-  "\@\@ -3401,16 +3401,26 \@\@ bool gfp_pfmemalloc_allowed(gfp_t gfp_mask)\n",
-  " static inline bool\n",
-  " should_reclaim_retry(gfp_t gfp_mask, unsigned order,\n",
-  " \t\t     struct alloc_context *ac, int alloc_flags,\n",
-  "-\t\t     bool did_some_progress, int no_progress_loops)\n",
-  "+\t\t     bool did_some_progress, int *no_progress_loops)\n",
-  " {\n",
-  " \tstruct zone *zone;\n",
-  " \tstruct zoneref *z;\n",
-  " \n",
-  " \t/*\n",
-  "+\t * Costly allocations might have made a progress but this doesn't mean\n",
-  "+\t * their order will become available due to high fragmentation so\n",
-  "+\t * always increment the no progress counter for them\n",
-  "+\t */\n",
-  "+\tif (did_some_progress && order <= PAGE_ALLOC_COSTLY_ORDER)\n",
-  "+\t\t*no_progress_loops = 0;\n",
-  "+\telse\n",
-  "+\t\t(*no_progress_loops)++;\n",
-  "+\n",
-  "+\t/*\n",
-  " \t * Make sure we converge to OOM if we cannot make any progress\n",
-  " \t * several times in the row.\n",
-  " \t */\n",
-  "-\tif (no_progress_loops > MAX_RECLAIM_RETRIES)\n",
-  "+\tif (*no_progress_loops > MAX_RECLAIM_RETRIES)\n",
-  " \t\treturn false;\n",
-  " \n",
-  " \t/*\n",
-  "\@\@ -3425,7 +3435,7 \@\@ should_reclaim_retry(gfp_t gfp_mask, unsigned order,\n",
-  " \t\tunsigned long reclaimable;\n",
-  " \n",
-  " \t\tavailable = reclaimable = zone_reclaimable_pages(zone);\n",
-  "-\t\tavailable -= DIV_ROUND_UP(no_progress_loops * available,\n",
-  "+\t\tavailable -= DIV_ROUND_UP((*no_progress_loops) * available,\n",
-  " \t\t\t\t\t  MAX_RECLAIM_RETRIES);\n",
-  " \t\tavailable += zone_page_state_snapshot(zone, NR_FREE_PAGES);\n",
-  " \n",
-  "\@\@ -3641,18 +3651,8 \@\@ __alloc_pages_slowpath(gfp_t gfp_mask, unsigned int order,\n",
-  " \tif (order > PAGE_ALLOC_COSTLY_ORDER && !(gfp_mask & __GFP_REPEAT))\n",
-  " \t\tgoto nopage;\n",
-  " \n",
-  "-\t/*\n",
-  "-\t * Costly allocations might have made a progress but this doesn't mean\n",
-  "-\t * their order will become available due to high fragmentation so\n",
-  "-\t * always increment the no progress counter for them\n",
-  "-\t */\n",
-  "-\tif (did_some_progress && order <= PAGE_ALLOC_COSTLY_ORDER)\n",
-  "-\t\tno_progress_loops = 0;\n",
-  "-\telse\n",
-  "-\t\tno_progress_loops++;\n",
-  "-\n",
-  " \tif (should_reclaim_retry(gfp_mask, order, ac, alloc_flags,\n",
-  "-\t\t\t\t did_some_progress > 0, no_progress_loops))\n",
-  "+\t\t\t\t did_some_progress > 0, &no_progress_loops))\n",
-  " \t\tgoto retry;\n",
-  " \n",
-  " \t/*\n",
-  "-- \n",
-  "2.10.0"
+  "----8<----"
 ]
 
-eef3ff000aa10447a4f764951b133394105f8f1dfbcf4e8e4ec8c679a78d6832
+c46a5230cf850c61c8da80af010b397199a23e2418ff7167943e9d63f4271a7c

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.