Skip to content

Commit

Permalink
Merge branch 'akpm' (patches from Andrew)
Browse files Browse the repository at this point in the history
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
  • Loading branch information
Linus Torvalds committed Apr 27, 2022
2 parents e4d8a29 + 5603f9b commit 8f4dd16
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
5 changes: 3 additions & 2 deletions Documentation/vm/page_owner.rst
Original file line number Diff line number Diff line change
Expand Up @@ -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.
Expand All @@ -122,7 +122,7 @@ Usage
-s Sort by stack trace.
-t Sort by times (default).

additional function:
additional function::

Cull:
--cull <rules>
Expand Down Expand Up @@ -153,6 +153,7 @@ Usage

STANDARD FORMAT SPECIFIERS
==========================
::

KEY LONG DESCRIPTION
p pid process ID
Expand Down
7 changes: 7 additions & 0 deletions mm/kasan/quarantine.c
Original file line number Diff line number Diff line change
Expand Up @@ -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);
}
Expand Down

0 comments on commit 8f4dd16

Please sign in to comment.