On Wed, 10 Jul 2019 17:20:56 -0700 Shakeel Butt shakeelb@google.com wrote:
--- a/mm/z3fold.c~mm-z3foldc-lock-z3fold-page-before-__setpagemovable +++ a/mm/z3fold.c @@ -924,7 +924,16 @@ retry: set_bit(PAGE_HEADLESS, &page->private); goto headless; }
__SetPageMovable(page, pool->inode->i_mapping);
if (can_sleep) {
lock_page(page);
__SetPageMovable(page, pool->inode->i_mapping);
unlock_page(page);
} else {
if (!trylock_page(page)) {
Oops, the above should be just trylock_page() without the '!'.
Sigh.
--- a/include/linux/pagemap.h~a +++ a/include/linux/pagemap.h @@ -451,6 +451,9 @@ extern int __lock_page_or_retry(struct p 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);
Andrew, can you please fix this in-place or do you want a new version to be posted.
Thanks, I'll fix.