All of lore.kernel.org
 help / color / mirror / Atom feed
* [nbd168-wireless:mt76 75/89] drivers/net/wireless/mediatek/mt76/mt7603/main.c:717:9: warning: Identical condition 'ret', second condition is always false
@ 2020-12-04 21:27 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2020-12-04 21:27 UTC (permalink / raw)
  To: kbuild

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

CC: kbuild-all(a)lists.01.org
TO: Lorenzo Bianconi <lorenzo@kernel.org>
CC: Felix Fietkau <nbd@nbd.name>

tree:   https://github.com/nbd168/wireless mt76
head:   01ef374d9117f199ba8abc8a284aa5929a955f6d
commit: 91990519298e231bf102f7242d5f483bef5e514a [75/89] mt76: move tx hw data queues in mt76_phy
:::::: branch date: 8 hours ago
:::::: commit date: 8 hours ago
compiler: microblaze-linux-gcc (GCC) 9.3.0

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


"cppcheck warnings: (new ones prefixed by >>)"
>> drivers/net/wireless/mediatek/mt76/mt7615/mcu.c:106:52: warning: Same value in both branches of ternary operator. [duplicateValueTernary]
    txd_len = cmd & MCU_UNI_PREFIX ? sizeof(*uni_txd) : sizeof(*mcu_txd);
                                                      ^

cppcheck possible warnings: (new ones prefixed by >>, may not real problems)

>> drivers/net/wireless/mediatek/mt76/mt7603/mcu.c:307:4: warning: Unused variable: __packed [unusedVariable]
    } __packed;
      ^
--
>> drivers/net/wireless/mediatek/mt76/mt7603/main.c:717:9: warning: Identical condition 'ret', second condition is always false [identicalConditionAfterEarlyExit]
    return ret;
           ^
   drivers/net/wireless/mediatek/mt76/mt7603/main.c:709:6: note: first condition
    if (ret)
        ^
   drivers/net/wireless/mediatek/mt76/mt7603/main.c:717:9: note: second condition
    return ret;
           ^
--
>> drivers/net/wireless/mediatek/mt76/mt7603/mac.c:448:41: warning: Array 'dev->mphy.q_tx[3]' accessed at index 3, which is out of bounds. [arrayIndexOutOfBounds]
      struct mt76_queue *q = dev->mphy.q_tx[i];
                                           ^
   drivers/net/wireless/mediatek/mt76/mt7603/mac.c:1518:21: warning: Array 'dev->mphy.q_tx[3]' accessed at index 3, which is out of bounds. [arrayIndexOutOfBounds]
     q = dev->mphy.q_tx[i];
                       ^
>> drivers/net/wireless/mediatek/mt76/mt7615/mcu.c:3026:36: warning: Boolean result is used in bitwise operation. Clarify expression with parentheses. [clarifyCondition]
    req->seq_num = mvif->scan_seq_num | ext_phy << 7;
                                      ^
   drivers/net/wireless/mediatek/mt76/mt7615/mcu.c:3137:36: warning: Boolean result is used in bitwise operation. Clarify expression with parentheses. [clarifyCondition]
    req->seq_num = mvif->scan_seq_num | ext_phy << 7;
                                      ^
>> drivers/net/wireless/mediatek/mt76/mt7615/mcu.c:2964:4: warning: Unused variable: __packed [unusedVariable]
    } __packed;
      ^
>> drivers/net/wireless/mediatek/mt76/mt76x02_mmio.c:349:21: warning: Array 'dev->mphy.q_tx[3]' accessed at index 3, which is out of bounds. [arrayIndexOutOfBounds]
     q = dev->mphy.q_tx[i];
                       ^

vim +/ret +717 drivers/net/wireless/mediatek/mt76/mt7603/main.c

c8846e1015022d2 Felix Fietkau 2018-11-06  703  
c8846e1015022d2 Felix Fietkau 2018-11-06  704  static int __init mt7603_init(void)
c8846e1015022d2 Felix Fietkau 2018-11-06  705  {
c8846e1015022d2 Felix Fietkau 2018-11-06  706  	int ret;
c8846e1015022d2 Felix Fietkau 2018-11-06  707  
c8846e1015022d2 Felix Fietkau 2018-11-06  708  	ret = platform_driver_register(&mt76_wmac_driver);
c8846e1015022d2 Felix Fietkau 2018-11-06  709  	if (ret)
c8846e1015022d2 Felix Fietkau 2018-11-06  710  		return ret;
c8846e1015022d2 Felix Fietkau 2018-11-06  711  
c8846e1015022d2 Felix Fietkau 2018-11-06  712  #ifdef CONFIG_PCI
c8846e1015022d2 Felix Fietkau 2018-11-06  713  	ret = pci_register_driver(&mt7603_pci_driver);
c8846e1015022d2 Felix Fietkau 2018-11-06  714  	if (ret)
c8846e1015022d2 Felix Fietkau 2018-11-06  715  		platform_driver_unregister(&mt76_wmac_driver);
c8846e1015022d2 Felix Fietkau 2018-11-06  716  #endif
c8846e1015022d2 Felix Fietkau 2018-11-06 @717  	return ret;
c8846e1015022d2 Felix Fietkau 2018-11-06  718  }
c8846e1015022d2 Felix Fietkau 2018-11-06  719  

:::::: The code at line 717 was first introduced by commit
:::::: c8846e1015022d2531ac4c895783e400b3e5babe mt76: add driver for MT7603E and MT7628/7688

:::::: TO: Felix Fietkau <nbd@nbd.name>
:::::: CC: Felix Fietkau <nbd@nbd.name>

---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org

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

only message in thread, other threads:[~2020-12-04 21:27 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-12-04 21:27 [nbd168-wireless:mt76 75/89] drivers/net/wireless/mediatek/mt76/mt7603/main.c:717:9: warning: Identical condition 'ret', second condition is always false kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.