[driver-core:debugfs_cleanup 67/70] drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'

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

 



tree:   https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core.git debugfs_cleanup
head:   ab2bf016efcd6603fab18068c1f3dd76f1389f7f
commit: 8cc1d21c4abb620671c8011ba78a17ad2430b93a [67/70] realtek: no need to check return value of debugfs_create functions
config: sh-allmodconfig (attached as .config)
compiler: sh4-linux-gnu-gcc (Debian 7.2.0-11) 7.2.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 8cc1d21c4abb620671c8011ba78a17ad2430b93a
        # save the attached .config to linux build tree
        GCC_VERSION=7.2.0 make.cross ARCH=sh 

All warnings (new ones prefixed by >>):

   drivers/net/wireless/realtek/rtlwifi/debug.c: In function 'rtl_debug_add_one':
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/wireless/realtek/rtlwifi/debug.c:489:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_0);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
>> drivers/net/wireless/realtek/rtlwifi/debug.c:489:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_0);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:490:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_1);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:490:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_1);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:491:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_2);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:491:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_2);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:492:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_3);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:492:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_3);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:493:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_4);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:493:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_4);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:494:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_5);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:494:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_5);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:495:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_6);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:495:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_6);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:496:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_7);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:496:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(mac_7);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:497:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(bb_8);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected statement before ')' token
            &file_ops_ ##fopname))     \
                                 ^
>> drivers/net/wireless/realtek/rtlwifi/debug.c:472:3: note: in expansion of macro 'RTL_DEBUGFS_ADD_CORE'
      RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
      ^~~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:497:2: note: in expansion of macro 'RTL_DEBUGFS_ADD'
     RTL_DEBUGFS_ADD(bb_8);
     ^~~~~~~~~~~~~~~
   drivers/net/wireless/realtek/rtlwifi/debug.c:468:30: error: expected ';' before ')' token
            &file_ops_ ##fopname))     \
                                 ^

vim +/RTL_DEBUGFS_ADD_CORE +472 drivers/net/wireless/realtek/rtlwifi/debug.c

