Hi Daniel,

[auto build test WARNING on tip/perf/core]
[also build test WARNING on v4.8-rc5 next-20160907]
[if your patch is applied to the wrong git tree, please drop us a note to help 
improve the system]
[Suggest to use git(>=2.9.0) format-patch --base=<commit> (or --base=auto for 
convenience) to record what (public, well-known) commit your patch series was 
built on]
[Check https://git-scm.com/docs/git-format-patch for more information]

url:    
https://github.com/0day-ci/linux/commits/Binoy-Jayan/tracing-Deference-pointers-without-RCU-checks/20160907-205003
config: i386-randconfig-x003-201636 (attached as .config)
compiler: gcc-6 (Debian 6.1.1-9) 6.1.1 20160705
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All warnings (new ones prefixed by >>):

   kernel/trace/trace_events_hist.c: In function 'hist_field_comm':
>> kernel/trace/trace_events_hist.c:85:9: warning: cast from pointer to integer 
>> of different size [-Wpointer-to-int-cast]
     return (u64) current->comm;
            ^

vim +85 kernel/trace/trace_events_hist.c

    69  }
    70  
    71  static u64 hist_field_log2(struct hist_field *hist_field, void *event)
    72  {
    73          u64 val = *(u64 *)(event + hist_field->field->offset);
    74  
    75          return (u64) ilog2(roundup_pow_of_two(val));
    76  }
    77  
    78  static u64 hist_field_cpu(struct hist_field *hist_field, void *event)
    79  {
    80          return (u64) smp_processor_id();
    81  }
    82  
    83  static u64 hist_field_comm(struct hist_field *hist_field, void *event)
    84  {
  > 85          return (u64) current->comm;
    86  }
    87  
    88  #define DEFINE_HIST_FIELD_FN(type)                                      
\
    89  static u64 hist_field_##type(struct hist_field *hist_field, void 
*event)\
    90  {                                                                       
\
    91          type *addr = (type *)(event + hist_field->field->offset);       
\
    92                                                                          
\
    93          return (u64)(unsigned long)*addr;                               
\

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

Attachment: .config.gz
Description: Binary data

Reply via email to