Re: [PATCH v3 2/7] drivers: mfd: Add a driver for iEi WT61P803 PUZZLE MCU

From: kernel test robot
Date: Wed Sep 30 2020 - 04:40:49 EST


Hi Luka,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on hwmon/hwmon-next]
[also build test WARNING on lee-mfd/for-mfd-next pavel-linux-leds/for-next linus/master v5.9-rc7 next-20200929]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]

url: https://github.com/0day-ci/linux/commits/Luka-Kovacic/Add-support-for-the-iEi-Puzzle-M801-board/20200930-094341
base: https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git hwmon-next
config: openrisc-randconfig-r033-20200930 (attached as .config)
compiler: or1k-linux-gcc (GCC) 9.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/0day-ci/linux/commit/3f186576324e22bba3e3893d6f3cf3ce91d70da7
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Luka-Kovacic/Add-support-for-the-iEi-Puzzle-M801-board/20200930-094341
git checkout 3f186576324e22bba3e3893d6f3cf3ce91d70da7
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=openrisc

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

All warnings (new ones prefixed by >>):

>> drivers/mfd/iei-wt61p803-puzzle.c:309:5: warning: no previous prototype for 'iei_wt61p803_puzzle_buzzer' [-Wmissing-prototypes]
309 | int iei_wt61p803_puzzle_buzzer(struct iei_wt61p803_puzzle *mcu, bool long_beep)
| ^~~~~~~~~~~~~~~~~~~~~~~~~~

vim +/iei_wt61p803_puzzle_buzzer +309 drivers/mfd/iei-wt61p803-puzzle.c

308
> 309 int iei_wt61p803_puzzle_buzzer(struct iei_wt61p803_puzzle *mcu, bool long_beep)
310 {
311 unsigned char buzzer_short_cmd[4] = {
312 IEI_WT61P803_PUZZLE_CMD_HEADER_START,
313 IEI_WT61P803_PUZZLE_CMD_FUNCTION_SINGLE,
314 '2'
315 }; /* Buzzer 0.5 sec */
316 unsigned char buzzer_long_cmd[4] = {
317 IEI_WT61P803_PUZZLE_CMD_HEADER_START,
318 IEI_WT61P803_PUZZLE_CMD_FUNCTION_SINGLE,
319 '3'
320 }; /* Buzzer 1.5 sec */
321 unsigned char *resp_buf = mcu->response_buffer;
322 size_t reply_size = 0;
323 int ret;
324
325 mutex_lock(&mcu->lock);
326 ret = iei_wt61p803_puzzle_write_command(mcu,
327 long_beep ? buzzer_long_cmd : buzzer_short_cmd, 4,
328 resp_buf, &reply_size);
329 if (ret)
330 goto exit;
331
332 if (reply_size != 3) {
333 ret = -EIO;
334 goto exit;
335 }
336
337 if (!(resp_buf[0] == IEI_WT61P803_PUZZLE_CMD_HEADER_START &&
338 resp_buf[1] == IEI_WT61P803_PUZZLE_CMD_RESPONSE_OK &&
339 resp_buf[2] == IEI_WT61P803_PUZZLE_CHECKSUM_RESPONSE_OK)) {
340 ret = -EPROTO;
341 goto exit;
342 }
343 exit:
344 mutex_unlock(&mcu->lock);
345 return ret;
346 }
347

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

Attachment: .config.gz
Description: application/gzip