oe-kbuild-all.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [rgushchin:page_counters.1 5/7] include/linux/page_counter.h:20:1: error: unknown type name 'define'
@ 2024-04-30  0:47 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-04-30  0:47 UTC (permalink / raw
  To: Roman Gushchin; +Cc: oe-kbuild-all

tree:   https://github.com/rgushchin/linux.git page_counters.1
head:   74f3bba65f60c295d6ea14d848aaefed4a70c397
commit: 527af2b8159ca031e267813637bebe68bc14875a [5/7] mm: memcg: merge multiple page_counters into a single structure
config: riscv-defconfig (https://download.01.org/0day-ci/archive/20240430/202404300847.ldO30ZB8-lkp@intel.com/config)
compiler: clang version 19.0.0git (https://github.com/llvm/llvm-project 37ae4ad0eef338776c7e2cffb3896153d43dcd90)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240430/202404300847.ldO30ZB8-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/202404300847.ldO30ZB8-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from arch/riscv/kernel/asm-offsets.c:10:
   In file included from include/linux/mm.h:2237:
   include/linux/vmstat.h:514:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
     514 |         return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
         |                               ~~~~~~~~~~~ ^ ~~~
   In file included from arch/riscv/kernel/asm-offsets.c:12:
   In file included from include/linux/suspend.h:5:
   In file included from include/linux/swap.h:9:
   In file included from include/linux/memcontrol.h:18:
>> include/linux/page_counter.h:20:1: error: unknown type name 'define'
      20 | define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
         | ^
>> include/linux/page_counter.h:20:27: error: expected ')'
      20 | define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
         |                           ^
   arch/riscv/include/asm/pgtable-64.h:110:27: note: expanded from macro 'HUGE_MAX_HSTATE'
     110 | #define HUGE_MAX_HSTATE         (2 + (NAPOT_ORDER_MAX - NAPOT_CONT_ORDER_BASE))
         |                                  ^
   include/linux/page_counter.h:20:27: note: to match this '('
   arch/riscv/include/asm/pgtable-64.h:110:26: note: expanded from macro 'HUGE_MAX_HSTATE'
     110 | #define HUGE_MAX_HSTATE         (2 + (NAPOT_ORDER_MAX - NAPOT_CONT_ORDER_BASE))
         |                                 ^
   In file included from arch/riscv/kernel/asm-offsets.c:12:
   In file included from include/linux/suspend.h:5:
   In file included from include/linux/swap.h:9:
   In file included from include/linux/memcontrol.h:18:
>> include/linux/page_counter.h:20:27: error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int]
      20 | define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
         |                           ^
         |                           int
   arch/riscv/include/asm/pgtable-64.h:110:27: note: expanded from macro 'HUGE_MAX_HSTATE'
     110 | #define HUGE_MAX_HSTATE         (2 + (NAPOT_ORDER_MAX - NAPOT_CONT_ORDER_BASE))
         |                                  ^
   In file included from arch/riscv/kernel/asm-offsets.c:12:
   In file included from include/linux/suspend.h:5:
   In file included from include/linux/swap.h:9:
   In file included from include/linux/memcontrol.h:18:
   include/linux/page_counter.h:20:43: error: expected ')'
      20 | define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
         |                                           ^
   include/linux/page_counter.h:20:26: note: to match this '('
      20 | define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
         |                          ^
>> include/linux/page_counter.h:20:51: error: expected ';' after top level declarator
      20 | define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
         |                                                   ^
         |                                                   ;
   1 warning and 5 errors generated.
   make[3]: *** [scripts/Makefile.build:117: arch/riscv/kernel/asm-offsets.s] Error 1
   make[3]: Target 'prepare' not remade because of errors.
   make[2]: *** [Makefile:1197: prepare0] Error 2
   make[2]: Target 'prepare' not remade because of errors.
   make[1]: *** [Makefile:240: __sub-make] Error 2
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [Makefile:240: __sub-make] Error 2
   make: Target 'prepare' not remade because of errors.


vim +/define +20 include/linux/page_counter.h

     9	
    10	/*
    11	 * Page counters are used by memory and hugetlb cgroups.
    12	 * Memory cgroups are using up to 4 separate counters:
    13	 * memory, swap (memory + swap on cgroup v1), kmem and tcpmem.
    14	 * Hugetlb cgroups are using 2 * HUGE_MAX_HSTATE separate
    15	 * counters: for tracking the usage and reservations of each
    16	 * supported hugepage size.
    17	 */
    18	
    19	#ifdef CONFIG_CGROUP_HUGETLB
  > 20	define __MCT_HUGETLB_MAX (HUGE_MAX_HSTATE * 2 - 1)
    21	#endif /* CONFIG_CGROUP_HUGETLB */
    22	

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-04-30  0:47 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-30  0:47 [rgushchin:page_counters.1 5/7] include/linux/page_counter.h:20:1: error: unknown type name 'define' kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).