Re: [PATCH v1 3/9] hwmon: (gxp-psu) Add driver to read HPE PSUs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

kernel test robot noticed the following build warnings:

[auto build test WARNING on groeck-staging/hwmon-next]
[also build test WARNING on robh/for-next linus/master v6.3-rc7]
[cannot apply to brgl/gpio/for-next next-20230417]
[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/nick-hawkins-hpe-com/gpio-gxp-Add-HPE-GXP-GPIO/20230418-233513
base:   https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git hwmon-next
patch link:    https://lore.kernel.org/r/20230418152824.110823-4-nick.hawkins%40hpe.com
patch subject: [PATCH v1 3/9] hwmon: (gxp-psu) Add driver to read HPE PSUs
config: sparc-allyesconfig (https://download.01.org/0day-ci/archive/20230419/202304190301.9jtv8uzG-lkp@xxxxxxxxx/config)
compiler: sparc64-linux-gcc (GCC) 12.1.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/intel-lab-lkp/linux/commit/4006e868883aedc37a54480167f6f9dc377db1cc
        git remote add linux-review https://github.com/intel-lab-lkp/linux
        git fetch --no-tags linux-review nick-hawkins-hpe-com/gpio-gxp-Add-HPE-GXP-GPIO/20230418-233513
        git checkout 4006e868883aedc37a54480167f6f9dc377db1cc
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=sparc olddefconfig
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=sparc SHELL=/bin/bash drivers/hwmon/

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Link: https://lore.kernel.org/oe-kbuild-all/202304190301.9jtv8uzG-lkp@xxxxxxxxx/

All warnings (new ones prefixed by >>):

>> drivers/hwmon/gxp-psu.c:62:4: warning: no previous prototype for 'get_psu_inst' [-Wmissing-prototypes]
      62 | u8 get_psu_inst(void)
         |    ^~~~~~~~~~~~
>> drivers/hwmon/gxp-psu.c:71:4: warning: no previous prototype for 'get_psu_ac' [-Wmissing-prototypes]
      71 | u8 get_psu_ac(void)
         |    ^~~~~~~~~~
>> drivers/hwmon/gxp-psu.c:80:4: warning: no previous prototype for 'get_psu_dc' [-Wmissing-prototypes]
      80 | u8 get_psu_dc(void)
         |    ^~~~~~~~~~
>> drivers/hwmon/gxp-psu.c:89:6: warning: no previous prototype for 'update_presence' [-Wmissing-prototypes]
      89 | void update_presence(u8 id)
         |      ^~~~~~~~~~~~~~~
>> drivers/hwmon/gxp-psu.c:376:6: warning: no previous prototype for 'swapbytes' [-Wmissing-prototypes]
     376 | void swapbytes(void *input, size_t len)
         |      ^~~~~~~~~
   drivers/hwmon/gxp-psu.c: In function 'gxp_psu_read_string':
>> drivers/hwmon/gxp-psu.c:528:17: warning: this statement may fall through [-Wimplicit-fallthrough=]
     528 |                 switch (attr) {
         |                 ^~~~~~
   drivers/hwmon/gxp-psu.c:535:9: note: here
     535 |         case hwmon_in:
         |         ^~~~
   drivers/hwmon/gxp-psu.c:536:17: warning: this statement may fall through [-Wimplicit-fallthrough=]
     536 |                 switch (attr) {
         |                 ^~~~~~
   drivers/hwmon/gxp-psu.c:543:9: note: here
     543 |         case hwmon_fan:
         |         ^~~~
   drivers/hwmon/gxp-psu.c:544:17: warning: this statement may fall through [-Wimplicit-fallthrough=]
     544 |                 switch (attr) {
         |                 ^~~~~~
   drivers/hwmon/gxp-psu.c:551:9: note: here
     551 |         case hwmon_curr:
         |         ^~~~
   drivers/hwmon/gxp-psu.c:552:17: warning: this statement may fall through [-Wimplicit-fallthrough=]
     552 |                 switch (attr) {
         |                 ^~~~~~
   drivers/hwmon/gxp-psu.c:559:9: note: here
     559 |         case hwmon_temp:
         |         ^~~~


vim +/get_psu_inst +62 drivers/hwmon/gxp-psu.c

    61	
  > 62	u8 get_psu_inst(void)
    63	{
    64		if (!pl_psu)
    65			return 0;
    66	
    67		return readb(pl_psu);
    68	}
    69	EXPORT_SYMBOL(get_psu_inst);
    70	
  > 71	u8 get_psu_ac(void)
    72	{
    73		if (!pl_psu)
    74			return 0;
    75	
    76		return readb(pl_psu + 0x02);
    77	}
    78	EXPORT_SYMBOL(get_psu_ac);
    79	
  > 80	u8 get_psu_dc(void)
    81	{
    82		if (!pl_psu)
    83			return 0;
    84	
    85		return readb(pl_psu + 0x03);
    86	}
    87	EXPORT_SYMBOL(get_psu_dc);
    88	
  > 89	void update_presence(u8 id)
    90	{
    91		unsigned int i;
    92		unsigned long temp = (unsigned long)readb(pl_psu);
    93	
    94		for_each_set_bit(i, &temp, 8) {
    95			if (i == id)
    96				psus[id]->present = true;
    97		}
    98	
    99		temp = ~temp;
   100		for_each_set_bit(i, &temp, 8) {
   101			if (i == id)
   102				psus[id]->present = false;
   103		}
   104	}
   105	

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux