lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202110291054.kTLXBeyu-lkp@intel.com>
Date:   Fri, 29 Oct 2021 10:02:24 +0800
From:   kernel test robot <lkp@...el.com>
To:     Jiasheng Jiang <jiasheng@...as.ac.cn>, rui.zhang@...el.com,
        daniel.lezcano@...aro.org, amitk@...nel.org
Cc:     kbuild-all@...ts.01.org, linux-pm@...r.kernel.org,
        linux-kernel@...r.kernel.org, Jiasheng Jiang <jiasheng@...as.ac.cn>
Subject: Re: [PATCH] thermal: Fix implicit type conversion

Hi Jiasheng,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on rafael-pm/thermal]
[also build test ERROR on v5.15-rc7 next-20211028]
[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]

url:    https://github.com/0day-ci/linux/commits/Jiasheng-Jiang/thermal-Fix-implicit-type-conversion/20211028-112252
base:   https://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm.git thermal
config: x86_64-randconfig-a015-20211027 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
        # https://github.com/0day-ci/linux/commit/07e91da90fa6847b02bff413b1a24027e4d36392
        git remote add linux-review https://github.com/0day-ci/linux
        git fetch --no-tags linux-review Jiasheng-Jiang/thermal-Fix-implicit-type-conversion/20211028-112252
        git checkout 07e91da90fa6847b02bff413b1a24027e4d36392
        # save the attached .config to linux build tree
        make W=1 ARCH=x86_64 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@...el.com>

All errors (new ones prefixed by >>):

   drivers/thermal/intel/intel_powerclamp.c: In function 'powerclamp_init':
>> drivers/thermal/intel/intel_powerclamp.c:723:9: error: passing argument 4 of 'cpuhp_setup_state_nocalls' from incompatible pointer type [-Werror=incompatible-pointer-types]
     723 |         powerclamp_cpu_predown);
         |         ^~~~~~~~~~~~~~~~~~~~~~
         |         |
         |         int (*)(int)
   In file included from include/linux/cpu.h:20,
                    from drivers/thermal/intel/intel_powerclamp.c:31:
   include/linux/cpuhotplug.h:317:16: note: expected 'int (*)(unsigned int)' but argument is of type 'int (*)(int)'
     317 |          int (*teardown)(unsigned int cpu))
         |          ~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors


vim +/cpuhp_setup_state_nocalls +723 drivers/thermal/intel/intel_powerclamp.c

cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  704  
4d2b6e4a9ebc29 drivers/thermal/intel_powerclamp.c       Mathias Krause            2015-03-25  705  static int __init powerclamp_init(void)
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  706  {
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  707  	int retval;
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  708  
7fc775ffebb93f drivers/thermal/intel/intel_powerclamp.c Christophe JAILLET        2021-09-26  709  	cpu_clamping_mask = bitmap_zalloc(num_possible_cpus(), GFP_KERNEL);
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  710  	if (!cpu_clamping_mask)
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  711  		return -ENOMEM;
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  712  
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  713  	/* probe cpu features and ids here */
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  714  	retval = powerclamp_probe();
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  715  	if (retval)
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  716  		goto exit_free;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  717  
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  718  	/* set default limit, maybe adjusted during runtime based on feedback */
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  719  	window_size = 2;
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  720  	retval = cpuhp_setup_state_nocalls(CPUHP_AP_ONLINE_DYN,
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  721  					   "thermal/intel_powerclamp:online",
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  722  					   powerclamp_cpu_online,
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28 @723  					   powerclamp_cpu_predown);
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  724  	if (retval < 0)
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  725  		goto exit_free;
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  726  
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  727  	hp_state = retval;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  728  
8d962ac7f396bc drivers/thermal/intel_powerclamp.c       Petr Mladek               2016-11-28  729  	worker_data = alloc_percpu(struct powerclamp_worker_data);
8d962ac7f396bc drivers/thermal/intel_powerclamp.c       Petr Mladek               2016-11-28  730  	if (!worker_data) {
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  731  		retval = -ENOMEM;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  732  		goto exit_unregister;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  733  	}
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  734  
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  735  	cooling_dev = thermal_cooling_device_register("intel_powerclamp", NULL,
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  736  						&powerclamp_cooling_ops);
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  737  	if (IS_ERR(cooling_dev)) {
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  738  		retval = -ENODEV;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  739  		goto exit_free_thread;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  740  	}
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  741  
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  742  	if (!duration)
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  743  		duration = jiffies_to_msecs(DEFAULT_DURATION_JIFFIES);
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  744  
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  745  	powerclamp_create_debug_files();
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  746  
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  747  	return 0;
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  748  
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  749  exit_free_thread:
8d962ac7f396bc drivers/thermal/intel_powerclamp.c       Petr Mladek               2016-11-28  750  	free_percpu(worker_data);
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  751  exit_unregister:
cb91fef1b71954 drivers/thermal/intel_powerclamp.c       Sebastian Andrzej Siewior 2016-11-28  752  	cpuhp_remove_state_nocalls(hp_state);
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  753  exit_free:
7fc775ffebb93f drivers/thermal/intel/intel_powerclamp.c Christophe JAILLET        2021-09-26  754  	bitmap_free(cpu_clamping_mask);
c32a5087b70a67 drivers/thermal/intel_powerclamp.c       durgadoss.r@...el.com     2013-10-04  755  	return retval;
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  756  }
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  757  module_init(powerclamp_init);
d6d71ee4a14ae6 drivers/thermal/intel_powerclamp.c       Jacob Pan                 2013-01-21  758  

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org

Download attachment ".config.gz" of type "application/gzip" (36410 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