From mboxrd@z Thu Jan 1 00:00:00 1970 Content-Type: multipart/mixed; boundary="===============6359048263433445639==" MIME-Version: 1.0 From: kernel test robot To: kbuild-all@lists.01.org Subject: Re: [PATCH] staging: pi433: add rf69_dbg_hex function Date: Fri, 11 Feb 2022 18:12:00 +0800 Message-ID: <202202111821.UaNmElDF-lkp@intel.com> In-Reply-To: List-Id: --===============6359048263433445639== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Hi Paulo, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on staging/staging-testing] url: https://github.com/0day-ci/linux/commits/Paulo-Miguel-Almeida/stagi= ng-pi433-add-rf69_dbg_hex-function/20220211-160900 base: https://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging.git = f2c461536226eb0852a241e72b9125685d6741b4 config: arc-randconfig-r043-20220211 (https://download.01.org/0day-ci/archi= ve/20220211/202202111821.UaNmElDF-lkp(a)intel.com/config) compiler: arc-elf-gcc (GCC) 11.2.0 reproduce (this is a W=3D1 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/0day-ci/linux/commit/a7ea3ecd6bd7905c6ee495a10= 53108c2bb922ec2 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Paulo-Miguel-Almeida/staging-pi433= -add-rf69_dbg_hex-function/20220211-160900 git checkout a7ea3ecd6bd7905c6ee495a1053108c2bb922ec2 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=3D$HOME/0day COMPILER=3Dgcc-11.2.0 make.cross= O=3Dbuild_dir ARCH=3Darc SHELL=3D/bin/bash drivers/staging/pi433/ If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot All warnings (new ones prefixed by >>): drivers/staging/pi433/rf69.c: In function 'rf69_dbg_hex': >> drivers/staging/pi433/rf69.c:837:9: warning: function 'rf69_dbg_hex' mig= ht be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=3D= format] 837 | text_pos =3D vscnprintf(text, sizeof(textbuf), fmt, args= ); | ^~~~~~~~ vim +837 drivers/staging/pi433/rf69.c 824 = 825 static void rf69_dbg_hex(struct spi_device *spi, u8 *buf, unsigned i= nt size, 826 const char *fmt, ...) 827 { 828 va_list args; 829 char textbuf[512] =3D {}; 830 char *text =3D textbuf; 831 int text_pos; 832 = 833 int rowsize =3D 16; 834 int i, linelen, remaining =3D size; 835 = 836 va_start(args, fmt); > 837 text_pos =3D vscnprintf(text, sizeof(textbuf), fmt, args); 838 text +=3D text_pos; 839 va_end(args); 840 = 841 for (i =3D 0; i < size; i +=3D rowsize) { 842 linelen =3D min(remaining, rowsize); 843 remaining -=3D rowsize; 844 = 845 hex_dump_to_buffer(buf + i, linelen, rowsize, 1, 846 text, sizeof(textbuf) - text_pos, false); 847 = 848 dev_dbg(&spi->dev, "%s\n", textbuf); 849 = 850 memset(text, 0, sizeof(textbuf) - text_pos); 851 } 852 } 853 = --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org --===============6359048263433445639==--