Hi Lu,
First bad commit (maybe != root cause):
tree: https://gitee.com/openeuler/kernel.git OLK-6.6 head: 91ff8f4b711382909faa289c49735e0514af6f76 commit: 654944510822988390470cbc5b6f914c19dd9b88 [2387/14244] sched/psi: add cpu fine grained stall tracking in pressure.stat config: arm64-randconfig-001-20240930 (https://download.01.org/0day-ci/archive/20240930/202409300544.lmhFdnFK-lkp@i...) compiler: clang version 20.0.0git (https://github.com/llvm/llvm-project 7773243d9916f98ba0ffce0c3a960e4aa9f03e81) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240930/202409300544.lmhFdnFK-lkp@i...)
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/202409300544.lmhFdnFK-lkp@intel.com/
All errors (new ones prefixed by >>):
In file included from kernel/sched/build_utility.c:24: In file included from include/linux/cpuset.h:17: In file included from include/linux/mm.h:2181: include/linux/vmstat.h:522:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion] 522 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_" | ~~~~~~~~~~~ ^ ~~~ In file included from kernel/sched/build_utility.c:97:
kernel/sched/psi.c:387:1: error: function definition is not allowed here
387 | { | ^ kernel/sched/psi.c:421:1: error: function definition is not allowed here 421 | { | ^ kernel/sched/psi.c:449:1: error: function definition is not allowed here 449 | { | ^ kernel/sched/psi.c:471:1: error: function definition is not allowed here 471 | { | ^ kernel/sched/psi.c:517:17: error: function definition is not allowed here 517 | bool next) {} | ^ kernel/sched/psi.c:523:1: error: function definition is not allowed here 523 | { | ^ kernel/sched/psi.c:590:1: error: function definition is not allowed here 590 | { | ^ kernel/sched/psi.c:608:1: error: function definition is not allowed here 608 | { | ^ kernel/sched/psi.c:635:1: error: function definition is not allowed here 635 | { | ^ kernel/sched/psi.c:707:1: error: function definition is not allowed here 707 | { | ^ kernel/sched/psi.c:772:1: error: function definition is not allowed here 772 | { | ^ kernel/sched/psi.c:808:1: error: function definition is not allowed here 808 | { | ^ kernel/sched/psi.c:822:1: error: function definition is not allowed here 822 | { | ^ kernel/sched/psi.c:848:1: error: function definition is not allowed here 848 | { | ^ kernel/sched/psi.c:932:1: error: function definition is not allowed here 932 | { | ^ kernel/sched/psi.c:950:1: error: function definition is not allowed here 950 | { | ^ kernel/sched/psi.c:958:1: error: function definition is not allowed here 958 | { | ^ kernel/sched/psi.c:993:1: error: function definition is not allowed here 993 | { | ^ kernel/sched/psi.c:1107:1: error: function definition is not allowed here 1107 | { | ^ fatal error: too many errors emitted, stopping now [-ferror-limit=] 1 warning and 20 errors generated.
vim +387 kernel/sched/psi.c
a65983d90bfb5e Lu Jialin 2024-01-04 383 a65983d90bfb5e Lu Jialin 2024-01-04 384 static bool test_fine_grained_stat(unsigned int *stat_tasks, a65983d90bfb5e Lu Jialin 2024-01-04 385 unsigned int nr_running, a65983d90bfb5e Lu Jialin 2024-01-04 386 enum psi_stat_states state) a65983d90bfb5e Lu Jialin 2024-01-04 @387 { a65983d90bfb5e Lu Jialin 2024-01-04 388 switch (state) { a65983d90bfb5e Lu Jialin 2024-01-04 389 case PSI_MEMCG_RECLAIM_SOME: a65983d90bfb5e Lu Jialin 2024-01-04 390 return unlikely(stat_tasks[NR_MEMCG_RECLAIM]); a65983d90bfb5e Lu Jialin 2024-01-04 391 case PSI_MEMCG_RECLAIM_FULL: a65983d90bfb5e Lu Jialin 2024-01-04 392 return unlikely(stat_tasks[NR_MEMCG_RECLAIM] && a65983d90bfb5e Lu Jialin 2024-01-04 393 nr_running == stat_tasks[NR_MEMCG_RECLAIM_RUNNING]); 25d00f6853c3c6 Lu Jialin 2024-01-04 394 case PSI_GLOBAL_RECLAIM_SOME: 25d00f6853c3c6 Lu Jialin 2024-01-04 395 return unlikely(stat_tasks[NR_GLOBAL_RECLAIM]); 25d00f6853c3c6 Lu Jialin 2024-01-04 396 case PSI_GLOBAL_RECLAIM_FULL: 25d00f6853c3c6 Lu Jialin 2024-01-04 397 return unlikely(stat_tasks[NR_GLOBAL_RECLAIM] && 25d00f6853c3c6 Lu Jialin 2024-01-04 398 nr_running == stat_tasks[NR_GLOBAL_RECLAIM_RUNNING]); 25d00f6853c3c6 Lu Jialin 2024-01-04 399 case PSI_COMPACT_SOME: 25d00f6853c3c6 Lu Jialin 2024-01-04 400 return unlikely(stat_tasks[NR_COMPACT]); 25d00f6853c3c6 Lu Jialin 2024-01-04 401 case PSI_COMPACT_FULL: 25d00f6853c3c6 Lu Jialin 2024-01-04 402 return unlikely(stat_tasks[NR_COMPACT] && 25d00f6853c3c6 Lu Jialin 2024-01-04 403 nr_running == stat_tasks[NR_COMPACT_RUNNING]); 25d00f6853c3c6 Lu Jialin 2024-01-04 404 case PSI_ASYNC_MEMCG_RECLAIM_SOME: 25d00f6853c3c6 Lu Jialin 2024-01-04 405 return unlikely(stat_tasks[NR_ASYNC_MEMCG_RECLAIM]); 25d00f6853c3c6 Lu Jialin 2024-01-04 406 case PSI_ASYNC_MEMCG_RECLAIM_FULL: 25d00f6853c3c6 Lu Jialin 2024-01-04 407 return unlikely(stat_tasks[NR_ASYNC_MEMCG_RECLAIM] && 25d00f6853c3c6 Lu Jialin 2024-01-04 408 nr_running == stat_tasks[NR_ASYNC_MEMCG_RECLAIM_RUNNING]); 25d00f6853c3c6 Lu Jialin 2024-01-04 409 case PSI_SWAP_SOME: 25d00f6853c3c6 Lu Jialin 2024-01-04 410 return unlikely(stat_tasks[NR_SWAP]); 25d00f6853c3c6 Lu Jialin 2024-01-04 411 case PSI_SWAP_FULL: 25d00f6853c3c6 Lu Jialin 2024-01-04 412 return unlikely(stat_tasks[NR_SWAP] && 25d00f6853c3c6 Lu Jialin 2024-01-04 413 nr_running == stat_tasks[NR_SWAP_RUNNING]); a65983d90bfb5e Lu Jialin 2024-01-04 414 default: a65983d90bfb5e Lu Jialin 2024-01-04 415 return false; a65983d90bfb5e Lu Jialin 2024-01-04 416 } a65983d90bfb5e Lu Jialin 2024-01-04 417 } a65983d90bfb5e Lu Jialin 2024-01-04 418
:::::: The code at line 387 was first introduced by commit :::::: a65983d90bfb5e031444fea492b32f931c83ffcf sched/psi: Introduce fine grained stall time collect for cgroup reclaim
:::::: TO: Lu Jialin lujialin4@huawei.com :::::: CC: yanhaitao yanhaitao2@huawei.com