[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202601230422.1xw7nG4T-lkp@intel.com>
Date: Fri, 23 Jan 2026 04:58:39 +0800
From: kernel test robot <lkp@...el.com>
To: Qiliang Yuan <realwujing@...il.com>, Ingo Molnar <mingo@...hat.com>,
Peter Zijlstra <peterz@...radead.org>,
Juri Lelli <juri.lelli@...hat.com>,
Vincent Guittot <vincent.guittot@...aro.org>
Cc: oe-kbuild-all@...ts.linux.dev,
Dietmar Eggemann <dietmar.eggemann@....com>,
Steven Rostedt <rostedt@...dmis.org>,
Ben Segall <bsegall@...gle.com>, Mel Gorman <mgorman@...e.de>,
Valentin Schneider <vschneid@...hat.com>,
linux-kernel@...r.kernel.org, Qiliang Yuan <realwujing@...il.com>
Subject: Re: [PATCH] sched/fair: Optimize EAS energy calculation complexity
from O(N) to O(1) inside inner loop
Hi Qiliang,
kernel test robot noticed the following build warnings:
[auto build test WARNING on tip/sched/core]
[also build test WARNING on tip/master peterz-queue/sched/core linus/master v6.19-rc6 next-20260122]
[cannot apply to tip/auto-latest]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Qiliang-Yuan/sched-fair-Optimize-EAS-energy-calculation-complexity-from-O-N-to-O-1-inside-inner-loop/20260123-000924
base: tip/sched/core
patch link: https://lore.kernel.org/r/20260122154227.130767-1-realwujing%40gmail.com
patch subject: [PATCH] sched/fair: Optimize EAS energy calculation complexity from O(N) to O(1) inside inner loop
config: sh-defconfig (https://download.01.org/0day-ci/archive/20260123/202601230422.1xw7nG4T-lkp@intel.com/config)
compiler: sh4-linux-gcc (GCC) 15.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260123/202601230422.1xw7nG4T-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202601230422.1xw7nG4T-lkp@intel.com/
All warnings (new ones prefixed by >>):
In file included from include/linux/bitmap.h:11,
from include/linux/cpumask.h:11,
from include/linux/energy_model.h:4,
from kernel/sched/fair.c:23:
kernel/sched/fair.c: In function 'find_energy_efficient_cpu':
>> include/linux/cpumask_types.h:18:37: warning: dereferencing 'void *' pointer
18 | #define cpumask_bits(maskp) ((maskp)->bits)
| ^~
include/linux/find.h:586:48: note: in definition of macro 'for_each_set_bit'
586 | for ((bit) = 0; (bit) = find_next_bit((addr), (size), (bit)), (bit) < (size); (bit)++)
| ^~~~
include/linux/cpumask.h:380:31: note: in expansion of macro 'cpumask_bits'
380 | for_each_set_bit(cpu, cpumask_bits(mask), small_cpumask_bits)
| ^~~~~~~~~~~~
kernel/sched/fair.c:8345:17: note: in expansion of macro 'for_each_cpu'
8345 | for_each_cpu(i, perf_domain_span(tmp_pd)) {
| ^~~~~~~~~~~~
include/linux/cpumask_types.h:18:37: error: request for member 'bits' in something not a structure or union
18 | #define cpumask_bits(maskp) ((maskp)->bits)
| ^~
include/linux/find.h:586:48: note: in definition of macro 'for_each_set_bit'
586 | for ((bit) = 0; (bit) = find_next_bit((addr), (size), (bit)), (bit) < (size); (bit)++)
| ^~~~
include/linux/cpumask.h:380:31: note: in expansion of macro 'cpumask_bits'
380 | for_each_set_bit(cpu, cpumask_bits(mask), small_cpumask_bits)
| ^~~~~~~~~~~~
kernel/sched/fair.c:8345:17: note: in expansion of macro 'for_each_cpu'
8345 | for_each_cpu(i, perf_domain_span(tmp_pd)) {
| ^~~~~~~~~~~~
>> include/linux/find.h:586:69: warning: left-hand operand of comma expression has no effect [-Wunused-value]
586 | for ((bit) = 0; (bit) = find_next_bit((addr), (size), (bit)), (bit) < (size); (bit)++)
| ^
include/linux/cpumask.h:380:9: note: in expansion of macro 'for_each_set_bit'
380 | for_each_set_bit(cpu, cpumask_bits(mask), small_cpumask_bits)
| ^~~~~~~~~~~~~~~~
kernel/sched/fair.c:8345:17: note: in expansion of macro 'for_each_cpu'
8345 | for_each_cpu(i, perf_domain_span(tmp_pd)) {
| ^~~~~~~~~~~~
vim +18 include/linux/cpumask_types.h
eb4faa36d674ee Yury Norov 2024-05-27 10
eb4faa36d674ee Yury Norov 2024-05-27 11 /**
eb4faa36d674ee Yury Norov 2024-05-27 12 * cpumask_bits - get the bits in a cpumask
eb4faa36d674ee Yury Norov 2024-05-27 13 * @maskp: the struct cpumask *
eb4faa36d674ee Yury Norov 2024-05-27 14 *
eb4faa36d674ee Yury Norov 2024-05-27 15 * You should only assume nr_cpu_ids bits of this mask are valid. This is
eb4faa36d674ee Yury Norov 2024-05-27 16 * a macro so it's const-correct.
eb4faa36d674ee Yury Norov 2024-05-27 17 */
eb4faa36d674ee Yury Norov 2024-05-27 @18 #define cpumask_bits(maskp) ((maskp)->bits)
eb4faa36d674ee Yury Norov 2024-05-27 19
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists