diff options
author | Matthew Wilcox (Oracle) <willy@infradead.org> | 2022-01-29 22:16:54 +0100 |
---|---|---|
committer | Matthew Wilcox (Oracle) <willy@infradead.org> | 2022-03-21 18:01:35 +0100 |
commit | 84fbbe21894bb9be8e16df408cbfbb9466fe396d (patch) | |
tree | e908796cd1ee4ef4f693807f82ebaaa6a15f9b8f /mm/page_idle.c | |
parent | mm/rmap: Convert rmap_walk() to take a folio (diff) | |
download | linux-84fbbe21894bb9be8e16df408cbfbb9466fe396d.tar.xz linux-84fbbe21894bb9be8e16df408cbfbb9466fe396d.zip |
mm/rmap: Constify the rmap_walk_control argument
The rmap walking functions do not modify the rmap_walk_control, and
page_idle_clear_pte_refs() takes advantage of that to move construction
of the rmap_walk_control to compile time. This lets us remove an
unclean cast.
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Diffstat (limited to 'mm/page_idle.c')
-rw-r--r-- | mm/page_idle.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/page_idle.c b/mm/page_idle.c index e34ba04e22e2..fc0435abf909 100644 --- a/mm/page_idle.c +++ b/mm/page_idle.c @@ -103,7 +103,7 @@ static void page_idle_clear_pte_refs(struct page *page) if (need_lock && !folio_trylock(folio)) return; - rmap_walk(folio, (struct rmap_walk_control *)&rwc); + rmap_walk(folio, &rwc); if (need_lock) folio_unlock(folio); |