Re: [PATCH 1/4] drm/i915: Add pipe crc tracepoint

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Ville,

Thank you for the patch! Yet something to improve:

[auto build test ERROR on drm-intel/for-linux-next]
[also build test ERROR on next-20190206]
[cannot apply to v5.0-rc4]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Ville-Syrjala/drm-i915-Add-pipe-crc-tracepoint/20190207-123120
base:   git://anongit.freedesktop.org/drm-intel for-linux-next
config: i386-randconfig-x009-201905 (attached as .config)
compiler: gcc-8 (Debian 8.2.0-14) 8.2.0
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All errors (new ones prefixed by >>):

   In file included from include/trace/define_trace.h:98,
                    from drivers/gpu/drm/i915/i915_trace.h:951,
                    from drivers/gpu/drm/i915/i915_trace_points.c:13:
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h: In function '__bpf_trace_intel_pipe_crc':
>> include/trace/bpf_probe.h:39:17: error: 'sizeof' on array function parameter 'crcs' will return size of 'const u32 *' {aka 'const unsigned int *'} [-Werror=sizeof-array-argument]
     UINTTYPE(sizeof(x)) __dst; \
                    ^
   include/trace/bpf_probe.h:32:35: note: in definition of macro 'UINTTYPE'
     __typeof__(__builtin_choose_expr(size == 1,  (u8)1, \
                                      ^~~~
   include/trace/bpf_probe.h:43:24: note: in expansion of macro '__CAST_TO_U64'
    #define __CAST1(a,...) __CAST_TO_U64(a)
                           ^~~~~~~~~~~~~
   include/trace/bpf_probe.h:44:42: note: in expansion of macro '__CAST1'
    #define __CAST2(a,...) __CAST_TO_U64(a), __CAST1(__VA_ARGS__)
                                             ^~~~~~~
   include/linux/kernel.h:986:24: note: in expansion of macro '__CAST2'
    #define __CONCAT(a, b) a ## b
                           ^
   include/linux/kernel.h:987:27: note: in expansion of macro '__CONCAT'
    #define CONCATENATE(a, b) __CONCAT(a, b)
                              ^~~~~~~~
   include/trace/bpf_probe.h:56:26: note: in expansion of macro 'CONCATENATE'
    #define CAST_TO_U64(...) CONCATENATE(__CAST, COUNT_ARGS(__VA_ARGS__))(__VA_ARGS__)
                             ^~~~~~~~~~~
   include/trace/bpf_probe.h:64:53: note: in expansion of macro 'CAST_TO_U64'
     CONCATENATE(bpf_trace_run, COUNT_ARGS(args))(prog, CAST_TO_U64(args)); \
                                                        ^~~~~~~~~~~
   include/trace/trace_events.h:74:2: note: in expansion of macro 'DECLARE_EVENT_CLASS'
     DECLARE_EVENT_CLASS(name,          \
     ^~~~~~~~~~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:50: note: declared here
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
                                           ~~~~~~~~~~^~~~~~~
   include/trace/bpf_probe.h:61:34: note: in definition of macro 'DECLARE_EVENT_CLASS'
    __bpf_trace_##call(void *__data, proto)     \
                                     ^~~~~
   include/trace/trace_events.h:75:9: note: in expansion of macro 'PARAMS'
            PARAMS(proto),         \
            ^~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:6: note: in expansion of macro 'TP_PROTO'
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
         ^~~~~~~~
>> include/trace/bpf_probe.h:39:17: error: 'sizeof' on array function parameter 'crcs' will return size of 'const u32 *' {aka 'const unsigned int *'} [-Werror=sizeof-array-argument]
     UINTTYPE(sizeof(x)) __dst; \
                    ^
   include/trace/bpf_probe.h:33:28: note: in definition of macro 'UINTTYPE'
         __builtin_choose_expr(size == 2, (u16)2, \
                               ^~~~
   include/trace/bpf_probe.h:43:24: note: in expansion of macro '__CAST_TO_U64'
    #define __CAST1(a,...) __CAST_TO_U64(a)
                           ^~~~~~~~~~~~~
   include/trace/bpf_probe.h:44:42: note: in expansion of macro '__CAST1'
    #define __CAST2(a,...) __CAST_TO_U64(a), __CAST1(__VA_ARGS__)
                                             ^~~~~~~
   include/linux/kernel.h:986:24: note: in expansion of macro '__CAST2'
    #define __CONCAT(a, b) a ## b
                           ^
   include/linux/kernel.h:987:27: note: in expansion of macro '__CONCAT'
    #define CONCATENATE(a, b) __CONCAT(a, b)
                              ^~~~~~~~
   include/trace/bpf_probe.h:56:26: note: in expansion of macro 'CONCATENATE'
    #define CAST_TO_U64(...) CONCATENATE(__CAST, COUNT_ARGS(__VA_ARGS__))(__VA_ARGS__)
                             ^~~~~~~~~~~
   include/trace/bpf_probe.h:64:53: note: in expansion of macro 'CAST_TO_U64'
     CONCATENATE(bpf_trace_run, COUNT_ARGS(args))(prog, CAST_TO_U64(args)); \
                                                        ^~~~~~~~~~~
   include/trace/trace_events.h:74:2: note: in expansion of macro 'DECLARE_EVENT_CLASS'
     DECLARE_EVENT_CLASS(name,          \
     ^~~~~~~~~~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:50: note: declared here
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
                                           ~~~~~~~~~~^~~~~~~
   include/trace/bpf_probe.h:61:34: note: in definition of macro 'DECLARE_EVENT_CLASS'
    __bpf_trace_##call(void *__data, proto)     \
                                     ^~~~~
   include/trace/trace_events.h:75:9: note: in expansion of macro 'PARAMS'
            PARAMS(proto),         \
            ^~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:6: note: in expansion of macro 'TP_PROTO'
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
         ^~~~~~~~
>> include/trace/bpf_probe.h:39:17: error: 'sizeof' on array function parameter 'crcs' will return size of 'const u32 *' {aka 'const unsigned int *'} [-Werror=sizeof-array-argument]
     UINTTYPE(sizeof(x)) __dst; \
                    ^
   include/trace/bpf_probe.h:34:28: note: in definition of macro 'UINTTYPE'
         __builtin_choose_expr(size == 4, (u32)3, \
                               ^~~~
   include/trace/bpf_probe.h:43:24: note: in expansion of macro '__CAST_TO_U64'
    #define __CAST1(a,...) __CAST_TO_U64(a)
                           ^~~~~~~~~~~~~
   include/trace/bpf_probe.h:44:42: note: in expansion of macro '__CAST1'
    #define __CAST2(a,...) __CAST_TO_U64(a), __CAST1(__VA_ARGS__)
                                             ^~~~~~~
   include/linux/kernel.h:986:24: note: in expansion of macro '__CAST2'
    #define __CONCAT(a, b) a ## b
                           ^
   include/linux/kernel.h:987:27: note: in expansion of macro '__CONCAT'
    #define CONCATENATE(a, b) __CONCAT(a, b)
                              ^~~~~~~~
   include/trace/bpf_probe.h:56:26: note: in expansion of macro 'CONCATENATE'
    #define CAST_TO_U64(...) CONCATENATE(__CAST, COUNT_ARGS(__VA_ARGS__))(__VA_ARGS__)
                             ^~~~~~~~~~~
   include/trace/bpf_probe.h:64:53: note: in expansion of macro 'CAST_TO_U64'
     CONCATENATE(bpf_trace_run, COUNT_ARGS(args))(prog, CAST_TO_U64(args)); \
                                                        ^~~~~~~~~~~
   include/trace/trace_events.h:74:2: note: in expansion of macro 'DECLARE_EVENT_CLASS'
     DECLARE_EVENT_CLASS(name,          \
     ^~~~~~~~~~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:50: note: declared here
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
                                           ~~~~~~~~~~^~~~~~~
   include/trace/bpf_probe.h:61:34: note: in definition of macro 'DECLARE_EVENT_CLASS'
    __bpf_trace_##call(void *__data, proto)     \
                                     ^~~~~
   include/trace/trace_events.h:75:9: note: in expansion of macro 'PARAMS'
            PARAMS(proto),         \
            ^~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:6: note: in expansion of macro 'TP_PROTO'
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
         ^~~~~~~~
>> include/trace/bpf_probe.h:39:17: error: 'sizeof' on array function parameter 'crcs' will return size of 'const u32 *' {aka 'const unsigned int *'} [-Werror=sizeof-array-argument]
     UINTTYPE(sizeof(x)) __dst; \
                    ^
   include/trace/bpf_probe.h:35:28: note: in definition of macro 'UINTTYPE'
         __builtin_choose_expr(size == 8, (u64)4, \
                               ^~~~
   include/trace/bpf_probe.h:43:24: note: in expansion of macro '__CAST_TO_U64'
    #define __CAST1(a,...) __CAST_TO_U64(a)
                           ^~~~~~~~~~~~~
   include/trace/bpf_probe.h:44:42: note: in expansion of macro '__CAST1'
    #define __CAST2(a,...) __CAST_TO_U64(a), __CAST1(__VA_ARGS__)
                                             ^~~~~~~
   include/linux/kernel.h:986:24: note: in expansion of macro '__CAST2'
    #define __CONCAT(a, b) a ## b
                           ^
   include/linux/kernel.h:987:27: note: in expansion of macro '__CONCAT'
    #define CONCATENATE(a, b) __CONCAT(a, b)
                              ^~~~~~~~
   include/trace/bpf_probe.h:56:26: note: in expansion of macro 'CONCATENATE'
    #define CAST_TO_U64(...) CONCATENATE(__CAST, COUNT_ARGS(__VA_ARGS__))(__VA_ARGS__)
                             ^~~~~~~~~~~
   include/trace/bpf_probe.h:64:53: note: in expansion of macro 'CAST_TO_U64'
     CONCATENATE(bpf_trace_run, COUNT_ARGS(args))(prog, CAST_TO_U64(args)); \
                                                        ^~~~~~~~~~~
   include/trace/trace_events.h:74:2: note: in expansion of macro 'DECLARE_EVENT_CLASS'
     DECLARE_EVENT_CLASS(name,          \
     ^~~~~~~~~~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:50: note: declared here
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
                                           ~~~~~~~~~~^~~~~~~
   include/trace/bpf_probe.h:61:34: note: in definition of macro 'DECLARE_EVENT_CLASS'
    __bpf_trace_##call(void *__data, proto)     \
                                     ^~~~~
   include/trace/trace_events.h:75:9: note: in expansion of macro 'PARAMS'
            PARAMS(proto),         \
            ^~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:19:1: note: in expansion of macro 'TRACE_EVENT'
    TRACE_EVENT(intel_pipe_crc,
    ^~~~~~~~~~~
   include/trace/../../drivers/gpu/drm/i915/i915_trace.h:20:6: note: in expansion of macro 'TP_PROTO'
         TP_PROTO(struct intel_crtc *crtc, const u32 crcs[5]),
         ^~~~~~~~
   cc1: all warnings being treated as errors

vim +39 include/trace/bpf_probe.h

c4f6699d Alexei Starovoitov 2018-03-28  29  
c4f6699d Alexei Starovoitov 2018-03-28  30  /* cast any integer, pointer, or small struct to u64 */
c4f6699d Alexei Starovoitov 2018-03-28  31  #define UINTTYPE(size) \
c4f6699d Alexei Starovoitov 2018-03-28  32  	__typeof__(__builtin_choose_expr(size == 1,  (u8)1, \
c4f6699d Alexei Starovoitov 2018-03-28  33  		   __builtin_choose_expr(size == 2, (u16)2, \
c4f6699d Alexei Starovoitov 2018-03-28  34  		   __builtin_choose_expr(size == 4, (u32)3, \
c4f6699d Alexei Starovoitov 2018-03-28  35  		   __builtin_choose_expr(size == 8, (u64)4, \
c4f6699d Alexei Starovoitov 2018-03-28  36  					 (void)5)))))
c4f6699d Alexei Starovoitov 2018-03-28  37  #define __CAST_TO_U64(x) ({ \
c4f6699d Alexei Starovoitov 2018-03-28  38  	typeof(x) __src = (x); \
c4f6699d Alexei Starovoitov 2018-03-28 @39  	UINTTYPE(sizeof(x)) __dst; \
c4f6699d Alexei Starovoitov 2018-03-28  40  	memcpy(&__dst, &__src, sizeof(__dst)); \
c4f6699d Alexei Starovoitov 2018-03-28  41  	(u64)__dst; })
c4f6699d Alexei Starovoitov 2018-03-28  42  

:::::: The code at line 39 was first introduced by commit
:::::: c4f6699dfcb8558d138fe838f741b2c10f416cf9 bpf: introduce BPF_RAW_TRACEPOINT

:::::: TO: Alexei Starovoitov <ast@xxxxxxxxxx>
:::::: CC: Daniel Borkmann <daniel@xxxxxxxxxxxxx>

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

Attachment: .config.gz
Description: application/gzip

_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

[Index of Archives]     [AMD Graphics]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux