mirror of
https://gitee.com/bianbu-linux/linux-6.6
synced 2025-04-26 14:17:26 -04:00
new helper: put_and_unmap_page()
kunmap_local() + put_page(), as done by e.g. ext2 directory handling. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
This commit is contained in:
parent
fe15c26ee2
commit
849ad04cf5
1 changed files with 6 additions and 0 deletions
|
@ -481,4 +481,10 @@ static inline void folio_zero_range(struct folio *folio,
|
||||||
zero_user_segments(&folio->page, start, start + length, 0, 0);
|
zero_user_segments(&folio->page, start, start + length, 0, 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static inline void put_and_unmap_page(struct page *page, void *addr)
|
||||||
|
{
|
||||||
|
kunmap_local(addr);
|
||||||
|
put_page(page);
|
||||||
|
}
|
||||||
|
|
||||||
#endif /* _LINUX_HIGHMEM_H */
|
#endif /* _LINUX_HIGHMEM_H */
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue