tree:
https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git x86/static_call
head: 814cfbceba54e980b1f949a13d04b1909bbe80da
commit: b2f0c8b71eec8a5833ae2eeecccf741b36171869 [11/34] x86/ftrace: Use text_gen_insn()
config: x86_64-lkp (attached as .config)
compiler: gcc-7 (Debian 7.4.0-13) 7.4.0
reproduce:
git checkout b2f0c8b71eec8a5833ae2eeecccf741b36171869
# save the attached .config to linux build tree
make ARCH=x86_64
If you fix the issue, kindly add following tag
Reported-by: kbuild test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
In file included from arch/x86/include/asm/bug.h:83:0,
from include/linux/bug.h:5,
from include/linux/thread_info.h:12,
from arch/x86/include/asm/preempt.h:7,
from include/linux/preempt.h:78,
from include/linux/spinlock.h:51,
from arch/x86/kernel/ftrace.c:15:
arch/x86/kernel/ftrace.c: In function 'addr_from_call':
> arch/x86/kernel/ftrace.c:468:23: error: 'union
text_poke_insn' has no member named 'op'
if (WARN_ON_ONCE(call.op
!= CALL_INSN_OPCODE)) {
^
include/asm-generic/bug.h:96:25: note: in definition of macro 'WARN_ON_ONCE'
int __ret_warn_on = !!(condition); \
^~~~~~~~~
In file included from include/linux/kernel.h:15:0,
from include/linux/list.h:9,
from include/linux/preempt.h:11,
from include/linux/spinlock.h:51,
from arch/x86/kernel/ftrace.c:15:
arch/x86/kernel/ftrace.c:469:40: error: 'union text_poke_insn' has no member
named 'op'
pr_warn("Expected E8, got %x\n", call.op);
^
include/linux/printk.h:306:37: note: in definition of macro 'pr_warning'
printk(KERN_WARNING pr_fmt(fmt), ##__VA_ARGS__)
^~~~~~~~~~~
arch/x86/kernel/ftrace.c:469:3: note: in expansion of macro 'pr_warn'
pr_warn("Expected E8, got %x\n", call.op);
^~~~~~~
vim +468 arch/x86/kernel/ftrace.c
456
457 /* Return the address of the function the trampoline calls */
458 static void *addr_from_call(void *ptr)
459 {
460 union text_poke_insn call;
461 int ret;
462
463 ret = probe_kernel_read(&call, ptr, CALL_INSN_SIZE);
464 if (WARN_ON_ONCE(ret < 0))
465 return NULL;
466
467 /* Make sure this is a call */
468 if (WARN_ON_ONCE(call.op != CALL_INSN_OPCODE)) {
469 pr_warn("Expected E8, got %x\n", call.op);
470 return NULL;
471 }
472
473 return ptr + CALL_INSN_SIZE + call.disp;
474 }
475
---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation