tree:
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: fb57b1fabcb28f358901b2df90abd2b48abc1ca8
commit: d639836ab3363f935a9a4336cb4ea3828d0437dd [8596/10701] net: qed: adding hw_err
states and handling
config: i386-randconfig-a006-20200520 (attached as .config)
compiler: gcc-6 (Debian 6.3.0-18+deb9u1) 6.3.0 20170516
reproduce:
git checkout d639836ab3363f935a9a4336cb4ea3828d0437dd
# save the attached .config to linux build tree
make ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kbuild test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>, old ones prefixed by <<):
drivers/net/ethernet/qlogic/qed/qed_hw.c: In function 'qed_hw_err_notify':
<< from drivers/net/ethernet/qlogic/qed/qed_hw.c:46:
> drivers/net/ethernet/qlogic/qed/qed_hw.c:850:3: warning: function
might be possible candidate for 'gnu_printf' format attribute
[-Wsuggest-attribute=format]
len = vsnprintf(buf, QED_HW_ERR_MAX_STR_SIZE, fmt,
vl);
^~~
In file included from drivers/net/ethernet/qlogic/qed/qed.h:51:0,
from drivers/net/ethernet/qlogic/qed/qed_hw.c:46:
At top level:
drivers/net/ethernet/qlogic/qed/qed_hsi.h:4421:18: warning: 'iro_arr' defined but
not used [-Wunused-const-variable=]
static const u32 iro_arr[] = {
^~~~~~~
vim +/gnu_printf +850 drivers/net/ethernet/qlogic/qed/qed_hw.c
839
840 void qed_hw_err_notify(struct qed_hwfn *p_hwfn,
841 struct qed_ptt *p_ptt,
842 enum qed_hw_err_type err_type, char *fmt, ...)
843 {
844 char buf[QED_HW_ERR_MAX_STR_SIZE];
845 va_list vl;
846 int len;
847
848 if (fmt) {
849 va_start(vl, fmt);
850 len = vsnprintf(buf, QED_HW_ERR_MAX_STR_SIZE, fmt, vl);
851 va_end(vl);
852
853 if (len > QED_HW_ERR_MAX_STR_SIZE - 1)
854 len = QED_HW_ERR_MAX_STR_SIZE - 1;
855
856 DP_NOTICE(p_hwfn, "%s", buf);
857 }
858
859 /* Fan failure cannot be masked by handling of another HW error */
860 if (p_hwfn->cdev->recov_in_prog &&
861 err_type != QED_HW_ERR_FAN_FAIL) {
862 DP_VERBOSE(p_hwfn,
863 NETIF_MSG_DRV,
864 "Recovery is in progress. Avoid notifying about HW error %d.\n",
865 err_type);
866 return;
867 }
868
869 qed_hw_error_occurred(p_hwfn, err_type);
870 }
871
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org