Merge branch 'akpm' (patches from Andrew)

Merge fixes from Andrew Morton:
 "Two patches.

  Subsystems affected by this patch series: mm/kasan and mm/debug"

* emailed patches from Andrew Morton <akpm@linux-foundation.org>:
  docs: vm/page_owner: use literal blocks for param description
  kasan: prevent cpu_quarantine corruption when CPU offline and cache shrink occur at same time
This commit is contained in:
Linus Torvalds 2022-04-27 13:44:37 -07:00
commit 8f4dd16603
2 changed files with 10 additions and 2 deletions

View File

@ -110,7 +110,7 @@ Usage
If you want to sort by the page nums of buf, use the ``-m`` parameter.
The detailed parameters are:
fundamental function:
fundamental function::
Sort:
-a Sort by memory allocation time.
@ -122,7 +122,7 @@ Usage
-s Sort by stack trace.
-t Sort by times (default).
additional function:
additional function::
Cull:
--cull <rules>
@ -153,6 +153,7 @@ Usage
STANDARD FORMAT SPECIFIERS
==========================
::
KEY LONG DESCRIPTION
p pid process ID

View File

@ -315,6 +315,13 @@ static void per_cpu_remove_cache(void *arg)
struct qlist_head *q;
q = this_cpu_ptr(&cpu_quarantine);
/*
* Ensure the ordering between the writing to q->offline and
* per_cpu_remove_cache. Prevent cpu_quarantine from being corrupted
* by interrupt.
*/
if (READ_ONCE(q->offline))
return;
qlist_move_cache(q, &to_free, cache);
qlist_free_all(&to_free, cache);
}