All of lore.kernel.org
 help / color / mirror / Atom feed
* [frank-w-bpi-r2-4.14:5.15-rc 6/25] drivers/misc/mediatek/btif/common/plat_inc/plat_common.h:64:9: warning: function 'hal_log_print' might be a candidate for 'gnu_printf' format attribute
@ 2021-10-09 21:04 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-10-09 21:04 UTC (permalink / raw)
  To: kbuild-all

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

tree:   https://github.com/frank-w/BPI-R2-4.14 5.15-rc
head:   b61ad126d9da67a52fa395215dc3a4219ff58121
commit: 669b10c8f4390c7a5c587bfc84d4f8615479a9b2 [6/25] mt6625l: include wifi-code
config: arm-randconfig-r025-20211010 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 11.2.0
reproduce (this is a W=1 build):
        wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
        chmod +x ~/bin/make.cross
        # https://github.com/frank-w/BPI-R2-4.14/commit/669b10c8f4390c7a5c587bfc84d4f8615479a9b2
        git remote add frank-w-bpi-r2-4.14 https://github.com/frank-w/BPI-R2-4.14
        git fetch --no-tags frank-w-bpi-r2-4.14 5.15-rc
        git checkout 669b10c8f4390c7a5c587bfc84d4f8615479a9b2
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=arm 

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

All warnings (new ones prefixed by >>):

   In file included from drivers/misc/mediatek/btif/common/plat_inc/btif_pub.h:17,
                    from drivers/misc/mediatek/btif/common/mtk_btif.c:37:
   drivers/misc/mediatek/btif/common/plat_inc/plat_common.h: In function 'hal_log_print':
>> drivers/misc/mediatek/btif/common/plat_inc/plat_common.h:64:9: warning: function 'hal_log_print' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
      64 |         vsnprintf(temp_sring, DBG_LOG_STR_SIZE, str, args);
         |         ^~~~~~~~~
   drivers/misc/mediatek/btif/common/mtk_btif.c: In function 'mtk_btif_restore_noirq':
   drivers/misc/mediatek/btif/common/mtk_btif.c:379:13: warning: variable 'i_ret' set but not used [-Wunused-but-set-variable]
     379 |         int i_ret = 0;
         |             ^~~~~
   drivers/misc/mediatek/btif/common/mtk_btif.c: In function 'flag_store':
   drivers/misc/mediatek/btif/common/mtk_btif.c:773:13: warning: variable 'result' set but not used [-Wunused-but-set-variable]
     773 |         int result = 0;
         |             ^~~~~~
   drivers/misc/mediatek/btif/common/mtk_btif.c: In function 'btif_log_buf_dmp_out':
   drivers/misc/mediatek/btif/common/mtk_btif.c:3029:24: warning: variable 'p_buf' set but not used [-Wunused-but-set-variable]
    3029 |         unsigned char *p_buf = NULL;
         |                        ^~~~~
--
   In file included from drivers/misc/mediatek/btif/common/plat_inc/btif_pub.h:17,
                    from drivers/misc/mediatek/btif/common/inc/mtk_btif.h:37,
                    from drivers/misc/mediatek/btif/common/mtk_btif_exp.c:20:
   drivers/misc/mediatek/btif/common/plat_inc/plat_common.h: In function 'hal_log_print':
>> drivers/misc/mediatek/btif/common/plat_inc/plat_common.h:64:9: warning: function 'hal_log_print' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
      64 |         vsnprintf(temp_sring, DBG_LOG_STR_SIZE, str, args);
         |         ^~~~~~~~~
--
   In file included from drivers/misc/mediatek/btif/common/plat_inc/btif_dma_pub.h:19,
                    from drivers/misc/mediatek/btif/common/plat_inc/btif_dma_priv.h:18,
                    from drivers/misc/mediatek/btif/common/btif_dma_plat.c:22:
   drivers/misc/mediatek/btif/common/plat_inc/plat_common.h: In function 'hal_log_print':
