Re: [PATCH v2 2/8] powerpc/module: Only try to generate the ftrace_caller() stub once

From: kbuild test robot
Date: Mon Feb 29 2016 - 20:41:31 EST


Hi Michael,

[auto build test ERROR on powerpc/next]
[also build test ERROR on v4.5-rc6 next-20160229]
[if your patch is applied to the wrong git tree, please drop us a note to help improving the system]

url: https://github.com/0day-ci/linux/commits/Michael-Ellerman/powerpc-Create-a-helper-for-getting-the-kernel-toc-value/20160229-172956
base: https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git next
config: powerpc-ppc6xx_defconfig (attached as .config)
reproduce:
wget https://git.kernel.org/cgit/linux/kernel/git/wfg/lkp-tests.git/plain/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# save the attached .config to linux build tree
make.cross ARCH=powerpc

Note: the linux-review/Michael-Ellerman/powerpc-Create-a-helper-for-getting-the-kernel-toc-value/20160229-172956 HEAD e702926c6f287a419f15b6b8451041fc7bd967f1 builds fine.
It only hurts bisectibility.

All errors (new ones prefixed by >>):

arch/powerpc/kernel/module_32.c: In function 'module_finalize_ftrace':
>> arch/powerpc/kernel/module_32.c:306:7: error: passing argument 3 of 'do_plt_call' discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers]
sechdrs, module);
^
arch/powerpc/kernel/module_32.c:182:17: note: expected 'Elf32_Shdr * {aka struct elf32_shdr *}' but argument is of type 'const Elf32_Shdr * {aka const struct elf32_shdr *}'
static uint32_t do_plt_call(void *location,
^
>> arch/powerpc/kernel/module_32.c:307:7: error: 'mod' undeclared (first use in this function)
if (!mod->arch.tramp)
^
arch/powerpc/kernel/module_32.c:307:7: note: each undeclared identifier is reported only once for each function it appears in
cc1: all warnings being treated as errors

vim +306 arch/powerpc/kernel/module_32.c

19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 300
7cc45e64 arch/powerpc/kernel/module_32.c Steven Rostedt 2008-11-15 301 #ifdef CONFIG_DYNAMIC_FTRACE
19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 302 int module_finalize_ftrace(struct module *module, const Elf_Shdr *sechdrs)
19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 303 {
19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 304 module->arch.tramp = do_plt_call(module->core_layout.base,
7cc45e64 arch/powerpc/kernel/module_32.c Steven Rostedt 2008-11-15 305 (unsigned long)ftrace_caller,
7cc45e64 arch/powerpc/kernel/module_32.c Steven Rostedt 2008-11-15 @306 sechdrs, module);
19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 @307 if (!mod->arch.tramp)
19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 308 return -ENOENT;
19558b67 arch/powerpc/kernel/module_32.c Michael Ellerman 2016-02-29 309
^1da177e arch/ppc/kernel/module.c Linus Torvalds 2005-04-16 310 return 0;

:::::: The code at line 306 was first introduced by commit
:::::: 7cc45e64323c8a1042f56e6a8d1dc982f98d52a8 powerpc/ppc32: ftrace, dynamic ftrace to handle modules

:::::: TO: Steven Rostedt <srostedt@xxxxxxxxxx>
:::::: CC: Steven Rostedt <srostedt@xxxxxxxxxx>

---
0-DAY kernel test infrastructure Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all Intel Corporation

Attachment: .config.gz
Description: Binary data