From: David Hildenbrand <david@redhat.com>
To: "Matthew Wilcox (Oracle)" <willy@infradead.org>,
Andrew Morton <akpm@linux-foundation.org>
Cc: linux-mm@kvack.org
Subject: Re: [PATCH 9/9] mm: Remove page_add_new_anon_rmap and lru_cache_add_inactive_or_unevictable
Date: Tue, 12 Dec 2023 14:21:48 +0100 [thread overview]
Message-ID: <d1d86f49-c0f6-4a5e-b38f-9eae40218a9c@redhat.com> (raw)
In-Reply-To: <20231211162214.2146080-10-willy@infradead.org>
On 11.12.23 17:22, Matthew Wilcox (Oracle) wrote:
> All callers have now been converted to folio_add_new_anon_rmap() and
> folio_add_lru_vma() so we can remove the wrapper.
>
> Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
> ---
> include/linux/rmap.h | 2 --
> include/linux/swap.h | 3 ---
> mm/folio-compat.c | 16 ----------------
> 3 files changed, 21 deletions(-)
>
> diff --git a/include/linux/rmap.h b/include/linux/rmap.h
> index af6a32b6f3e7..0ae2bb0e77f5 100644
> --- a/include/linux/rmap.h
> +++ b/include/linux/rmap.h
> @@ -197,8 +197,6 @@ typedef int __bitwise rmap_t;
> void folio_move_anon_rmap(struct folio *, struct vm_area_struct *);
> void page_add_anon_rmap(struct page *, struct vm_area_struct *,
> unsigned long address, rmap_t flags);
> -void page_add_new_anon_rmap(struct page *, struct vm_area_struct *,
> - unsigned long address);
> void folio_add_new_anon_rmap(struct folio *, struct vm_area_struct *,
> unsigned long address);
> void page_add_file_rmap(struct page *, struct vm_area_struct *,
> diff --git a/include/linux/swap.h b/include/linux/swap.h
> index 4f25b1237364..edc0f2c8ce01 100644
> --- a/include/linux/swap.h
> +++ b/include/linux/swap.h
> @@ -397,9 +397,6 @@ void folio_deactivate(struct folio *folio);
> void folio_mark_lazyfree(struct folio *folio);
> extern void swap_setup(void);
>
> -extern void lru_cache_add_inactive_or_unevictable(struct page *page,
> - struct vm_area_struct *vma);
> -
> /* linux/mm/vmscan.c */
> extern unsigned long zone_reclaimable_pages(struct zone *zone);
> extern unsigned long try_to_free_pages(struct zonelist *zonelist, int order,
> diff --git a/mm/folio-compat.c b/mm/folio-compat.c
> index aee3b9a16828..50412014f16f 100644
> --- a/mm/folio-compat.c
> +++ b/mm/folio-compat.c
> @@ -77,12 +77,6 @@ bool redirty_page_for_writepage(struct writeback_control *wbc,
> }
> EXPORT_SYMBOL(redirty_page_for_writepage);
>
> -void lru_cache_add_inactive_or_unevictable(struct page *page,
> - struct vm_area_struct *vma)
> -{
> - folio_add_lru_vma(page_folio(page), vma);
> -}
> -
> int add_to_page_cache_lru(struct page *page, struct address_space *mapping,
> pgoff_t index, gfp_t gfp)
> {
> @@ -122,13 +116,3 @@ void putback_lru_page(struct page *page)
> {
> folio_putback_lru(page_folio(page));
> }
> -
> -#ifdef CONFIG_MMU
> -void page_add_new_anon_rmap(struct page *page, struct vm_area_struct *vma,
> - unsigned long address)
> -{
> - VM_BUG_ON_PAGE(PageTail(page), page);
> -
> - return folio_add_new_anon_rmap((struct folio *)page, vma, address);
> -}
> -#endif
Reviewed-by: David Hildenbrand <david@redhat.com>
--
Cheers,
David / dhildenb
prev parent reply other threads:[~2023-12-12 13:21 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-12-11 16:22 [PATCH 0/9] Finish two folio conversions Matthew Wilcox (Oracle)
2023-12-11 16:22 ` [PATCH 1/9] mm: Convert ksm_might_need_to_copy() to work on folios Matthew Wilcox (Oracle)
2023-12-12 12:32 ` David Hildenbrand
2023-12-12 12:43 ` Matthew Wilcox
2023-12-12 12:43 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 2/9] mm: Simplify the assertions in unuse_pte() Matthew Wilcox (Oracle)
2023-12-12 12:26 ` David Hildenbrand
2023-12-12 13:52 ` Matthew Wilcox
2023-12-12 13:55 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 3/9] mm: Convert unuse_pte() to use a folio throughout Matthew Wilcox (Oracle)
2023-12-11 16:22 ` [PATCH 4/9] mm: Remove some calls to page_add_new_anon_rmap() Matthew Wilcox (Oracle)
2023-12-12 13:20 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 5/9] mm: Remove stale example from comment Matthew Wilcox (Oracle)
2023-12-12 13:20 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 6/9] mm: Remove references to page_add_new_anon_rmap in comments Matthew Wilcox (Oracle)
2023-12-12 13:20 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 7/9] mm: Convert migrate_vma_insert_page() to use a folio Matthew Wilcox (Oracle)
2023-12-11 22:17 ` Alistair Popple
2023-12-12 13:21 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 8/9] mm: Convert collapse_huge_page() " Matthew Wilcox (Oracle)
2023-12-12 13:21 ` David Hildenbrand
2023-12-11 16:22 ` [PATCH 9/9] mm: Remove page_add_new_anon_rmap and lru_cache_add_inactive_or_unevictable Matthew Wilcox (Oracle)
2023-12-12 13:21 ` David Hildenbrand [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d1d86f49-c0f6-4a5e-b38f-9eae40218a9c@redhat.com \
--to=david@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=linux-mm@kvack.org \
--cc=willy@infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox