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 for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Date:   Tue, 24 May 2022 16:56:31 +0800
From:   kernel test robot <lkp@...el.com>
To:     Krzysztof Kozlowski <krzk@...nel.org>
Cc:     kbuild-all@...ts.01.org, linux-kernel@...r.kernel.org
Subject: [krzk-github:n/qcom-bwmon-v3 21/22]
 drivers/soc/qcom/icc-bwmon.c:160:35: warning: variable 'irq_enable' set but
 not used

tree:   https://github.com/krzk/linux n/qcom-bwmon-v3
head:   f595f77c2d91820ce85df16e278315e522172710
commit: 3cd6e62deb674c541c6e46597273ee0235c339ec [21/22] bwmon v3
config: arc-allyesconfig (https://download.01.org/0day-ci/archive/20220524/202205241624.KBClsJGP-lkp@intel.com/config)
compiler: arceb-elf-gcc (GCC) 11.3.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/krzk/linux/commit/3cd6e62deb674c541c6e46597273ee0235c339ec
        git remote add krzk-github https://github.com/krzk/linux
        git fetch --no-tags krzk-github n/qcom-bwmon-v3
        git checkout 3cd6e62deb674c541c6e46597273ee0235c339ec
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=arc SHELL=/bin/bash drivers/soc/qcom/

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

All warnings (new ones prefixed by >>):

   drivers/soc/qcom/icc-bwmon.c: In function 'bwmon_start':
>> drivers/soc/qcom/icc-bwmon.c:160:35: warning: variable 'irq_enable' set but not used [-Wunused-but-set-variable]
     160 |         unsigned int thres_count, irq_enable;
         |                                   ^~~~~~~~~~


vim +/irq_enable +160 drivers/soc/qcom/icc-bwmon.c

1598903c24dd56 Krzysztof Kozlowski 2022-04-22  156  
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  157  static void bwmon_start(struct icc_bwmon *bwmon,
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  158  			const struct icc_bwmon_data *data)
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  159  {
1598903c24dd56 Krzysztof Kozlowski 2022-04-22 @160  	unsigned int thres_count, irq_enable;
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  161  	int window;
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  162  
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  163  	bwmon_clear(bwmon);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  164  
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  165  	window = mult_frac(bwmon->sample_ms, HW_TIMER_HZ, MSEC_PER_SEC);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  166  	writel_relaxed(window, bwmon->base + BWMON_SAMPLE_WINDOW);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  167  
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  168  	bwmon_set_threshold(bwmon, BWMON_THRESHOLD_HIGH,
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  169  			    data->default_highbw_kbps);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  170  	bwmon_set_threshold(bwmon, BWMON_THRESHOLD_MED,
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  171  			    data->default_medbw_kbps);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  172  	bwmon_set_threshold(bwmon, BWMON_THRESHOLD_LOW,
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  173  			    data->default_lowbw_kbps);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  174  
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  175  	thres_count = data->zone3_thres_count << BWMON_THRESHOLD_COUNT_ZONE3_SHIFT |
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  176  		      BWMON_THRESHOLD_COUNT_ZONE2_DEFAULT << BWMON_THRESHOLD_COUNT_ZONE2_SHIFT |
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  177  		      data->zone1_thres_count << BWMON_THRESHOLD_COUNT_ZONE1_SHIFT |
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  178  		      BWMON_THRESHOLD_COUNT_ZONE0_DEFAULT;
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  179  	writel_relaxed(thres_count, bwmon->base + BWMON_THRESHOLD_COUNT);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  180  	writel_relaxed(BWMON_ZONE_ACTIONS_DEFAULT,
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  181  		       bwmon->base + BWMON_ZONE_ACTIONS);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  182  
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  183  	/* Write barriers in bwmon_clear() */
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  184  	irq_enable = BIT(BWMON_IRQ_ENABLE_ZONE1_SHIFT) |
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  185  		     BIT(BWMON_IRQ_ENABLE_ZONE3_SHIFT);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  186  	bwmon_clear(bwmon);
3cd6e62deb674c Krzysztof Kozlowski 2022-05-24  187  	bwmon_enable(bwmon, BWMON_IRQ_ENABLE_MASK);
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  188  }
1598903c24dd56 Krzysztof Kozlowski 2022-04-22  189  

:::::: The code at line 160 was first introduced by commit
:::::: 1598903c24dd564eb700ef2439ca169bc6c52fb0 soc: qcom: icc-bwmon: Add bandwidth monitoring driver

:::::: TO: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>
:::::: CC: Krzysztof Kozlowski <krzysztof.kozlowski@...aro.org>

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