lkml.org 
[lkml]   [2022]   [Jun]   [4]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
Subject[jcmvbkbc-xtensa:xtensa-5.18-esp32 42/45] drivers/tty/serial/esp32_uart.c:33:6: warning: no previous prototype for 'dbg_echo'
tree:   https://github.com/jcmvbkbc/linux-xtensa xtensa-5.18-esp32
head: 137adeae90088411fe27a1be624afd8336542302
commit: 4475ad0ed7f7654f6cbc879814c0a2bad8274db4 [42/45] WIP: drivers/tty/serial: add driver for ESP32 UART
config: powerpc-allmodconfig (https://download.01.org/0day-ci/archive/20220604/202206041621.cmMY1siz-lkp@intel.com/config)
compiler: powerpc-linux-gcc (GCC) 11.3.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/jcmvbkbc/linux-xtensa/commit/4475ad0ed7f7654f6cbc879814c0a2bad8274db4
git remote add jcmvbkbc-xtensa https://github.com/jcmvbkbc/linux-xtensa
git fetch --no-tags jcmvbkbc-xtensa xtensa-5.18-esp32
git checkout 4475ad0ed7f7654f6cbc879814c0a2bad8274db4
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.3.0 make.cross W=1 O=build_dir ARCH=powerpc SHELL=/bin/bash drivers/tty/serial/

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

All warnings (new ones prefixed by >>):

>> drivers/tty/serial/esp32_uart.c:33:6: warning: no previous prototype for 'dbg_echo' [-Wmissing-prototypes]
33 | void dbg_echo(const char *s)
| ^~~~~~~~
>> drivers/tty/serial/esp32_uart.c:48:6: warning: no previous prototype for 'dbg_printf' [-Wmissing-prototypes]
48 | void dbg_printf(const char *fmt, ...)
| ^~~~~~~~~~
drivers/tty/serial/esp32_uart.c: In function 'dbg_printf':
>> drivers/tty/serial/esp32_uart.c:54:9: warning: function 'dbg_printf' might be a candidate for 'gnu_printf' format attribute [-Wsuggest-attribute=format]
54 | vsnprintf(buf, sizeof(buf), fmt, ap);
| ^~~~~~~~~


vim +/dbg_echo +33 drivers/tty/serial/esp32_uart.c

32
> 33 void dbg_echo(const char *s)
34 {
35 volatile void __iomem *base = (volatile void __iomem *)0x3ff40000;
36
37 while ((readl(base + UART_STATUS_REG) & UART_TXFIFO_CNT_MASK) != 0)
38 ;
39
40 while (*s) {
41 if (*s == '\n')
42 writel('\r', base + UART_FIFO_REG);
43 writel(*s, base + UART_FIFO_REG);
44 ++s;
45 }
46 }
47
> 48 void dbg_printf(const char *fmt, ...)
49 {
50 va_list ap;
51 char buf[256];
52
53 va_start(ap, fmt);
> 54 vsnprintf(buf, sizeof(buf), fmt, ap);
55 va_end(ap);
56 dbg_echo(buf);
57 }
58

--
0-DAY CI Kernel Test Service
https://01.org/lkp

\
 
 \ /
  Last update: 2022-06-04 10:16    [W:0.021 / U:1.688 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site