Commit 89be82b4 authored by Kemeng Shi's avatar Kemeng Shi Committed by Andrew Morton

mm/rmap: correct stale comment of rmap_walk_anon and rmap_walk_file

1. update page to folio in comment
2. add comment of new added @locked

Link: https://lkml.kernel.org/r/20230718092136.1935789-1-shikemeng@huaweicloud.comSigned-off-by: default avatarKemeng Shi <shikemeng@huaweicloud.com>
Reviewed-by: default avatarDavid Hildenbrand <david@redhat.com>
Reviewed-by: default avatarMatthew Wilcox (Oracle) <willy@infradead.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent cabdf74e
...@@ -2397,11 +2397,12 @@ static struct anon_vma *rmap_walk_anon_lock(struct folio *folio, ...@@ -2397,11 +2397,12 @@ static struct anon_vma *rmap_walk_anon_lock(struct folio *folio,
/* /*
* rmap_walk_anon - do something to anonymous page using the object-based * rmap_walk_anon - do something to anonymous page using the object-based
* rmap method * rmap method
* @page: the page to be handled * @folio: the folio to be handled
* @rwc: control variable according to each walk type * @rwc: control variable according to each walk type
* @locked: caller holds relevant rmap lock
* *
* Find all the mappings of a page using the mapping pointer and the vma chains * Find all the mappings of a folio using the mapping pointer and the vma
* contained in the anon_vma struct it points to. * chains contained in the anon_vma struct it points to.
*/ */
static void rmap_walk_anon(struct folio *folio, static void rmap_walk_anon(struct folio *folio,
struct rmap_walk_control *rwc, bool locked) struct rmap_walk_control *rwc, bool locked)
...@@ -2445,10 +2446,11 @@ static void rmap_walk_anon(struct folio *folio, ...@@ -2445,10 +2446,11 @@ static void rmap_walk_anon(struct folio *folio,
/* /*
* rmap_walk_file - do something to file page using the object-based rmap method * rmap_walk_file - do something to file page using the object-based rmap method
* @page: the page to be handled * @folio: the folio to be handled
* @rwc: control variable according to each walk type * @rwc: control variable according to each walk type
* @locked: caller holds relevant rmap lock
* *
* Find all the mappings of a page using the mapping pointer and the vma chains * Find all the mappings of a folio using the mapping pointer and the vma chains
* contained in the address_space struct it points to. * contained in the address_space struct it points to.
*/ */
static void rmap_walk_file(struct folio *folio, static void rmap_walk_file(struct folio *folio,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment