mm/writeback: Add __folio_end_writeback()
test_clear_page_writeback() is actually an mm-internal function, although it's named as if it's a pagecache function. Move it to mm/internal.h, rename it to __folio_end_writeback() and change the return type to bool. The conversion from page to folio is mostly about accounting the number of pages being written back, although it does eliminate a couple of 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>
This commit is contained in:
@@ -657,7 +657,6 @@ static __always_inline void SetPageUptodate(struct page *page)
|
||||
|
||||
CLEARPAGEFLAG(Uptodate, uptodate, PF_NO_TAIL)
|
||||
|
||||
int test_clear_page_writeback(struct page *page);
|
||||
int __test_set_page_writeback(struct page *page, bool keep_write);
|
||||
|
||||
#define test_set_page_writeback(page) \
|
||||
|
||||
Reference in New Issue
Block a user