linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1848:2: warning: 'addr' may be used uninitialized in this function
@ 2019-11-11  6:35 kbuild test robot
  0 siblings, 0 replies; only message in thread
From: kbuild test robot @ 2019-11-11  6:35 UTC (permalink / raw)
  To: Randy Dunlap; +Cc: kbuild-all, linux-kernel, Michal Simek

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

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head:   31f4f5b495a62c9a8b15b1c3581acd5efeb9af8c
commit: 6a090e97972dc7bb6f2661eda3eabd8ae21e9b6d arch/microblaze: support get_user() of size 8 bytes
date:   8 weeks ago
config: microblaze-allyesconfig (attached as .config)
compiler: microblaze-linux-gcc (GCC) 7.4.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        git checkout 6a090e97972dc7bb6f2661eda3eabd8ae21e9b6d
        # save the attached .config to linux build tree
        GCC_VERSION=7.4.0 make.cross ARCH=microblaze 

If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp@intel.com>

Note: it may well be a FALSE warning. FWIW you are at least aware of it now.
http://gcc.gnu.org/wiki/Better_Uninitialized_Warnings

All warnings (new ones prefixed by >>):

   drivers/staging/rtl8712/rtl871x_ioctl_linux.c: In function 'r8711_wx_write32':
>> drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1848:2: warning: 'addr' may be used uninitialized in this function [-Wmaybe-uninitialized]
     r8712_write32(padapter, addr, data32);
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   drivers/staging/rtl8712/rtl871x_ioctl_linux.c: In function 'r8711_wx_read32':
   drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1830:9: warning: 'addr' may be used uninitialized in this function [-Wmaybe-uninitialized]
     data32 = r8712_read32(padapter, addr);
     ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

vim +/addr +1848 drivers/staging/rtl8712/rtl871x_ioctl_linux.c

2865d42c78a912 Larry Finger 2010-08-20  1837  
2865d42c78a912 Larry Finger 2010-08-20  1838  static int r8711_wx_write32(struct net_device *dev,
2865d42c78a912 Larry Finger 2010-08-20  1839  				 struct iw_request_info *info,
2865d42c78a912 Larry Finger 2010-08-20  1840  				 union iwreq_data *wrqu, char *keybuf)
2865d42c78a912 Larry Finger 2010-08-20  1841  {
8f47c28b5a0346 Julia Lawall 2015-03-29  1842  	struct _adapter *padapter = netdev_priv(dev);
2865d42c78a912 Larry Finger 2010-08-20  1843  	u32 addr;
2865d42c78a912 Larry Finger 2010-08-20  1844  	u32 data32;
2865d42c78a912 Larry Finger 2010-08-20  1845  
2865d42c78a912 Larry Finger 2010-08-20  1846  	get_user(addr, (u32 __user *)wrqu->data.pointer);
2865d42c78a912 Larry Finger 2010-08-20  1847  	data32 = ((u32)wrqu->data.length << 16) | (u32)wrqu->data.flags;
2865d42c78a912 Larry Finger 2010-08-20 @1848  	r8712_write32(padapter, addr, data32);
2865d42c78a912 Larry Finger 2010-08-20  1849  	return 0;
2865d42c78a912 Larry Finger 2010-08-20  1850  }
2865d42c78a912 Larry Finger 2010-08-20  1851  

:::::: The code at line 1848 was first introduced by commit
:::::: 2865d42c78a9121caad52cb02d1fbb7f5cdbc4ef staging: r8712u: Add the new driver to the mainline kernel

:::::: TO: Larry Finger <Larry.Finger@lwfinger.net>
:::::: CC: Larry Finger <Larry.Finger@lwfinger.net>

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

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2019-11-11  6:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-11-11  6:35 drivers/staging/rtl8712/rtl871x_ioctl_linux.c:1848:2: warning: 'addr' may be used uninitialized in this function kbuild test robot

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).