From f445884562dd8bc51eb4136bd21f014403d1813d Mon Sep 17 00:00:00 2001 From: Andrew Morton Date: Thu, 11 Jul 2019 20:54:59 -0700 Subject: include/linux/pagemap.h: document trylock_page() return value Cc: Henry Burns Cc: Jonathan Adams Cc: David Rientjes Cc: Mike Rapoport Cc: Vitaly Wool Cc: Xidong Wang Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- include/linux/pagemap.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'include') diff --git a/include/linux/pagemap.h b/include/linux/pagemap.h index fe0b29bf2df7..6fd0d3aa492c 100644 --- a/include/linux/pagemap.h +++ b/include/linux/pagemap.h @@ -452,6 +452,9 @@ extern int __lock_page_or_retry(struct page *page, struct mm_struct *mm, unsigned int flags); extern void unlock_page(struct page *page); +/* + * Return true if the page was successfully locked + */ static inline int trylock_page(struct page *page) { page = compound_head(page); -- cgit