linux-pm.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [vireshk:opp/genpd-performance-state 6/9] drivers/opp/qcom_rpmpd.c:126:1: error: type defaults to 'int' in declaration of 'subsys_initcall'
@ 2017-10-06  8:35 kbuild test robot
  2017-10-06  9:20 ` Viresh Kumar
  0 siblings, 1 reply; 2+ messages in thread
From: kbuild test robot @ 2017-10-06  8:35 UTC (permalink / raw)
  To: Viresh Kumar; +Cc: kbuild-all, linux-pm

[-- Attachment #1: Type: text/plain, Size: 3793 bytes --]

tree:   https://git.linaro.org/people/vireshk/linux opp/genpd-performance-state
head:   13fe1509c44fe331828415c105e47904a376a016
commit: bc45091e2bb046eb6718d715bb24c6184baa0263 [6/9] soc: qcom: rpmpd: Add a powerdomain driver to model cx/mx powerdomains
config: arm-allmodconfig (attached as .config)
compiler: arm-linux-gnueabi-gcc (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout bc45091e2bb046eb6718d715bb24c6184baa0263
        # save the attached .config to linux build tree
        make.cross ARCH=arm 

All error/warnings (new ones prefixed by >>):

>> drivers/opp/qcom_rpmpd.c:126:1: warning: data definition has no type or storage class
    subsys_initcall(rpmpd_get_performance);
    ^~~~~~~~~~~~~~~
>> drivers/opp/qcom_rpmpd.c:126:1: error: type defaults to 'int' in declaration of 'subsys_initcall' [-Werror=implicit-int]
>> drivers/opp/qcom_rpmpd.c:126:1: warning: parameter names (without types) in function declaration
   drivers/opp/qcom_rpmpd.c:95:19: warning: 'rpmpd_get_performance' defined but not used [-Wunused-function]
    static int __init rpmpd_get_performance(void)
                      ^~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors

vim +126 drivers/opp/qcom_rpmpd.c

60dfbefa Viresh Kumar 2017-10-05   94  
60dfbefa Viresh Kumar 2017-10-05   95  static int __init rpmpd_get_performance(void)
60dfbefa Viresh Kumar 2017-10-05   96  {
60dfbefa Viresh Kumar 2017-10-05   97  	struct platform_device *pdev;
60dfbefa Viresh Kumar 2017-10-05   98  	struct device_node *np;
60dfbefa Viresh Kumar 2017-10-05   99  	int i, index;
60dfbefa Viresh Kumar 2017-10-05  100  
60dfbefa Viresh Kumar 2017-10-05  101  	if (!of_machine_is_compatible("qcom,msm8996-mtp"))
60dfbefa Viresh Kumar 2017-10-05  102  		return 0;
60dfbefa Viresh Kumar 2017-10-05  103  
60dfbefa Viresh Kumar 2017-10-05  104  	for (i = 0; i < ARRAY_SIZE(devices); i++) {
60dfbefa Viresh Kumar 2017-10-05  105  		np = of_find_compatible_node(NULL, NULL, devices[i].compatible);
60dfbefa Viresh Kumar 2017-10-05  106  		if (!np)
60dfbefa Viresh Kumar 2017-10-05  107  			continue;
60dfbefa Viresh Kumar 2017-10-05  108  
60dfbefa Viresh Kumar 2017-10-05  109  		pdev = of_find_device_by_node(np);
60dfbefa Viresh Kumar 2017-10-05  110  		if (!pdev)
60dfbefa Viresh Kumar 2017-10-05  111  			pdev = of_platform_device_create(np, NULL, NULL);
60dfbefa Viresh Kumar 2017-10-05  112  
60dfbefa Viresh Kumar 2017-10-05  113  		of_node_put(np);
60dfbefa Viresh Kumar 2017-10-05  114  
60dfbefa Viresh Kumar 2017-10-05  115  		if (!pdev)
60dfbefa Viresh Kumar 2017-10-05  116  			continue;
60dfbefa Viresh Kumar 2017-10-05  117  
60dfbefa Viresh Kumar 2017-10-05  118  		index = (enum msm8996_devices)(devices[i].data);
60dfbefa Viresh Kumar 2017-10-05  119  		msm8996_rpmpd_freq_map[index].dev = &pdev->dev;
60dfbefa Viresh Kumar 2017-10-05  120  
60dfbefa Viresh Kumar 2017-10-05  121  		dev_pm_opp_register_get_pstate_helper(&pdev->dev, get_pstate);
60dfbefa Viresh Kumar 2017-10-05  122  	}
60dfbefa Viresh Kumar 2017-10-05  123  
60dfbefa Viresh Kumar 2017-10-05  124  	return 0;
60dfbefa Viresh Kumar 2017-10-05  125  }
60dfbefa Viresh Kumar 2017-10-05 @126  subsys_initcall(rpmpd_get_performance);

:::::: The code at line 126 was first introduced by commit
:::::: 60dfbefa17fadd4caf208f1ae18ee93ae9918ec0 opp: qcom: rpmpd: Add support to set performance states of OPPs

:::::: TO: Viresh Kumar <viresh.kumar@linaro.org>
:::::: CC: Viresh Kumar <viresh.kumar@linaro.org>

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 64023 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [vireshk:opp/genpd-performance-state 6/9] drivers/opp/qcom_rpmpd.c:126:1: error: type defaults to 'int' in declaration of 'subsys_initcall'
  2017-10-06  8:35 [vireshk:opp/genpd-performance-state 6/9] drivers/opp/qcom_rpmpd.c:126:1: error: type defaults to 'int' in declaration of 'subsys_initcall' kbuild test robot
@ 2017-10-06  9:20 ` Viresh Kumar
  0 siblings, 0 replies; 2+ messages in thread
