From: kernel test robot <lkp@intel.com>
To: kbuild-all@lists.01.org
Subject: [peterz-queue:x86/fpu 6/9] arch/x86/kernel/jump_label.c:40:27: error: 'JUMP_LABEL_NOP_SIZE' undeclared; did you mean
Date: Sat, 13 Mar 2021 13:37:05 +0800 [thread overview]
Message-ID: <202103131301.nt78RSvY-lkp@intel.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 6372 bytes --]
tree: https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git x86/fpu
head: 42088f5f7dcaf5e6d51b71cb32097ca4dad9b225
commit: 86d276af0556e9e6e579c71a48eff194d907be04 [6/9] jump_label, x86: Introduce jump_entry_size()
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/peterz/queue.git/commit/?id=86d276af0556e9e6e579c71a48eff194d907be04
git remote add peterz-queue https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
git fetch --no-tags peterz-queue x86/fpu
git checkout 86d276af0556e9e6e579c71a48eff194d907be04
# 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 errors (new ones prefixed by >>):
arch/x86/kernel/jump_label.c: In function '__jump_label_set_jump_code':
>> arch/x86/kernel/jump_label.c:40:27: error: 'JUMP_LABEL_NOP_SIZE' undeclared (first use in this function); did you mean 'JUMP_LABEL_NOP'?
40 | if (memcmp(addr, expect, JUMP_LABEL_NOP_SIZE)) {
| ^~~~~~~~~~~~~~~~~~~
| JUMP_LABEL_NOP
arch/x86/kernel/jump_label.c:40:27: note: each undeclared identifier is reported only once for each function it appears in
In file included from include/linux/kernel.h:16,
from arch/x86/include/asm/percpu.h:27,
from arch/x86/include/asm/current.h:6,
from include/linux/sched.h:12,
from include/linux/ratelimit.h:6,
from include/linux/dev_printk.h:16,
from include/linux/device.h:15,
from include/linux/node.h:18,
from include/linux/memory.h:19,
from arch/x86/kernel/jump_label.c:9:
arch/x86/kernel/jump_label.c:47:31: error: 'init' undeclared (first use in this function); did you mean 'int'?
47 | addr, addr, addr, expect, init, type);
| ^~~~
include/linux/printk.h:333:34: note: in definition of macro 'pr_crit'
333 | printk(KERN_CRIT pr_fmt(fmt), ##__VA_ARGS__)
| ^~~~~~~~~~~
arch/x86/kernel/jump_label.c: In function '__jump_label_transform':
arch/x86/kernel/jump_label.c:76:5: error: 'JUMP_LABEL_NOP_SIZE' undeclared (first use in this function); did you mean 'JUMP_LABEL_NOP'?
76 | JUMP_LABEL_NOP_SIZE);
| ^~~~~~~~~~~~~~~~~~~
| JUMP_LABEL_NOP
arch/x86/kernel/jump_label.c: In function 'arch_jump_label_transform_queue':
arch/x86/kernel/jump_label.c:114:12: error: 'JUMP_LABEL_NOP_SIZE' undeclared (first use in this function); did you mean 'JUMP_LABEL_NOP'?
114 | opcode, JUMP_LABEL_NOP_SIZE, NULL);
| ^~~~~~~~~~~~~~~~~~~
| JUMP_LABEL_NOP
vim +40 arch/x86/kernel/jump_label.c
86d276af0556e9e Peter Zijlstra 2019-06-28 23
18cbc8bed0c7079 Peter Zijlstra 2019-08-26 24 static const void *
b9acd3e858cf960 Peter Zijlstra 2021-03-10 25 __jump_label_set_jump_code(struct jump_entry *entry, enum jump_label_type type)
d9f5ab7b1c0a520 Jason Baron 2010-09-17 26 {
63f62addb88ec4b Peter Zijlstra 2019-10-03 27 const void *expect, *code;
63f62addb88ec4b Peter Zijlstra 2019-10-03 28 const void *addr, *dest;
9fc0f798ab8a6c0 Ard Biesheuvel 2018-09-18 29
63f62addb88ec4b Peter Zijlstra 2019-10-03 30 addr = (void *)jump_entry_code(entry);
63f62addb88ec4b Peter Zijlstra 2019-10-03 31 dest = (void *)jump_entry_target(entry);
18cbc8bed0c7079 Peter Zijlstra 2019-08-26 32
63f62addb88ec4b Peter Zijlstra 2019-10-03 33 code = text_gen_insn(JMP32_INSN_OPCODE, addr, dest);
d9f5ab7b1c0a520 Jason Baron 2010-09-17 34
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 35 if (type == JUMP_LABEL_JMP)
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 36 expect = x86_nops[5];
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 37 else
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 38 expect = code;
e71a5be15e47a73 Jeremy Fitzhardinge 2011-09-29 39
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 @40 if (memcmp(addr, expect, JUMP_LABEL_NOP_SIZE)) {
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 41 /*
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 42 * The location is not an op that we were expecting.
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 43 * Something went wrong. Crash the box, as something could be
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 44 * corrupting the kernel.
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 45 */
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 46 pr_crit("jump_label: Fatal kernel bug, unexpected op at %pS [%p] (%5ph != %5ph)) init:%d type:%d\n",
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 47 addr, addr, addr, expect, init, type);
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 48 BUG();
ea9a8a73e58ed8b Peter Zijlstra 2019-06-28 49 }
9fc0f798ab8a6c0 Ard Biesheuvel 2018-09-18 50
4cc6620b5e4c895 Daniel Bristot de Oliveira 2019-06-12 51 if (type == JUMP_LABEL_NOP)
b9acd3e858cf960 Peter Zijlstra 2021-03-10 52 code = x86_nops[5];
18cbc8bed0c7079 Peter Zijlstra 2019-08-26 53
63f62addb88ec4b Peter Zijlstra 2019-10-03 54 return code;
4cc6620b5e4c895 Daniel Bristot de Oliveira 2019-06-12 55 }
4cc6620b5e4c895 Daniel Bristot de Oliveira 2019-06-12 56
:::::: The code at line 40 was first introduced by commit
:::::: ea9a8a73e58ed8b9a24d6c84c033c7064fe2a05c jump_label, x86: Improve error when we fail expected text
:::::: TO: Peter Zijlstra <peterz@infradead.org>
:::::: CC: Peter Zijlstra <peterz@infradead.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org
[-- Attachment #2: config.gz --]
[-- Type: application/gzip, Size: 41159 bytes --]
next reply other threads:[~2021-03-13 5:37 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-13 5:37 kernel test robot [this message]
-- strict thread matches above, loose matches on Subject: below --
2021-03-11 1:31 [peterz-queue:x86/fpu 6/9] arch/x86/kernel/jump_label.c:40:27: error: 'JUMP_LABEL_NOP_SIZE' undeclared; did you mean 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=202103131301.nt78RSvY-lkp@intel.com \
--to=lkp@intel.com \
--cc=kbuild-all@lists.01.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.