tree:   https://git.kernel.org/pub/scm/linux/kernel/git/powerpc/linux.git test
head:   675b1ff3778df243879ed2c58dfa80aeb1f9bf03
commit: ad581fb0a5d8a5a505a85e03a87ef14b8defa072 [26/49] powerpc/kprobes: 
Implement Optprobes
config: powerpc-maple_defconfig (attached as .config)
compiler: powerpc64-linux-gnu-gcc (Debian 6.1.1-9) 6.1.1 20160705
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
        git checkout ad581fb0a5d8a5a505a85e03a87ef14b8defa072
        # save the attached .config to linux build tree
        make.cross ARCH=powerpc 

All errors (new ones prefixed by >>):

   In file included from include/linux/kprobes.h:45:0,
                    from arch/powerpc/kernel/optprobes.c:12:
   arch/powerpc/kernel/optprobes.c: In function 'arch_prepare_optimized_kprobe':
   arch/powerpc/include/asm/kprobes.h:79:16: error: 'MODULE_NAME_LEN' 
undeclared (first use in this function)
     char dot_name[MODULE_NAME_LEN + 1 + KSYM_NAME_LEN];  \
                   ^
   arch/powerpc/kernel/optprobes.c:230:2: note: in expansion of macro 
'kprobe_lookup_name'
     kprobe_lookup_name("optimized_callback", op_callback_addr);
     ^~~~~~~~~~~~~~~~~~
   arch/powerpc/include/asm/kprobes.h:79:16: note: each undeclared identifier 
is reported only once for each function it appears in
     char dot_name[MODULE_NAME_LEN + 1 + KSYM_NAME_LEN];  \
                   ^
   arch/powerpc/kernel/optprobes.c:230:2: note: in expansion of macro 
'kprobe_lookup_name'
     kprobe_lookup_name("optimized_callback", op_callback_addr);
     ^~~~~~~~~~~~~~~~~~
>> arch/powerpc/include/asm/kprobes.h:82:14: error: assignment discards 'const' 
>> qualifier from pointer target type [-Werror=discarded-qualifiers]
     if ((modsym = strchr(name, ':')) != NULL) {   \
                 ^
   arch/powerpc/kernel/optprobes.c:230:2: note: in expansion of macro 
'kprobe_lookup_name'
     kprobe_lookup_name("optimized_callback", op_callback_addr);
     ^~~~~~~~~~~~~~~~~~
>> arch/powerpc/include/asm/kprobes.h:79:7: error: unused variable 'dot_name' 
>> [-Werror=unused-variable]
     char dot_name[MODULE_NAME_LEN + 1 + KSYM_NAME_LEN];  \
          ^
   arch/powerpc/kernel/optprobes.c:230:2: note: in expansion of macro 
'kprobe_lookup_name'
     kprobe_lookup_name("optimized_callback", op_callback_addr);
     ^~~~~~~~~~~~~~~~~~
>> arch/powerpc/include/asm/kprobes.h:82:14: error: assignment discards 'const' 
>> qualifier from pointer target type [-Werror=discarded-qualifiers]
     if ((modsym = strchr(name, ':')) != NULL) {   \
                 ^
   arch/powerpc/kernel/optprobes.c:231:2: note: in expansion of macro 
'kprobe_lookup_name'
     kprobe_lookup_name("emulate_step", emulate_step_addr);
     ^~~~~~~~~~~~~~~~~~
>> arch/powerpc/include/asm/kprobes.h:79:7: error: unused variable 'dot_name' 
>> [-Werror=unused-variable]
     char dot_name[MODULE_NAME_LEN + 1 + KSYM_NAME_LEN];  \
          ^
   arch/powerpc/kernel/optprobes.c:231:2: note: in expansion of macro 
'kprobe_lookup_name'
     kprobe_lookup_name("emulate_step", emulate_step_addr);
     ^~~~~~~~~~~~~~~~~~
   cc1: all warnings being treated as errors

vim +/const +82 arch/powerpc/include/asm/kprobes.h

bf794bf5 Naveen N. Rao 2014-12-15  73   *
bf794bf5 Naveen N. Rao 2014-12-15  74   * This ensures we always get to the 
actual symbol and not the descriptor.
bf794bf5 Naveen N. Rao 2014-12-15  75   * Also handle <module:symbol> format.
bf794bf5 Naveen N. Rao 2014-12-15  76   */
bf794bf5 Naveen N. Rao 2014-12-15  77  #define kprobe_lookup_name(name, addr)   
                                \
bf794bf5 Naveen N. Rao 2014-12-15  78  {                                        
                                \
bf794bf5 Naveen N. Rao 2014-12-15 @79   char dot_name[MODULE_NAME_LEN + 1 + 
KSYM_NAME_LEN];             \
bf794bf5 Naveen N. Rao 2014-12-15  80   char *modsym;                           
                        \
bf794bf5 Naveen N. Rao 2014-12-15  81   bool dot_appended = false;              
                        \
bf794bf5 Naveen N. Rao 2014-12-15 @82   if ((modsym = strchr(name, ':')) != 
NULL) {                     \
bf794bf5 Naveen N. Rao 2014-12-15  83           modsym++;                       
                        \
bf794bf5 Naveen N. Rao 2014-12-15  84           if (*modsym != '\0' && *modsym 
!= '.') {                \
bf794bf5 Naveen N. Rao 2014-12-15  85                   /* Convert to 
<module:.symbol> */               \

:::::: The code at line 82 was first introduced by commit
:::::: bf794bf52a80c6278a028f0af2ca32d7c3508c9b powerpc/kprobes: Fix kallsyms 
lookup across powerpc ABIv1 and ABIv2

:::::: TO: Naveen N. Rao <naveen.n....@linux.vnet.ibm.com>
:::::: CC: Michael Ellerman <m...@ellerman.id.au>

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

Attachment: .config.gz
Description: application/gzip

Reply via email to