From: Viresh Kumar @ 2017-10-06  9:20 UTC (permalink / raw)
  To: kbuild test robot; +Cc: kbuild-all, linux-pm

On 06-10-17, 16:35, kbuild test robot wrote:
> tree:   https://git.linaro.org/people/vireshk/linux opp/genpd-performance-state
> head:   13fe1509c44fe331828415c105e47904a376a016
> commit: bc45091e2bb046eb6718d715bb24c6184baa0263 [6/9] soc: qcom: rpmpd: Add a powerdomain driver to model cx/mx powerdomains
> config: arm-allmodconfig (attached as .config)
> compiler: arm-linux-gnueabi-gcc (Debian 6.1.1-9) 6.1.1 20160705
> reproduce:
>         wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
>         chmod +x ~/bin/make.cross
>         git checkout bc45091e2bb046eb6718d715bb24c6184baa0263
>         # save the attached .config to linux build tree
>         make.cross ARCH=arm 
> 
> All error/warnings (new ones prefixed by >>):
> 
> >> drivers/opp/qcom_rpmpd.c:126:1: warning: data definition has no type or storage class
>     subsys_initcall(rpmpd_get_performance);
>     ^~~~~~~~~~~~~~~
> >> drivers/opp/qcom_rpmpd.c:126:1: error: type defaults to 'int' in declaration of 'subsys_initcall' [-Werror=implicit-int]
> >> drivers/opp/qcom_rpmpd.c:126:1: warning: parameter names (without types) in function declaration
>    drivers/opp/qcom_rpmpd.c:95:19: warning: 'rpmpd_get_performance' defined but not used [-Wunused-function]
>     static int __init rpmpd_get_performance(void)
>                       ^~~~~~~~~~~~~~~~~~~~~
>    cc1: some warnings being treated as errors

Fixed it. Thanks. Had to include module.h as well.

-- 
viresh

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-10-06  9:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-10-06  8:35 [vireshk:opp/genpd-performance-state 6/9] drivers/opp/qcom_rpmpd.c:126:1: error: type defaults to 'int' in declaration of 'subsys_initcall' kbuild test robot
2017-10-06  9:20 ` Viresh Kumar

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 NNTP newsgroup(s).