From: kernel test robot <lkp@intel.com>
To: Ingo Molnar <mingo@kernel.org>
Cc: kbuild-all@lists.01.org, linux-kernel@vger.kernel.org, x86@kernel.org
Subject: [tip:tmp.tmp2 255/364] include/linux/printk.h:505:9: error: type defaults to 'int' in declaration of 'DEFINE_RATELIMIT_STATE'
Date: Tue, 15 Jun 2021 02:20:00 +0800 [thread overview]
Message-ID: <202106150250.tUEUUWIf-lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 6206 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git tmp.tmp2
head: adcceb5eb7aee38e4a9c15bdf599655f0e1b1324
commit: a490873e1d58c0b339bb50ee382dc1fe95c6d9a4 [255/364] sched/headers, printk: Reduce <linux/printk.h> header dependencies
config: x86_64-rhel-8.3 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
# https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git/commit/?id=a490873e1d58c0b339bb50ee382dc1fe95c6d9a4
git remote add tip https://git.kernel.org/pub/scm/linux/kernel/git/tip/tip.git
git fetch --no-tags tip tmp.tmp2
git checkout a490873e1d58c0b339bb50ee382dc1fe95c6d9a4
# save the attached .config to linux build tree
make W=1 ARCH=x86_64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>
All error/warnings (new ones prefixed by >>):
In file included from include/linux/kernel.h:7,
from include/linux/crypto.h:16,
from include/crypto/algapi.h:10,
from crypto/arc4.c:10:
crypto/arc4.c: In function 'crypto_arc4_init':
>> include/linux/printk.h:505:9: error: type defaults to 'int' in declaration of 'DEFINE_RATELIMIT_STATE' [-Werror=implicit-int]
505 | static DEFINE_RATELIMIT_STATE(_rs, \
| ^~~~~~~~~~~~~~~~~~~~~~
include/linux/printk.h:526:2: note: in expansion of macro 'printk_ratelimited'
526 | printk_ratelimited(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
crypto/arc4.c:46:2: note: in expansion of macro 'pr_warn_ratelimited'
46 | pr_warn_ratelimited("\"%s\" (%ld) uses obsolete ecb(arc4) skcipher\n",
| ^~~~~~~~~~~~~~~~~~~
>> crypto/arc4.c:46:2: warning: parameter names (without types) in function declaration
In file included from include/linux/kernel.h:7,
from include/linux/crypto.h:16,
from include/crypto/algapi.h:10,
from crypto/arc4.c:10:
>> include/linux/printk.h:505:9: error: invalid storage class for function 'DEFINE_RATELIMIT_STATE'
505 | static DEFINE_RATELIMIT_STATE(_rs, \
| ^~~~~~~~~~~~~~~~~~~~~~
include/linux/printk.h:526:2: note: in expansion of macro 'printk_ratelimited'
526 | printk_ratelimited(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
crypto/arc4.c:46:2: note: in expansion of macro 'pr_warn_ratelimited'
46 | pr_warn_ratelimited("\"%s\" (%ld) uses obsolete ecb(arc4) skcipher\n",
| ^~~~~~~~~~~~~~~~~~~
>> include/linux/printk.h:509:6: error: implicit declaration of function '__ratelimit' [-Werror=implicit-function-declaration]
509 | if (__ratelimit(&_rs)) \
| ^~~~~~~~~~~
include/linux/printk.h:526:2: note: in expansion of macro 'printk_ratelimited'
526 | printk_ratelimited(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
crypto/arc4.c:46:2: note: in expansion of macro 'pr_warn_ratelimited'
46 | pr_warn_ratelimited("\"%s\" (%ld) uses obsolete ecb(arc4) skcipher\n",
| ^~~~~~~~~~~~~~~~~~~
>> include/linux/printk.h:509:19: error: '_rs' undeclared (first use in this function)
509 | if (__ratelimit(&_rs)) \
| ^~~
include/linux/printk.h:526:2: note: in expansion of macro 'printk_ratelimited'
526 | printk_ratelimited(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
crypto/arc4.c:46:2: note: in expansion of macro 'pr_warn_ratelimited'
46 | pr_warn_ratelimited("\"%s\" (%ld) uses obsolete ecb(arc4) skcipher\n",
| ^~~~~~~~~~~~~~~~~~~
include/linux/printk.h:509:19: note: each undeclared identifier is reported only once for each function it appears in
509 | if (__ratelimit(&_rs)) \
| ^~~
include/linux/printk.h:526:2: note: in expansion of macro 'printk_ratelimited'
526 | printk_ratelimited(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~~~~~~~~
crypto/arc4.c:46:2: note: in expansion of macro 'pr_warn_ratelimited'
46 | pr_warn_ratelimited("\"%s\" (%ld) uses obsolete ecb(arc4) skcipher\n",
| ^~~~~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +505 include/linux/printk.h
16cb839f133249 Joe Perches 2011-01-12 497
968ab1838a5d48 Linus Torvalds 2010-11-15 498 /*
968ab1838a5d48 Linus Torvalds 2010-11-15 499 * ratelimited messages with local ratelimit_state,
968ab1838a5d48 Linus Torvalds 2010-11-15 500 * no local ratelimit_state used in the !PRINTK case
968ab1838a5d48 Linus Torvalds 2010-11-15 501 */
968ab1838a5d48 Linus Torvalds 2010-11-15 502 #ifdef CONFIG_PRINTK
6ec42a56e25846 Joe Perches 2011-01-12 503 #define printk_ratelimited(fmt, ...) \
6ec42a56e25846 Joe Perches 2011-01-12 504 ({ \
968ab1838a5d48 Linus Torvalds 2010-11-15 @505 static DEFINE_RATELIMIT_STATE(_rs, \
968ab1838a5d48 Linus Torvalds 2010-11-15 506 DEFAULT_RATELIMIT_INTERVAL, \
968ab1838a5d48 Linus Torvalds 2010-11-15 507 DEFAULT_RATELIMIT_BURST); \
968ab1838a5d48 Linus Torvalds 2010-11-15 508 \
968ab1838a5d48 Linus Torvalds 2010-11-15 @509 if (__ratelimit(&_rs)) \
968ab1838a5d48 Linus Torvalds 2010-11-15 510 printk(fmt, ##__VA_ARGS__); \
968ab1838a5d48 Linus Torvalds 2010-11-15 511 })
968ab1838a5d48 Linus Torvalds 2010-11-15 512 #else
6ec42a56e25846 Joe Perches 2011-01-12 513 #define printk_ratelimited(fmt, ...) \
6ec42a56e25846 Joe Perches 2011-01-12 514 no_printk(fmt, ##__VA_ARGS__)
968ab1838a5d48 Linus Torvalds 2010-11-15 515 #endif
968ab1838a5d48 Linus Torvalds 2010-11-15 516
:::::: The code at line 505 was first introduced by commit
:::::: 968ab1838a5d48f02f5b471aa1d0e59e2cc2ccbc include/linux/kernel.h: Move logging bits to include/linux/printk.h
:::::: TO: Linus Torvalds <torvalds@linux-foundation.org>
:::::: CC: Linus Torvalds <torvalds@linux-foundation.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: 41434 bytes --]
reply other threads:[~2021-06-14 18:20 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=202106150250.tUEUUWIf-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mingo@kernel.org \
--cc=x86@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