From: kernel test robot <lkp@intel.com>
To: Arnd Bergmann <arnd@arndb.de>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org,
Linus Walleij <linus.walleij@linaro.org>
Subject: kernel/time/clocksource.c:1053:9: warning: no previous prototype for 'sysfs_get_uname'
Date: Thu, 11 Nov 2021 00:46:54 +0800 [thread overview]
Message-ID: <202111110045.DsNsKG7H-lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 3063 bytes --]
Hi Arnd,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: cb690f5238d71f543f4ce874aa59237cf53a877c
commit: 686092e7daaa9f43396c57ea0044799e47f0d9da parisc: use legacy_timer_tick
date: 1 year ago
config: parisc-buildonly-randconfig-r005-20210927 (attached as .config)
compiler: hppa64-linux-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://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=686092e7daaa9f43396c57ea0044799e47f0d9da
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout 686092e7daaa9f43396c57ea0044799e47f0d9da
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-11.2.0 make.cross ARCH=parisc
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 >>):
>> kernel/time/clocksource.c:1053:9: warning: no previous prototype for 'sysfs_get_uname' [-Wmissing-prototypes]
1053 | ssize_t sysfs_get_uname(const char *buf, char *dst, size_t cnt)
| ^~~~~~~~~~~~~~~
vim +/sysfs_get_uname +1053 kernel/time/clocksource.c
734efb467b31e56 John Stultz 2006-06-26 1052
891292a767c2453 Patrick Palka 2013-10-11 @1053 ssize_t sysfs_get_uname(const char *buf, char *dst, size_t cnt)
29b5407819f5973 Thomas Gleixner 2013-04-25 1054 {
29b5407819f5973 Thomas Gleixner 2013-04-25 1055 size_t ret = cnt;
29b5407819f5973 Thomas Gleixner 2013-04-25 1056
29b5407819f5973 Thomas Gleixner 2013-04-25 1057 /* strings from sysfs write are not 0 terminated! */
29b5407819f5973 Thomas Gleixner 2013-04-25 1058 if (!cnt || cnt >= CS_NAME_LEN)
29b5407819f5973 Thomas Gleixner 2013-04-25 1059 return -EINVAL;
29b5407819f5973 Thomas Gleixner 2013-04-25 1060
29b5407819f5973 Thomas Gleixner 2013-04-25 1061 /* strip of \n: */
29b5407819f5973 Thomas Gleixner 2013-04-25 1062 if (buf[cnt-1] == '\n')
29b5407819f5973 Thomas Gleixner 2013-04-25 1063 cnt--;
29b5407819f5973 Thomas Gleixner 2013-04-25 1064 if (cnt > 0)
29b5407819f5973 Thomas Gleixner 2013-04-25 1065 memcpy(dst, buf, cnt);
29b5407819f5973 Thomas Gleixner 2013-04-25 1066 dst[cnt] = 0;
29b5407819f5973 Thomas Gleixner 2013-04-25 1067 return ret;
29b5407819f5973 Thomas Gleixner 2013-04-25 1068 }
29b5407819f5973 Thomas Gleixner 2013-04-25 1069
:::::: The code at line 1053 was first introduced by commit
:::::: 891292a767c2453af0e5be9465e95b06b4b29ebe time: Fix signedness bug in sysfs_get_uname() and its callers
:::::: TO: Patrick Palka <patrick@parcs.ath.cx>
:::::: CC: John Stultz <john.stultz@linaro.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
[-- Attachment #2: .config.gz --]
[-- Type: application/gzip, Size: 39072 bytes --]
next reply other threads:[~2021-11-10 16:47 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-10 16:46 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-09-28 2:00 kernel/time/clocksource.c:1053:9: warning: no previous prototype for 'sysfs_get_uname' kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=202111110045.DsNsKG7H-lkp@intel.com \
--to=lkp@intel.com \
--cc=arnd@arndb.de \
--cc=kbuild-all@lists.01.org \
--cc=linus.walleij@linaro.org \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox