Search Linux Wireless

Re: [kbuild] Re: [PATCH v2 1/2] mt76: mt7915: add missing capabilities for DBDC

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

 



On Wed, 2021-03-10 at 11:30 +0300, Dan Carpenter wrote:
> Hi Ryder,
> 
> url:    https://github.com/0day-ci/linux/commits/Ryder-Lee/mt76-mt7915-add-missing-capabilities-for-DBDC/20210225-230323 
> base:   https://git.kernel.org/pub/scm/linux/kernel/git/kvalo/wireless-drivers-next.git  master
> config: x86_64-randconfig-m001-20210309 (attached as .config)
> compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
> 
> If you fix the issue, kindly add following tag as appropriate
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Reported-by: Dan Carpenter <dan.carpenter@xxxxxxxxxx>
> 
> smatch warnings:
> drivers/net/wireless/mediatek/mt76/mt7915/init.c:353 mt7915_set_stream_vht_txbf_caps() error: potentially dereferencing uninitialized 'cap'.
> 
> vim +/cap +353 drivers/net/wireless/mediatek/mt76/mt7915/init.c
> 
> 00b2e16e006390 Ryder Lee 2020-05-12  344  void mt7915_set_stream_vht_txbf_caps(struct mt7915_phy *phy)
> 00b2e16e006390 Ryder Lee 2020-05-12  345  {
> 50a6fe79623e22 Ryder Lee 2021-02-25  346  	int nss;
> 50a6fe79623e22 Ryder Lee 2021-02-25  347  	u32 *cap;
> 50a6fe79623e22 Ryder Lee 2021-02-25  348  
> 50a6fe79623e22 Ryder Lee 2021-02-25  349  	if (!phy->mt76->cap.has_5ghz)
> 50a6fe79623e22 Ryder Lee 2021-02-25  350  		return;
> 50a6fe79623e22 Ryder Lee 2021-02-25  351  
> 50a6fe79623e22 Ryder Lee 2021-02-25  352  	nss = hweight8(phy->mt76->chainmask);
> 50a6fe79623e22 Ryder Lee 2021-02-25 @353  	*cap = &phy->mt76->sband_5g.sband.vht_cap.cap;
>                                                 ^^^^
> "cap" isn't initialized.

This has been fixed in v3
https://patchwork.kernel.org/project/linux-mediatek/patch/427ab5a2a79b8bbfa05225cfe4cfb55b3f143c8c.1614357346.git.ryder.lee@xxxxxxxxxxxx/

Ryder





[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux