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>] [day] [month] [year] [list]
Message-ID: <202203130000.24KypUX4-lkp@intel.com>
Date:   Sun, 13 Mar 2022 00:11:01 +0800
From:   kernel test robot <lkp@...el.com>
To:     "Russell King (Oracle)" <rmk+kernel@...linux.org.uk>
Cc:     llvm@...ts.linux.dev, kbuild-all@...ts.01.org,
        linux-kernel@...r.kernel.org
Subject: [rmk-arm:zii 128/199] drivers/net/dsa/mv88e6xxx/serdes.c:1343:3:
 warning: variable 'reg' is uninitialized when used here

tree:   git://git.armlinux.org.uk/~rmk/linux-arm zii
head:   22f6fd6865d54d3632278e7f17bad52308e50311
commit: b222c2366f2aacc7b0b55d6fa78e903293aa9eaa [128/199] net: dsa: mv88e6xxx: provide and use mv88e6390_serdes_modify()
config: i386-randconfig-a013 (https://download.01.org/0day-ci/archive/20220313/202203130000.24KypUX4-lkp@intel.com/config)
compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project 43f668b98e8d87290fc6bbf5ed13c3ab542e3497)
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
        git remote add rmk-arm git://git.armlinux.org.uk/~rmk/linux-arm
        git fetch --no-tags rmk-arm zii
        git checkout b222c2366f2aacc7b0b55d6fa78e903293aa9eaa
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash drivers/net/dsa/mv88e6xxx/

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

All warnings (new ones prefixed by >>):

>> drivers/net/dsa/mv88e6xxx/serdes.c:1343:3: warning: variable 'reg' is uninitialized when used here [-Wuninitialized]
                   reg |= MV88E6393X_SERDES_CTRL1_TX_PDOWN |
                   ^~~
   drivers/net/dsa/mv88e6xxx/serdes.c:1338:9: note: initialize the variable 'reg' to silence this warning
           u16 reg;
                  ^
                   = 0
   1 warning generated.


vim +/reg +1343 drivers/net/dsa/mv88e6xxx/serdes.c

de776d0d316f72 Pavana Sharma         2021-03-17  1334  
7527d66260ac0c Marek Behún           2021-11-30  1335  static int mv88e6393x_serdes_power_lane(struct mv88e6xxx_chip *chip, int lane,
7527d66260ac0c Marek Behún           2021-11-30  1336  					bool on)
7527d66260ac0c Marek Behún           2021-11-30  1337  {
7527d66260ac0c Marek Behún           2021-11-30  1338  	u16 reg;
7527d66260ac0c Marek Behún           2021-11-30  1339  
7527d66260ac0c Marek Behún           2021-11-30  1340  	if (on)
b222c2366f2aac Russell King (Oracle  2022-03-08  1341) 		reg = 0;
7527d66260ac0c Marek Behún           2021-11-30  1342  	else
7527d66260ac0c Marek Behún           2021-11-30 @1343  		reg |= MV88E6393X_SERDES_CTRL1_TX_PDOWN |
7527d66260ac0c Marek Behún           2021-11-30  1344  		       MV88E6393X_SERDES_CTRL1_RX_PDOWN;
7527d66260ac0c Marek Behún           2021-11-30  1345  
b222c2366f2aac Russell King (Oracle  2022-03-08  1346) 	return mv88e6390_serdes_modify(chip, lane, MDIO_MMD_PHYXS,
b222c2366f2aac Russell King (Oracle  2022-03-08  1347) 				       MV88E6393X_SERDES_CTRL1,
b222c2366f2aac Russell King (Oracle  2022-03-08  1348) 				       MV88E6393X_SERDES_CTRL1_TX_PDOWN |
b222c2366f2aac Russell King (Oracle  2022-03-08  1349) 				       MV88E6393X_SERDES_CTRL1_RX_PDOWN, reg);
7527d66260ac0c Marek Behún           2021-11-30  1350  }
7527d66260ac0c Marek Behún           2021-11-30  1351  

:::::: The code at line 1343 was first introduced by commit
:::::: 7527d66260ac0c603c6baca5146748061fcddbd6 net: dsa: mv88e6xxx: Save power by disabling SerDes trasmitter and receiver

:::::: TO: Marek Behún <kabel@...nel.org>
:::::: CC: David S. Miller <davem@...emloft.net>

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