610247f4 Ping-Ke Shih       2017-12-29  462  
610247f4 Ping-Ke Shih       2017-12-29  463  #define RTL_DEBUGFS_ADD_CORE(name, mode, fopname)			   \
610247f4 Ping-Ke Shih       2017-12-29  464  	do {								   \
610247f4 Ping-Ke Shih       2017-12-29  465  		rtl_debug_priv_ ##name.rtlpriv = rtlpriv;		   \
8cc1d21c Greg Kroah-Hartman 2019-01-03  466  		debugfs_create_file(#name, mode, parent,		   \
8cc1d21c Greg Kroah-Hartman 2019-01-03  467  				    &rtl_debug_priv_ ##name,		   \
610247f4 Ping-Ke Shih       2017-12-29 @468  				    &file_ops_ ##fopname))		   \
610247f4 Ping-Ke Shih       2017-12-29  469  	} while (0)
610247f4 Ping-Ke Shih       2017-12-29  470  
610247f4 Ping-Ke Shih       2017-12-29  471  #define RTL_DEBUGFS_ADD(name)						   \
610247f4 Ping-Ke Shih       2017-12-29 @472  		RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0444, common)
610247f4 Ping-Ke Shih       2017-12-29  473  #define RTL_DEBUGFS_ADD_W(name)						   \
610247f4 Ping-Ke Shih       2017-12-29  474  		RTL_DEBUGFS_ADD_CORE(name, S_IFREG | 0222, common_write)
610247f4 Ping-Ke Shih       2017-12-29  475  
610247f4 Ping-Ke Shih       2017-12-29  476  void rtl_debug_add_one(struct ieee80211_hw *hw)
610247f4 Ping-Ke Shih       2017-12-29  477  {
610247f4 Ping-Ke Shih       2017-12-29  478  	struct rtl_priv *rtlpriv = rtl_priv(hw);
610247f4 Ping-Ke Shih       2017-12-29  479  	struct rtl_efuse *rtlefuse = rtl_efuse(rtl_priv(hw));
610247f4 Ping-Ke Shih       2017-12-29  480  	struct dentry *parent;
610247f4 Ping-Ke Shih       2017-12-29  481  
610247f4 Ping-Ke Shih       2017-12-29  482  	snprintf(rtlpriv->dbg.debugfs_name, 18, "%pMF", rtlefuse->dev_addr);
610247f4 Ping-Ke Shih       2017-12-29  483  
610247f4 Ping-Ke Shih       2017-12-29  484  	rtlpriv->dbg.debugfs_dir =
610247f4 Ping-Ke Shih       2017-12-29  485  		debugfs_create_dir(rtlpriv->dbg.debugfs_name, debugfs_topdir);
610247f4 Ping-Ke Shih       2017-12-29  486  
610247f4 Ping-Ke Shih       2017-12-29  487  	parent = rtlpriv->dbg.debugfs_dir;
610247f4 Ping-Ke Shih       2017-12-29  488  
610247f4 Ping-Ke Shih       2017-12-29 @489  	RTL_DEBUGFS_ADD(mac_0);
610247f4 Ping-Ke Shih       2017-12-29  490  	RTL_DEBUGFS_ADD(mac_1);
610247f4 Ping-Ke Shih       2017-12-29  491  	RTL_DEBUGFS_ADD(mac_2);
610247f4 Ping-Ke Shih       2017-12-29  492  	RTL_DEBUGFS_ADD(mac_3);
610247f4 Ping-Ke Shih       2017-12-29  493  	RTL_DEBUGFS_ADD(mac_4);
610247f4 Ping-Ke Shih       2017-12-29  494  	RTL_DEBUGFS_ADD(mac_5);
610247f4 Ping-Ke Shih       2017-12-29  495  	RTL_DEBUGFS_ADD(mac_6);
610247f4 Ping-Ke Shih       2017-12-29  496  	RTL_DEBUGFS_ADD(mac_7);
610247f4 Ping-Ke Shih       2017-12-29  497  	RTL_DEBUGFS_ADD(bb_8);
610247f4 Ping-Ke Shih       2017-12-29  498  	RTL_DEBUGFS_ADD(bb_9);
610247f4 Ping-Ke Shih       2017-12-29  499  	RTL_DEBUGFS_ADD(bb_a);
610247f4 Ping-Ke Shih       2017-12-29  500  	RTL_DEBUGFS_ADD(bb_b);
610247f4 Ping-Ke Shih       2017-12-29  501  	RTL_DEBUGFS_ADD(bb_c);
610247f4 Ping-Ke Shih       2017-12-29  502  	RTL_DEBUGFS_ADD(bb_d);
610247f4 Ping-Ke Shih       2017-12-29  503  	RTL_DEBUGFS_ADD(bb_e);
610247f4 Ping-Ke Shih       2017-12-29  504  	RTL_DEBUGFS_ADD(bb_f);
610247f4 Ping-Ke Shih       2017-12-29  505  	RTL_DEBUGFS_ADD(mac_10);
610247f4 Ping-Ke Shih       2017-12-29  506  	RTL_DEBUGFS_ADD(mac_11);
610247f4 Ping-Ke Shih       2017-12-29  507  	RTL_DEBUGFS_ADD(mac_12);
610247f4 Ping-Ke Shih       2017-12-29  508  	RTL_DEBUGFS_ADD(mac_13);
610247f4 Ping-Ke Shih       2017-12-29  509  	RTL_DEBUGFS_ADD(mac_14);
610247f4 Ping-Ke Shih       2017-12-29  510  	RTL_DEBUGFS_ADD(mac_15);
610247f4 Ping-Ke Shih       2017-12-29  511  	RTL_DEBUGFS_ADD(mac_16);
610247f4 Ping-Ke Shih       2017-12-29  512  	RTL_DEBUGFS_ADD(mac_17);
610247f4 Ping-Ke Shih       2017-12-29  513  	RTL_DEBUGFS_ADD(bb_18);
610247f4 Ping-Ke Shih       2017-12-29  514  	RTL_DEBUGFS_ADD(bb_19);
610247f4 Ping-Ke Shih       2017-12-29  515  	RTL_DEBUGFS_ADD(bb_1a);
610247f4 Ping-Ke Shih       2017-12-29  516  	RTL_DEBUGFS_ADD(bb_1b);
610247f4 Ping-Ke Shih       2017-12-29  517  	RTL_DEBUGFS_ADD(bb_1c);
610247f4 Ping-Ke Shih       2017-12-29  518  	RTL_DEBUGFS_ADD(bb_1d);
610247f4 Ping-Ke Shih       2017-12-29  519  	RTL_DEBUGFS_ADD(bb_1e);
610247f4 Ping-Ke Shih       2017-12-29  520  	RTL_DEBUGFS_ADD(bb_1f);
610247f4 Ping-Ke Shih       2017-12-29  521  	RTL_DEBUGFS_ADD(rf_a);
610247f4 Ping-Ke Shih       2017-12-29  522  	RTL_DEBUGFS_ADD(rf_b);
610247f4 Ping-Ke Shih       2017-12-29  523  
610247f4 Ping-Ke Shih       2017-12-29  524  	RTL_DEBUGFS_ADD(cam_1);
610247f4 Ping-Ke Shih       2017-12-29  525  	RTL_DEBUGFS_ADD(cam_2);
610247f4 Ping-Ke Shih       2017-12-29  526  	RTL_DEBUGFS_ADD(cam_3);
610247f4 Ping-Ke Shih       2017-12-29  527  
610247f4 Ping-Ke Shih       2017-12-29 @528  	RTL_DEBUGFS_ADD(btcoex);
610247f4 Ping-Ke Shih       2017-12-29  529  
610247f4 Ping-Ke Shih       2017-12-29 @530  	RTL_DEBUGFS_ADD_W(write_reg);
610247f4 Ping-Ke Shih       2017-12-29  531  	RTL_DEBUGFS_ADD_W(write_h2c);
610247f4 Ping-Ke Shih       2017-12-29  532  	RTL_DEBUGFS_ADD_W(write_rfreg);
610247f4 Ping-Ke Shih       2017-12-29  533  }
610247f4 Ping-Ke Shih       2017-12-29  534  EXPORT_SYMBOL_GPL(rtl_debug_add_one);
610247f4 Ping-Ke Shih       2017-12-29  535  

:::::: The code at line 472 was first introduced by commit
:::::: 610247f46feb23beda99d0bb44aa8f51a8dc27e1 rtlwifi: Improve debugging by using debugfs

:::::: TO: Ping-Ke Shih <pkshih@xxxxxxxxxxx>
:::::: CC: Kalle Valo <kvalo@xxxxxxxxxxxxxx>

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

Attachment: .config.gz
Description: application/gzip

_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux