From: kernel test robot <lkp@intel.com>
To: Ning Zhang <ningzhang@linux.alibaba.com>
Cc: llvm@lists.linux.dev, kbuild-all@lists.01.org
Subject: Re: [RFC 1/6] mm, thp: introduce thp zero subpages reclaim
Date: Fri, 29 Oct 2021 04:50:21 +0800 [thread overview]
Message-ID: <202110290440.seethEPd-lkp@intel.com> (raw)
In-Reply-To: <1635422215-99394-2-git-send-email-ningzhang@linux.alibaba.com>
[-- Attachment #1: Type: text/plain, Size: 13257 bytes --]
Hi Ning,
[FYI, it's a private test report for your RFC patch.]
[auto build test ERROR on linus/master]
[also build test ERROR on v5.15-rc7]
[cannot apply to hnaz-mm/master next-20211028]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Ning-Zhang/Reclaim-zero-subpages-of-thp-to-avoid-memory-bloat/20211028-200001
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 1fc596a56b334f4d593a2b49e5ff55af6aaa0816
config: arm-randconfig-c002-20211028 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 5db7568a6a1fcb408eb8988abdaff2a225a8eb72)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
# https://github.com/0day-ci/linux/commit/ba9f8c1a43c2d9ab2d2ac5696aaffbeaf043fa02
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Ning-Zhang/Reclaim-zero-subpages-of-thp-to-avoid-memory-bloat/20211028-200001
git checkout ba9f8c1a43c2d9ab2d2ac5696aaffbeaf043fa02
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
mm/vmscan.c:1340:6: warning: variable 'err' set but not used [-Wunused-but-set-variable]
int err;
^
>> mm/vmscan.c:2803:36: error: no member named 'hpage_reclaim_queue' in 'struct mem_cgroup_per_node'
hr_queue = &memcg->nodeinfo[nid]->hpage_reclaim_queue;
~~~~~~~~~~~~~~~~~~~~ ^
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:290:10: note: expanded from macro '__native_word'
(sizeof(t) == sizeof(char) || sizeof(t) == sizeof(short) || \
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:290:39: note: expanded from macro '__native_word'
(sizeof(t) == sizeof(char) || sizeof(t) == sizeof(short) || \
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:291:10: note: expanded from macro '__native_word'
sizeof(t) == sizeof(int) || sizeof(t) == sizeof(long))
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:291:38: note: expanded from macro '__native_word'
sizeof(t) == sizeof(int) || sizeof(t) == sizeof(long))
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:48: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:65: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
include/linux/compiler_types.h:279:13: note: expanded from macro '__unqual_scalar_typeof'
_Generic((x), \
^
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:65: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
include/linux/compiler_types.h:286:15: note: expanded from macro '__unqual_scalar_typeof'
default: (x)))
^
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:72: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
mm/vmscan.c:2804:6: error: invalid argument type 'void' to unary expression
if (!READ_ONCE(memcg->thp_reclaim))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/vmscan.c:2813:7: error: implicit declaration of function 'zsr_get_hpage' [-Werror,-Wimplicit-function-declaration]
if (zsr_get_hpage(hr_queue, &page))
^
>> mm/vmscan.c:2819:19: error: implicit declaration of function 'zsr_reclaim_hpage' [-Werror,-Wimplicit-function-declaration]
nr_reclaimed += zsr_reclaim_hpage(lruvec, page);
^
1 warning and 12 errors generated.
vim +2803 mm/vmscan.c
2784
2785 #ifdef CONFIG_MEMCG
2786 #define MAX_SCAN_HPAGE 32UL
2787 /*
2788 * Try to reclaim the zero subpages for the transparent huge page.
2789 */
2790 static unsigned long reclaim_hpage_zero_subpages(struct lruvec *lruvec,
2791 int priority,
2792 unsigned long nr_to_reclaim)
2793 {
2794 struct mem_cgroup *memcg;
2795 struct hpage_reclaim *hr_queue;
2796 int nid = lruvec->pgdat->node_id;
2797 unsigned long nr_reclaimed = 0, nr_scanned = 0, nr_to_scan;
2798
2799 memcg = lruvec_memcg(lruvec);
2800 if (!memcg)
2801 goto out;
2802
> 2803 hr_queue = &memcg->nodeinfo[nid]->hpage_reclaim_queue;
2804 if (!READ_ONCE(memcg->thp_reclaim))
2805 goto out;
2806
2807 /* The last scan loop will scan all the huge pages.*/
2808 nr_to_scan = priority == 0 ? 0 : MAX_SCAN_HPAGE;
2809
2810 do {
2811 struct page *page = NULL;
2812
> 2813 if (zsr_get_hpage(hr_queue, &page))
2814 break;
2815
2816 if (!page)
2817 continue;
2818
> 2819 nr_reclaimed += zsr_reclaim_hpage(lruvec, page);
2820
2821 cond_resched();
2822
2823 } while ((nr_reclaimed < nr_to_reclaim) && (++nr_scanned != nr_to_scan));
2824 out:
2825 return nr_reclaimed;
2826 }
2827 #else
2828 static unsigned long reclaim_hpage_zero_subpages(struct lruvec *lruvec,
2829 int priority,
2830 unsigned long nr_to_reclaim)
2831 {
2832 return 0;
2833 }
2834 #endif
2835
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 29712 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: Re: [RFC 1/6] mm, thp: introduce thp zero subpages reclaim
Date: Fri, 29 Oct 2021 04:50:21 +0800 [thread overview]
Message-ID: <202110290440.seethEPd-lkp@intel.com> (raw)
In-Reply-To: <1635422215-99394-2-git-send-email-ningzhang@linux.alibaba.com>
[-- Attachment #1: Type: text/plain, Size: 13500 bytes --]
Hi Ning,
[FYI, it's a private test report for your RFC patch.]
[auto build test ERROR on linus/master]
[also build test ERROR on v5.15-rc7]
[cannot apply to hnaz-mm/master next-20211028]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Ning-Zhang/Reclaim-zero-subpages-of-thp-to-avoid-memory-bloat/20211028-200001
base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git 1fc596a56b334f4d593a2b49e5ff55af6aaa0816
config: arm-randconfig-c002-20211028 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 5db7568a6a1fcb408eb8988abdaff2a225a8eb72)
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# install arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
# https://github.com/0day-ci/linux/commit/ba9f8c1a43c2d9ab2d2ac5696aaffbeaf043fa02
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Ning-Zhang/Reclaim-zero-subpages-of-thp-to-avoid-memory-bloat/20211028-200001
git checkout ba9f8c1a43c2d9ab2d2ac5696aaffbeaf043fa02
# save the attached .config to linux build tree
mkdir build_dir
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All errors (new ones prefixed by >>):
mm/vmscan.c:1340:6: warning: variable 'err' set but not used [-Wunused-but-set-variable]
int err;
^
>> mm/vmscan.c:2803:36: error: no member named 'hpage_reclaim_queue' in 'struct mem_cgroup_per_node'
hr_queue = &memcg->nodeinfo[nid]->hpage_reclaim_queue;
~~~~~~~~~~~~~~~~~~~~ ^
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:290:10: note: expanded from macro '__native_word'
(sizeof(t) == sizeof(char) || sizeof(t) == sizeof(short) || \
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:290:39: note: expanded from macro '__native_word'
(sizeof(t) == sizeof(char) || sizeof(t) == sizeof(short) || \
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:291:10: note: expanded from macro '__native_word'
sizeof(t) == sizeof(int) || sizeof(t) == sizeof(long))
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:35: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:291:38: note: expanded from macro '__native_word'
sizeof(t) == sizeof(int) || sizeof(t) == sizeof(long))
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:49:33: note: expanded from macro 'READ_ONCE'
compiletime_assert_rwonce_type(x); \
^
include/asm-generic/rwonce.h:36:48: note: expanded from macro 'compiletime_assert_rwonce_type'
compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
^
include/linux/compiler_types.h:322:22: note: expanded from macro 'compiletime_assert'
_compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
^~~~~~~~~
include/linux/compiler_types.h:310:23: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^~~~~~~~~
include/linux/compiler_types.h:302:9: note: expanded from macro '__compiletime_assert'
if (!(condition)) \
^~~~~~~~~
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:65: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
include/linux/compiler_types.h:279:13: note: expanded from macro '__unqual_scalar_typeof'
_Generic((x), \
^
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:65: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
include/linux/compiler_types.h:286:15: note: expanded from macro '__unqual_scalar_typeof'
default: (x)))
^
mm/vmscan.c:2804:24: error: no member named 'thp_reclaim' in 'struct mem_cgroup'
if (!READ_ONCE(memcg->thp_reclaim))
~~~~~ ^
include/asm-generic/rwonce.h:50:14: note: expanded from macro 'READ_ONCE'
__READ_ONCE(x); \
^
include/asm-generic/rwonce.h:44:72: note: expanded from macro '__READ_ONCE'
#define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
^
mm/vmscan.c:2804:6: error: invalid argument type 'void' to unary expression
if (!READ_ONCE(memcg->thp_reclaim))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/vmscan.c:2813:7: error: implicit declaration of function 'zsr_get_hpage' [-Werror,-Wimplicit-function-declaration]
if (zsr_get_hpage(hr_queue, &page))
^
>> mm/vmscan.c:2819:19: error: implicit declaration of function 'zsr_reclaim_hpage' [-Werror,-Wimplicit-function-declaration]
nr_reclaimed += zsr_reclaim_hpage(lruvec, page);
^
1 warning and 12 errors generated.
vim +2803 mm/vmscan.c
2784
2785 #ifdef CONFIG_MEMCG
2786 #define MAX_SCAN_HPAGE 32UL
2787 /*
2788 * Try to reclaim the zero subpages for the transparent huge page.
2789 */
2790 static unsigned long reclaim_hpage_zero_subpages(struct lruvec *lruvec,
2791 int priority,
2792 unsigned long nr_to_reclaim)
2793 {
2794 struct mem_cgroup *memcg;
2795 struct hpage_reclaim *hr_queue;
2796 int nid = lruvec->pgdat->node_id;
2797 unsigned long nr_reclaimed = 0, nr_scanned = 0, nr_to_scan;
2798
2799 memcg = lruvec_memcg(lruvec);
2800 if (!memcg)
2801 goto out;
2802
> 2803 hr_queue = &memcg->nodeinfo[nid]->hpage_reclaim_queue;
2804 if (!READ_ONCE(memcg->thp_reclaim))
2805 goto out;
2806
2807 /* The last scan loop will scan all the huge pages.*/
2808 nr_to_scan = priority == 0 ? 0 : MAX_SCAN_HPAGE;
2809
2810 do {
2811 struct page *page = NULL;
2812
> 2813 if (zsr_get_hpage(hr_queue, &page))
2814 break;
2815
2816 if (!page)
2817 continue;
2818
> 2819 nr_reclaimed += zsr_reclaim_hpage(lruvec, page);
2820
2821 cond_resched();
2822
2823 } while ((nr_reclaimed < nr_to_reclaim) && (++nr_scanned != nr_to_scan));
2824 out:
2825 return nr_reclaimed;
2826 }
2827 #else
2828 static unsigned long reclaim_hpage_zero_subpages(struct lruvec *lruvec,
2829 int priority,
2830 unsigned long nr_to_reclaim)
2831 {
2832 return 0;
2833 }
2834 #endif
2835
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 29712 bytes --]
next prev parent reply other threads:[~2021-10-28 20:51 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-28 11:56 [RFC 0/6] Reclaim zero subpages of thp to avoid memory bloat Ning Zhang
2021-10-28 11:56 ` [RFC 1/6] mm, thp: introduce thp zero subpages reclaim Ning Zhang
2021-10-28 12:53 ` Matthew Wilcox
2021-10-29 12:16 ` ning zhang
2021-10-28 20:50 ` kernel test robot [this message]
2021-10-28 20:50 ` kernel test robot
2021-10-28 11:56 ` [RFC 2/6] mm, thp: add a global interface for zero subapges reclaim Ning Zhang
2021-10-29 0:44 ` kernel test robot
2021-10-29 0:44 ` kernel test robot
2021-10-28 11:56 ` [RFC 3/6] mm, thp: introduce zero subpages reclaim threshold Ning Zhang
2021-10-28 11:56 ` [RFC 4/6] mm, thp: introduce a controller to trigger zero subpages reclaim Ning Zhang
2021-10-28 11:56 ` [RFC 5/6] mm, thp: add some statistics for " Ning Zhang
2021-10-28 11:56 ` [RFC 6/6] mm, thp: add document " Ning Zhang
2021-10-28 14:13 ` [RFC 0/6] Reclaim zero subpages of thp to avoid memory bloat Kirill A. Shutemov
2021-10-29 12:07 ` ning zhang
2021-10-29 16:56 ` Yang Shi
2021-11-01 2:50 ` ning zhang
2021-10-29 13:38 ` Michal Hocko
2021-10-29 16:12 ` ning zhang
2021-11-01 9:20 ` Michal Hocko
2021-11-08 3:24 ` ning zhang
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202110290440.seethEPd-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
--cc=llvm@lists.linux.dev \
--cc=ningzhang@linux.alibaba.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.