Re: [PATCH 4/9] mm: Make free_compound_page() static

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]


On 15.08.23 09:47, David Hildenbrand wrote:
On 15.08.23 05:26, Matthew Wilcox (Oracle) wrote:
free_compound_page() is the only remaining dynamic destructor.
Call it unconditionally from destroy_large_folio() and convert it
to take a folio.  It used to be the last thing called from
free_transhuge_folio(), and the call from destroy_large_folio()
will take care of that case too.

This was the last entry in the compound_page_dtors array, so delete it
and reword the comments that referred to it.

Signed-off-by: Matthew Wilcox (Oracle) <willy@xxxxxxxxxxxxx>


   int min_free_kbytes = 1024;
   int user_min_free_kbytes = -1;
   static int watermark_boost_factor __read_mostly = 15000;
@@ -587,17 +582,17 @@ static inline void free_the_page(struct page *page, unsigned int order)
    * The remaining PAGE_SIZE pages are called "tail pages". PageTail() is encoded
    * in bit 0 of page->compound_head. The rest of bits is pointer to head page.
- * The first tail page's ->compound_dtor holds the offset in array of compound
- * page destructors. See compound_page_dtors.
+ * The first tail page's ->compound_dtor describes how to destroy the
+ * compound page.
    * The first tail page's ->compound_order holds the order of allocation.
    * This usage means that zero-order pages may not be compound.
-void free_compound_page(struct page *page)
+static void free_compound_page(struct folio *folio)

"free_folio", maybe? Doesn't seem to be taken yet.

Ah, I see it gets removed in the following patch.


David / dhildenb

[Index of Archives]     [Linux Samsung SoC]     [Linux Rockchip SoC]     [Linux Actions SoC]     [Linux for Synopsys ARC Processors]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux