提交 2e5f71ad 编写于 作者: A Alexander Lobakin 提交者: Zheng Zengkai

mm: constify page_is_pfmemalloc() argument

mainline inclusion
from mainline-v5.12-rc1-dontuse
commit 1d7bab6a
category: feature
bugzilla: 173966
CVE: NA

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=1d7bab6a94458e959f3f55788fd50ddc7d97403b

----------------------------------------------------------------------

The function only tests for page->index, so its argument should be
const.
Signed-off-by: NAlexander Lobakin <alobakin@pm.me>
Reviewed-by: NJesse Brandeburg <jesse.brandeburg@intel.com>
Acked-by: NDavid Rientjes <rientjes@google.com>
Signed-off-by: NJakub Kicinski <kuba@kernel.org>
Reviewed-by: NYongxin Li <liyongxin1@huawei.com>
Signed-off-by: NZheng Zengkai <zhengzengkai@huawei.com>
上级 9443ab6c
...@@ -1596,7 +1596,7 @@ struct address_space *page_mapping_file(struct page *page); ...@@ -1596,7 +1596,7 @@ struct address_space *page_mapping_file(struct page *page);
* ALLOC_NO_WATERMARKS and the low watermark was not * ALLOC_NO_WATERMARKS and the low watermark was not
* met implying that the system is under some pressure. * met implying that the system is under some pressure.
*/ */
static inline bool page_is_pfmemalloc(struct page *page) static inline bool page_is_pfmemalloc(const struct page *page)
{ {
/* /*
* Page index cannot be this large so this must be * Page index cannot be this large so this must be
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册