[linux-next:master 3309/5417] drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:897:29: sparse: sparse: incorrect type in initializer (different base types)

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

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head:   6d9bd4ad4ca08b1114e814c2c42383b8b13be631
commit: 988845c9361a0279d061ad7c2afebf54065b2e83 [3309/5417] mt76: mt7915: add support for passing chip/firmware debug data to user space
config: powerpc-allyesconfig (https://download.01.org/0day-ci/archive/20220212/202202120125.QQmuEWJm-lkp@xxxxxxxxx/config)
compiler: powerpc-linux-gcc (GCC) 11.2.0
reproduce:
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # apt-get install sparse
        # sparse version: v0.6.4-dirty
        # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=988845c9361a0279d061ad7c2afebf54065b2e83
        git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
        git fetch --no-tags linux-next master
        git checkout 988845c9361a0279d061ad7c2afebf54065b2e83
        # save the config file to linux build tree
        mkdir build_dir
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=powerpc SHELL=/bin/bash drivers/net/wireless/mediatek/mt76/mt7915/

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


sparse warnings: (new ones prefixed by >>)
   drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:349:9: sparse: sparse: dubious: x | !y
>> drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:897:29: sparse: sparse: incorrect type in initializer (different base types) @@     expected restricted __le16 [usertype] msg_type @@     got int @@
   drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:897:29: sparse:     expected restricted __le16 [usertype] msg_type
   drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:897:29: sparse:     got int
>> drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:903:23: sparse: sparse: incorrect type in assignment (different base types) @@     expected restricted __le32 [usertype] timestamp @@     got unsigned int @@
   drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:903:23: sparse:     expected restricted __le32 [usertype] timestamp
   drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c:903:23: sparse:     got unsigned int

vim +897 drivers/net/wireless/mediatek/mt76/mt7915/debugfs.c

   887	
   888	void mt7915_debugfs_rx_fw_monitor(struct mt7915_dev *dev, const void *data, int len)
   889	{
   890		struct {
   891			__le32 magic;
   892			__le32 timestamp;
   893			__le16 msg_type;
   894			__le16 len;
   895		} hdr = {
   896			.magic = cpu_to_le32(FW_BIN_LOG_MAGIC),
 > 897			.msg_type = PKT_TYPE_RX_FW_MONITOR,
   898		};
   899	
   900		if (!dev->relay_fwlog)
   901			return;
   902	
 > 903		hdr.timestamp = mt76_rr(dev, MT_LPON_FRCR(0));
   904		hdr.len = *(__le16 *)data;
   905		mt7915_debugfs_write_fwlog(dev, &hdr, sizeof(hdr), data, len);
   906	}
   907	

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




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [eCos]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux