Skip to content

Commit a30573b

Browse files
author
Gao Xiang
committed
erofs: fix setting up pcluster for temporary pages
pcluster should be only set up for all managed pages instead of temporary pages. Since it currently uses page->mapping to identify, the impact is minor for now. [ Update: Vladimir reported the kernel log becomes polluted because PAGE_FLAGS_CHECK_AT_FREE flag(s) set if the page allocation debug option is enabled. ] Link: https://lore.kernel.org/r/20201022145724.27284-1-hsiangkao@aol.com Fixes: 5ddcee1 ("erofs: get rid of __stagingpage_alloc helper") Cc: <stable@vger.kernel.org> # 5.5+ Tested-by: Vladimir Zapolskiy <vladimir@tuxera.com> Reviewed-by: Chao Yu <yuchao0@huawei.com> Signed-off-by: Gao Xiang <hsiangkao@redhat.com>
1 parent d3938ee commit a30573b

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

fs/erofs/zdata.c

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1078,8 +1078,11 @@ static struct page *pickup_page_for_submission(struct z_erofs_pcluster *pcl,
10781078
cond_resched();
10791079
goto repeat;
10801080
}
1081-
set_page_private(page, (unsigned long)pcl);
1082-
SetPagePrivate(page);
1081+
1082+
if (tocache) {
1083+
set_page_private(page, (unsigned long)pcl);
1084+
SetPagePrivate(page);
1085+
}
10831086
out: /* the only exit (for tracing and debugging) */
10841087
return page;
10851088
}

0 commit comments

Comments
 (0)