* + mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5.patch added to mm-unstable branch
@ 2022-08-27 3:20 Andrew Morton
0 siblings, 0 replies; only message in thread
From: Andrew Morton @ 2022-08-27 3:20 UTC (permalink / raw)
To: mm-commits, william.kucharski, vbabka, sjpark, sieberf, shakeelb,
quic_pkondeti, pasha.tatashin, minchan, mhocko, david,
quic_charante, akpm
The patch titled
Subject: mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5
has been added to the -mm mm-unstable branch. Its filename is
mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5.patch
This patch will shortly appear at
https://git.kernel.org/pub/scm/linux/kernel/git/akpm/25-new.git/tree/patches/mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5.patch
This patch will later appear in the mm-unstable branch at
git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a
reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/process/submit-checklist.rst when testing your code ***
The -mm tree is included into linux-next via the mm-everything
branch at git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm
and is updated there every 2-3 working days
------------------------------------------------------
From: Charan Teja Kalla <quic_charante@quicinc.com>
Subject: mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5
Date: Fri, 26 Aug 2022 12:26:33 +0530
rename label `loop' to `ext_put_continue' per David
Link: https://lkml.kernel.org/r/1661496993-11473-1-git-send-email-quic_charante@quicinc.com
Signed-off-by: Charan Teja Kalla <quic_charante@quicinc.com>
Suggested-by: David Hildenbrand <david@redhat.com>
Suggested-by: Michal Hocko <mhocko@suse.com>
Cc: Fernand Sieber <sieberf@amazon.com>
Cc: Minchan Kim <minchan@google.com>
Cc: Pasha Tatashin <pasha.tatashin@soleen.com>
Cc: Pavan Kondeti <quic_pkondeti@quicinc.com>
Cc: SeongJae Park <sjpark@amazon.de>
Cc: Shakeel Butt <shakeelb@google.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: William Kucharski <william.kucharski@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
mm/page_owner.c | 18 +++++++++---------
1 file changed, 9 insertions(+), 9 deletions(-)
--- a/mm/page_owner.c~mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5
+++ a/mm/page_owner.c
@@ -326,7 +326,7 @@ void pagetypeinfo_showmixedcount_print(s
continue;
if (!test_bit(PAGE_EXT_OWNER_ALLOCATED, &page_ext->flags))
- goto loop;
+ goto ext_put_continue;
page_owner = get_page_owner(page_ext);
page_mt = gfp_migratetype(page_owner->gfp_mask);
@@ -341,7 +341,7 @@ void pagetypeinfo_showmixedcount_print(s
break;
}
pfn += (1UL << page_owner->order) - 1;
-loop:
+ext_put_continue:
page_ext_put(page_ext);
}
}
@@ -561,14 +561,14 @@ read_page_owner(struct file *file, char
* because we don't hold the zone lock.
*/
if (!test_bit(PAGE_EXT_OWNER, &page_ext->flags))
- goto loop;
+ goto ext_put_continue;
/*
* Although we do have the info about past allocation of free
* pages, it's not relevant for current memory usage.
*/
if (!test_bit(PAGE_EXT_OWNER_ALLOCATED, &page_ext->flags))
- goto loop;
+ goto ext_put_continue;
page_owner = get_page_owner(page_ext);
@@ -577,7 +577,7 @@ read_page_owner(struct file *file, char
* would inflate the stats.
*/
if (!IS_ALIGNED(pfn, 1 << page_owner->order))
- goto loop;
+ goto ext_put_continue;
/*
* Access to page_ext->handle isn't synchronous so we should
@@ -585,7 +585,7 @@ read_page_owner(struct file *file, char
*/
handle = READ_ONCE(page_owner->handle);
if (!handle)
- goto loop;
+ goto ext_put_continue;
/* Record the next PFN to read in the file offset */
*ppos = (pfn - min_low_pfn) + 1;
@@ -594,7 +594,7 @@ read_page_owner(struct file *file, char
page_ext_put(page_ext);
return print_page_owner(buf, count, pfn, page,
&page_owner_tmp, handle);
-loop:
+ext_put_continue:
page_ext_put(page_ext);
}
@@ -654,13 +654,13 @@ static void init_pages_in_zone(pg_data_t
/* Maybe overlapping zone */
if (test_bit(PAGE_EXT_OWNER, &page_ext->flags))
- goto loop;
+ goto ext_put_continue;
/* Found early allocated page */
__set_page_owner_handle(page_ext, early_handle,
0, 0);
count++;
-loop:
+ext_put_continue:
page_ext_put(page_ext);
}
cond_resched();
_
Patches currently in -mm which might be from quic_charante@quicinc.com are
mm-page_ext-remove-unused-variable-in-offline_page_ext.patch
mm-cma_debug-show-complete-cma-name-in-debugfs-directories.patch
mm-oom_kill-add-trace-logs-in-process_mrelease-system-call.patch
mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline.patch
mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2022-08-27 3:20 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-27 3:20 + mm-fix-use-after-free-of-page_ext-after-race-with-memory-offline-v5.patch added to mm-unstable branch Andrew Morton
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.