public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: Dietmar Eggemann <dietmar.eggemann@arm.com>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
	0day robot <lkp@intel.com>,
	Vincent Guittot <vincent.guittot@linaro.org>
Subject: include/linux/percpu-defs.h:317:1: warning: initialization of 'struct cpumask *' from 'int' makes pointer from integer without a cast
Date: Wed, 22 Jun 2022 10:22:10 +0800	[thread overview]
Message-ID: <202206221013.ygryuYit-lkp@intel.com> (raw)

tree:   https://github.com/intel-lab-lkp/linux/commits/Vincent-Donnefort/feec-energy-margin-removal/20220621-170631
head:   2059fff7a5a2b6016ef5843c673845283a00a646
commit: a4a1ec79913664ac49b72cda8c3756c4da7c16b4 sched/fair: Rename select_idle_mask to select_rq_mask
date:   17 hours ago
config: x86_64-rhel-8.3 (https://download.01.org/0day-ci/archive/20220622/202206221013.ygryuYit-lkp@intel.com/config)
compiler: gcc-11 (Debian 11.3.0-3) 11.3.0
reproduce (this is a W=1 build):
        # https://github.com/intel-lab-lkp/linux/commit/a4a1ec79913664ac49b72cda8c3756c4da7c16b4
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review Vincent-Donnefort/feec-energy-margin-removal/20220621-170631
        git checkout a4a1ec79913664ac49b72cda8c3756c4da7c16b4
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        make W=1 O=build_dir ARCH=x86_64 SHELL=/bin/bash kernel/sched/

If you fix the issue, kindly add following tag where applicable
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

   In file included from include/asm-generic/percpu.h:7,
                    from arch/x86/include/asm/percpu.h:390,
                    from arch/x86/include/asm/current.h:6,
                    from include/linux/sched.h:12,
                    from include/linux/ratelimit.h:6,
                    from include/linux/dev_printk.h:16,
                    from include/linux/device.h:15,
                    from include/linux/energy_model.h:5,
                    from kernel/sched/fair.c:23:
   kernel/sched/fair.c: In function 'find_idlest_group':
   kernel/sched/fair.c:9246:81: error: 'select_idle_mask' undeclared (first use in this function); did you mean 'select_idle_cpu'?
    9246 |                                 struct cpumask *cpus = this_cpu_cpumask_var_ptr(select_idle_mask);
         |                                                                                 ^~~~~~~~~~~~~~~~
   include/linux/percpu-defs.h:318:16: note: in definition of macro '__pcpu_size_call_return'
     318 |         typeof(variable) pscr_ret__;                                    \
         |                ^~~~~~~~
   include/linux/cpumask.h:742:41: note: in expansion of macro 'this_cpu_read'
     742 | #define this_cpu_cpumask_var_ptr(x)     this_cpu_read(x)
         |                                         ^~~~~~~~~~~~~
   kernel/sched/fair.c:9246:56: note: in expansion of macro 'this_cpu_cpumask_var_ptr'
    9246 |                                 struct cpumask *cpus = this_cpu_cpumask_var_ptr(select_idle_mask);
         |                                                        ^~~~~~~~~~~~~~~~~~~~~~~~
   kernel/sched/fair.c:9246:81: note: each undeclared identifier is reported only once for each function it appears in
    9246 |                                 struct cpumask *cpus = this_cpu_cpumask_var_ptr(select_idle_mask);
         |                                                                                 ^~~~~~~~~~~~~~~~
   include/linux/percpu-defs.h:318:16: note: in definition of macro '__pcpu_size_call_return'
     318 |         typeof(variable) pscr_ret__;                                    \
         |                ^~~~~~~~
   include/linux/cpumask.h:742:41: note: in expansion of macro 'this_cpu_read'
     742 | #define this_cpu_cpumask_var_ptr(x)     this_cpu_read(x)
         |                                         ^~~~~~~~~~~~~
   kernel/sched/fair.c:9246:56: note: in expansion of macro 'this_cpu_cpumask_var_ptr'
    9246 |                                 struct cpumask *cpus = this_cpu_cpumask_var_ptr(select_idle_mask);
         |                                                        ^~~~~~~~~~~~~~~~~~~~~~~~
>> include/linux/percpu-defs.h:317:1: warning: initialization of 'struct cpumask *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     317 | ({                                                                      \
         | ^
   include/linux/percpu-defs.h:507:41: note: in expansion of macro '__pcpu_size_call_return'
     507 | #define this_cpu_read(pcp)              __pcpu_size_call_return(this_cpu_read_, pcp)
         |                                         ^~~~~~~~~~~~~~~~~~~~~~~
   include/linux/cpumask.h:742:41: note: in expansion of macro 'this_cpu_read'
     742 | #define this_cpu_cpumask_var_ptr(x)     this_cpu_read(x)
         |                                         ^~~~~~~~~~~~~
   kernel/sched/fair.c:9246:56: note: in expansion of macro 'this_cpu_cpumask_var_ptr'
    9246 |                                 struct cpumask *cpus = this_cpu_cpumask_var_ptr(select_idle_mask);
         |                                                        ^~~~~~~~~~~~~~~~~~~~~~~~


vim +317 include/linux/percpu-defs.h

a32f8d8eda8bd49 Tejun Heo 2014-06-17  315  
a32f8d8eda8bd49 Tejun Heo 2014-06-17  316  #define __pcpu_size_call_return(stem, variable)				\
eba117889ac444b Tejun Heo 2014-06-17 @317  ({									\
eba117889ac444b Tejun Heo 2014-06-17  318  	typeof(variable) pscr_ret__;					\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  319  	__verify_pcpu_ptr(&(variable));					\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  320  	switch(sizeof(variable)) {					\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  321  	case 1: pscr_ret__ = stem##1(variable); break;			\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  322  	case 2: pscr_ret__ = stem##2(variable); break;			\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  323  	case 4: pscr_ret__ = stem##4(variable); break;			\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  324  	case 8: pscr_ret__ = stem##8(variable); break;			\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  325  	default:							\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  326  		__bad_size_call_parameter(); break;			\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  327  	}								\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  328  	pscr_ret__;							\
a32f8d8eda8bd49 Tejun Heo 2014-06-17  329  })
a32f8d8eda8bd49 Tejun Heo 2014-06-17  330  

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

                 reply	other threads:[~2022-06-22  2:22 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=202206221013.ygryuYit-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=dietmar.eggemann@arm.com \
    --cc=kbuild-all@lists.01.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=vincent.guittot@linaro.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox