diff options
author | 2021-04-29 11:09:31 -0400 | |
---|---|---|
committer | 2021-10-18 07:49:40 -0400 | |
commit | 0d31125d2d3267ec349796418a16761bbda20387 (patch) | |
tree | 0c8d48387f014681277dde1285d675fa675951c9 /include | |
parent | mm/lru: Convert __pagevec_lru_add_fn to take a folio (diff) | |
download | linux-0d31125d2d3267ec349796418a16761bbda20387.tar.gz linux-0d31125d2d3267ec349796418a16761bbda20387.tar.bz2 linux-0d31125d2d3267ec349796418a16761bbda20387.zip |
mm/lru: Add folio_add_lru()
Reimplement lru_cache_add() as a wrapper around folio_add_lru().
Saves 159 bytes of kernel text due to removing calls to compound_head().
Signed-off-by: Matthew Wilcox (Oracle) <willy@infradead.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: David Howells <dhowells@redhat.com>
Acked-by: Vlastimil Babka <vbabka@suse.cz>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/swap.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/swap.h b/include/linux/swap.h index 892faac942da..cdf0957a88a4 100644 --- a/include/linux/swap.h +++ b/include/linux/swap.h @@ -351,6 +351,7 @@ extern unsigned long nr_free_buffer_pages(void); extern void lru_note_cost(struct lruvec *lruvec, bool file, unsigned int nr_pages); extern void lru_note_cost_folio(struct folio *); +extern void folio_add_lru(struct folio *); extern void lru_cache_add(struct page *); void mark_page_accessed(struct page *); void folio_mark_accessed(struct folio *); |