All of lore.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Baoquan He <bhe@redhat.com>, linux-mm@kvack.org
Cc: oe-kbuild-all@lists.linux.dev, akpm@linux-foundation.org,
	chrisl@kernel.org, kasong@tencent.com, youngjun.park@lge.com,
	baohua@kernel.org, shikemeng@huaweicloud.com, nphamcs@gmail.com,
	Baoquan He <bhe@redhat.com>
Subject: Re: [PATCH v4 mm-new 1/2] mm/swap: do not choose swap device according to numa node
Date: Sun, 12 Oct 2025 04:45:07 +0800	[thread overview]
Message-ID: <202510120456.vTSygUXV-lkp@intel.com> (raw)
In-Reply-To: <20251011081624.224202-2-bhe@redhat.com>

Hi Baoquan,

kernel test robot noticed the following build errors:

[auto build test ERROR on akpm-mm/mm-everything]

url:    https://github.com/intel-lab-lkp/linux/commits/Baoquan-He/mm-swap-do-not-choose-swap-device-according-to-numa-node/20251011-161743
base:   https://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm.git mm-everything
patch link:    https://lore.kernel.org/r/20251011081624.224202-2-bhe%40redhat.com
patch subject: [PATCH v4 mm-new 1/2] mm/swap: do not choose swap device according to numa node
config: i386-buildonly-randconfig-003-20251012 (https://download.01.org/0day-ci/archive/20251012/202510120456.vTSygUXV-lkp@intel.com/config)
compiler: gcc-14 (Debian 14.2.0-19) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20251012/202510120456.vTSygUXV-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202510120456.vTSygUXV-lkp@intel.com/

All error/warnings (new ones prefixed by >>):

   In file included from include/linux/list.h:5,
                    from include/linux/wait.h:7,
                    from include/linux/wait_bit.h:8,
                    from include/linux/fs.h:7,
                    from include/linux/highmem.h:5,
                    from include/linux/bvec.h:10,
                    from include/linux/blk_types.h:10,
                    from include/linux/blkdev.h:9,
                    from mm/swapfile.c:9:
   mm/swapfile.c: In function 'swap_sync_discard':
>> mm/swapfile.c:1395:46: error: 'swap_avail_heads' undeclared (first use in this function); did you mean 'swap_avail_head'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                              ^~~~~~~~~~~~~~~~
   include/linux/container_of.h:20:33: note: in definition of macro 'container_of'
      20 |         void *__mptr = (void *)(ptr);                                   \
         |                                 ^~~
   include/linux/list.h:620:9: note: in expansion of macro 'list_entry'
     620 |         list_entry((ptr)->next, type, member)
         |         ^~~~~~~~~~
   include/linux/list.h:869:20: note: in expansion of macro 'list_first_entry'
     869 |         for (pos = list_first_entry(head, typeof(*pos), member),        \
         |                    ^~~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:46: note: each undeclared identifier is reported only once for each function it appears in
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                              ^~~~~~~~~~~~~~~~
   include/linux/container_of.h:20:33: note: in definition of macro 'container_of'
      20 |         void *__mptr = (void *)(ptr);                                   \
         |                                 ^~~
   include/linux/list.h:620:9: note: in expansion of macro 'list_entry'
     620 |         list_entry((ptr)->next, type, member)
         |         ^~~~~~~~~~
   include/linux/list.h:869:20: note: in expansion of macro 'list_first_entry'
     869 |         for (pos = list_first_entry(head, typeof(*pos), member),        \
         |                    ^~~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from include/linux/init.h:5,
                    from include/linux/printk.h:6,
                    from include/asm-generic/bug.h:22,
                    from arch/x86/include/asm/bug.h:103,
                    from include/linux/bug.h:5,
                    from include/linux/vfsdebug.h:5,
                    from include/linux/fs.h:5:
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:620:9: note: in expansion of macro 'list_entry'
     620 |         list_entry((ptr)->next, type, member)
         |         ^~~~~~~~~~
   include/linux/list.h:869:20: note: in expansion of macro 'list_first_entry'
     869 |         for (pos = list_first_entry(head, typeof(*pos), member),        \
         |                    ^~~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/compiler_types.h:530:27: error: expression in static assertion is not an integer
     530 | #define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
         |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:620:9: note: in expansion of macro 'list_entry'
     620 |         list_entry((ptr)->next, type, member)
         |         ^~~~~~~~~~
   include/linux/list.h:869:20: note: in expansion of macro 'list_first_entry'
     869 |         for (pos = list_first_entry(head, typeof(*pos), member),        \
         |                    ^~~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   In file included from include/uapi/linux/posix_types.h:5,
                    from include/uapi/linux/types.h:14,
                    from include/linux/types.h:6,
                    from include/linux/blkdev.h:8:
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/stddef.h:16:58: note: in definition of macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                                          ^~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:620:9: note: in expansion of macro 'list_entry'
     620 |         list_entry((ptr)->next, type, member)
         |         ^~~~~~~~~~
   include/linux/list.h:869:20: note: in expansion of macro 'list_first_entry'
     869 |         for (pos = list_first_entry(head, typeof(*pos), member),        \
         |                    ^~~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/container_of.h:20:33: note: in definition of macro 'container_of'
      20 |         void *__mptr = (void *)(ptr);                                   \
         |                                 ^~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:870:21: note: in expansion of macro 'list_next_entry'
     870 |                 n = list_next_entry(pos, member);                       \
         |                     ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:870:21: note: in expansion of macro 'list_next_entry'
     870 |                 n = list_next_entry(pos, member);                       \
         |                     ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:870:21: note: in expansion of macro 'list_next_entry'
     870 |                 n = list_next_entry(pos, member);                       \
         |                     ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:22:23: note: in expansion of macro '__same_type'
      22 |                       __same_type(*(ptr), void),                        \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:870:21: note: in expansion of macro 'list_next_entry'
     870 |                 n = list_next_entry(pos, member);                       \
         |                     ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/compiler_types.h:530:27: error: expression in static assertion is not an integer
     530 | #define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
         |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:870:21: note: in expansion of macro 'list_next_entry'
     870 |                 n = list_next_entry(pos, member);                       \
         |                     ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/stddef.h:16:58: note: in definition of macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                                          ^~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:870:21: note: in expansion of macro 'list_next_entry'
     870 |                 n = list_next_entry(pos, member);                       \
         |                     ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/list.h:869:64: warning: left-hand operand of comma expression has no effect [-Wunused-value]
     869 |         for (pos = list_first_entry(head, typeof(*pos), member),        \
         |                                                                ^
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/list.h:773:28: note: in definition of macro 'list_entry_is_head'
     773 |         list_is_head(&pos->member, (head))
         |                            ^~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/container_of.h:20:33: note: in definition of macro 'container_of'
      20 |         void *__mptr = (void *)(ptr);                                   \
         |                                 ^~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:872:27: note: in expansion of macro 'list_next_entry'
     872 |              pos = n, n = list_next_entry(n, member))
         |                           ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:872:27: note: in expansion of macro 'list_next_entry'
     872 |              pos = n, n = list_next_entry(n, member))
         |                           ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:872:27: note: in expansion of macro 'list_next_entry'
     872 |              pos = n, n = list_next_entry(n, member))
         |                           ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:22:23: note: in expansion of macro '__same_type'
      22 |                       __same_type(*(ptr), void),                        \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:872:27: note: in expansion of macro 'list_next_entry'
     872 |              pos = n, n = list_next_entry(n, member))
         |                           ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/compiler_types.h:530:27: error: expression in static assertion is not an integer
     530 | #define __same_type(a, b) __builtin_types_compatible_p(typeof(a), typeof(b))
         |                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/build_bug.h:78:56: note: in definition of macro '__static_assert'
      78 | #define __static_assert(expr, msg, ...) _Static_assert(expr, msg)
         |                                                        ^~~~
   include/linux/container_of.h:21:9: note: in expansion of macro 'static_assert'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |         ^~~~~~~~~~~~~
   include/linux/container_of.h:21:23: note: in expansion of macro '__same_type'
      21 |         static_assert(__same_type(*(ptr), ((type *)0)->member) ||       \
         |                       ^~~~~~~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:872:27: note: in expansion of macro 'list_next_entry'
     872 |              pos = n, n = list_next_entry(n, member))
         |                           ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1395:69: error: 'struct swap_info_struct' has no member named 'avail_lists'; did you mean 'avail_list'?
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |                                                                     ^~~~~~~~~~~
   include/linux/stddef.h:16:58: note: in definition of macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                                          ^~~~~~
   include/linux/list.h:609:9: note: in expansion of macro 'container_of'
     609 |         container_of(ptr, type, member)
         |         ^~~~~~~~~~~~
   include/linux/list.h:667:9: note: in expansion of macro 'list_entry'
     667 |         list_entry((pos)->member.next, typeof(*(pos)), member)
         |         ^~~~~~~~~~
   include/linux/list.h:872:27: note: in expansion of macro 'list_next_entry'
     872 |              pos = n, n = list_next_entry(n, member))
         |                           ^~~~~~~~~~~~~~~
   include/linux/plist.h:197:9: note: in expansion of macro 'list_for_each_entry_safe'
     197 |         list_for_each_entry_safe(pos, n, &(head)->node_list, m.node_list)
         |         ^~~~~~~~~~~~~~~~~~~~~~~~
   mm/swapfile.c:1395:9: note: in expansion of macro 'plist_for_each_entry_safe'
    1395 |         plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
         |         ^~~~~~~~~~~~~~~~~~~~~~~~~
>> mm/swapfile.c:1391:13: warning: variable 'nid' set but not used [-Wunused-but-set-variable]
    1391 |         int nid = numa_node_id();
         |             ^~~
   mm/swapfile.c: In function '__do_sys_swapoff':
   mm/swapfile.c:2893:21: warning: unused variable 'nid' [-Wunused-variable]
    2893 |                 int nid;
         |                     ^~~


vim +1395 mm/swapfile.c

b487a2da3575b6 Kairui Song 2025-03-14  1383  
74cdc690138b65 Kairui Song 2025-10-07  1384  /*
74cdc690138b65 Kairui Song 2025-10-07  1385   * Discard pending clusters in a synchronized way when under high pressure.
74cdc690138b65 Kairui Song 2025-10-07  1386   * Return: true if any cluster is discarded.
74cdc690138b65 Kairui Song 2025-10-07  1387   */
74cdc690138b65 Kairui Song 2025-10-07  1388  static bool swap_sync_discard(void)
74cdc690138b65 Kairui Song 2025-10-07  1389  {
74cdc690138b65 Kairui Song 2025-10-07  1390  	bool ret = false;
74cdc690138b65 Kairui Song 2025-10-07 @1391  	int nid = numa_node_id();
74cdc690138b65 Kairui Song 2025-10-07  1392  	struct swap_info_struct *si, *next;
74cdc690138b65 Kairui Song 2025-10-07  1393  
74cdc690138b65 Kairui Song 2025-10-07  1394  	spin_lock(&swap_avail_lock);
74cdc690138b65 Kairui Song 2025-10-07 @1395  	plist_for_each_entry_safe(si, next, &swap_avail_heads[nid], avail_lists[nid]) {
74cdc690138b65 Kairui Song 2025-10-07  1396  		spin_unlock(&swap_avail_lock);
74cdc690138b65 Kairui Song 2025-10-07  1397  		if (get_swap_device_info(si)) {
74cdc690138b65 Kairui Song 2025-10-07  1398  			if (si->flags & SWP_PAGE_DISCARD)
74cdc690138b65 Kairui Song 2025-10-07  1399  				ret = swap_do_scheduled_discard(si);
74cdc690138b65 Kairui Song 2025-10-07  1400  			put_swap_device(si);
74cdc690138b65 Kairui Song 2025-10-07  1401  		}
74cdc690138b65 Kairui Song 2025-10-07  1402  		if (ret)
74cdc690138b65 Kairui Song 2025-10-07  1403  			break;
74cdc690138b65 Kairui Song 2025-10-07  1404  		spin_lock(&swap_avail_lock);
74cdc690138b65 Kairui Song 2025-10-07  1405  	}
74cdc690138b65 Kairui Song 2025-10-07  1406  	spin_unlock(&swap_avail_lock);
74cdc690138b65 Kairui Song 2025-10-07  1407  
74cdc690138b65 Kairui Song 2025-10-07  1408  	return ret;
74cdc690138b65 Kairui Song 2025-10-07  1409  }
74cdc690138b65 Kairui Song 2025-10-07  1410  

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki


  reply	other threads:[~2025-10-11 20:45 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-10-11  8:16 [PATCH v4 mm-new 0/2] mm/swapfile.c: select the swap device with default priority round robin Baoquan He
2025-10-11  8:16 ` [PATCH v4 mm-new 1/2] mm/swap: do not choose swap device according to numa node Baoquan He
2025-10-11 20:45   ` kernel test robot [this message]
2025-10-11 22:04     ` Andrew Morton
2025-10-12  2:08       ` Baoquan He
2025-10-14 11:56       ` Baoquan He
2025-10-13  6:09   ` Barry Song
2025-10-14 21:50     ` Chris Li
2025-10-15  3:06     ` Baoquan He
2025-10-15  5:02       ` Barry Song
2025-10-15  6:23         ` Chris Li
2025-10-15  8:09           ` Barry Song
2025-10-15 13:27             ` Chris Li
2025-10-11  8:16 ` [PATCH v4 mm-new 2/2] mm/swap: select swap device with default priority round robin Baoquan He
2025-10-12 20:40   ` Barry Song
2025-10-13  3:58     ` Baoquan He
2025-10-13  6:17       ` Barry Song
2025-10-13 23:07         ` Baoquan He
2025-10-14 22:11         ` Chris Li
2025-10-15  4:29           ` Barry Song
2025-10-15  6:24             ` Chris Li
2025-10-14 22:01     ` Chris Li

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=202510120456.vTSygUXV-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=baohua@kernel.org \
    --cc=bhe@redhat.com \
    --cc=chrisl@kernel.org \
    --cc=kasong@tencent.com \
    --cc=linux-mm@kvack.org \
    --cc=nphamcs@gmail.com \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=shikemeng@huaweicloud.com \
    --cc=youngjun.park@lge.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.