>> drivers/misc/mediatek/btif/common/plat_inc/plat_common.h:64:9: warning: function 'hal_log_print' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
      64 |         vsnprintf(temp_sring, DBG_LOG_STR_SIZE, str, args);
         |         ^~~~~~~~~
   drivers/misc/mediatek/btif/common/btif_dma_plat.c: In function 'hal_dma_pm_ops':
   drivers/misc/mediatek/btif/common/btif_dma_plat.c:1313:38: warning: variable 'flag' set but not used [-Wunused-but-set-variable]
    1313 |                         unsigned int flag = 0;
         |                                      ^~~~
--
   In file included from drivers/misc/mediatek/btif/common/plat_inc/btif_pub.h:17,
                    from drivers/misc/mediatek/btif/common/btif_plat.c:21:
   drivers/misc/mediatek/btif/common/plat_inc/plat_common.h: In function 'hal_log_print':
>> drivers/misc/mediatek/btif/common/plat_inc/plat_common.h:64:9: warning: function 'hal_log_print' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
      64 |         vsnprintf(temp_sring, DBG_LOG_STR_SIZE, str, args);
         |         ^~~~~~~~~
   drivers/misc/mediatek/btif/common/btif_plat.c: In function 'hal_btif_hw_init':
>> drivers/misc/mediatek/btif/common/btif_plat.c:516:39: warning: implicit conversion from 'enum <anonymous>' to 'ENUM_BTIF_MODE' {aka 'enum _ENUM_BTIF_MODE_'} [-Wenum-conversion]
     516 |         hal_btif_tx_mode_ctrl(p_btif, false);
         |                                       ^~~~~
   drivers/misc/mediatek/btif/common/btif_plat.c:518:39: warning: implicit conversion from 'enum <anonymous>' to 'ENUM_BTIF_MODE' {aka 'enum _ENUM_BTIF_MODE_'} [-Wenum-conversion]
     518 |         hal_btif_rx_mode_ctrl(p_btif, false);
         |                                       ^~~~~
   drivers/misc/mediatek/btif/common/btif_plat.c: In function 'hal_btif_pm_ops':
   drivers/misc/mediatek/btif/common/btif_plat.c:1343:38: warning: variable 'flag' set but not used [-Wunused-but-set-variable]
    1343 |                         unsigned int flag = 0;
         |                                      ^~~~

Kconfig warnings: (for reference only)
   WARNING: unmet direct dependencies detected for MTK_GPS
   Depends on ARM && GPS
   Selected by
   - MTK_GPS_SUPPORT && ARM


vim +64 drivers/misc/mediatek/btif/common/plat_inc/plat_common.h

c5ee799ddeb7053 Frank Wunderlich 2021-08-29  56  
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  57  /*Log defination*/
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  58  static int hal_log_print(const char *str, ...)
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  59  {
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  60  	va_list args;
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  61  	char temp_sring[DBG_LOG_STR_SIZE];
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  62  
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  63  	va_start(args, str);
c5ee799ddeb7053 Frank Wunderlich 2021-08-29 @64  	vsnprintf(temp_sring, DBG_LOG_STR_SIZE, str, args);
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  65  	va_end(args);
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  66  
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  67  	pr_err("%s", temp_sring);
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  68  
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  69  	return 0;
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  70  }
c5ee799ddeb7053 Frank Wunderlich 2021-08-29  71  

:::::: The code at line 64 was first introduced by commit
:::::: c5ee799ddeb7053632fb81f09d36b86037eed8d8 mt6625l: add driver folder from 5.14

:::::: TO: Frank Wunderlich <frank-w@public-files.de>
:::::: CC: Frank Wunderlich <frank-w@public-files.de>

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

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

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

only message in thread, other threads:[~2021-10-09 21:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-09 21:04 [frank-w-bpi-r2-4.14:5.15-rc 6/25] drivers/misc/mediatek/btif/common/plat_inc/plat_common.h:64:9: warning: function 'hal_log_print' might be a candidate for 'gnu_printf' format attribute 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.