Re: [PATCH v2] net: tracepoint: fix print wrong sysctl_mem value

2020-09-10 Thread dust.li
On Tue, Sep 08, 2020 at 07:49:52PM -0700, David Miller wrote: >From: Dust Li >Date: Tue, 8 Sep 2020 10:09:39 +0800 > >> @@ -98,7 +98,7 @@ TRACE_EVENT(sock_exceed_buf_limit, >> >> TP_STRUCT__entry( >> __array(char, name, 32) >> -__field(long *, sysctl_mem) >> +

Re: [PATCH v2] net: tracepoint: fix print wrong sysctl_mem value

2020-09-08 Thread David Miller
From: Dust Li Date: Tue, 8 Sep 2020 10:09:39 +0800 > @@ -98,7 +98,7 @@ TRACE_EVENT(sock_exceed_buf_limit, > > TP_STRUCT__entry( > __array(char, name, 32) > - __field(long *, sysctl_mem) > + __array(long, sysctl_mem, 3) > __field(long, a

[PATCH v2] net: tracepoint: fix print wrong sysctl_mem value

2020-09-07 Thread Dust Li
sysctl_mem is an point, and tracepoint entry do not support been visited like an array. Use an __array(3) to store sysctl_mem instead. tracpoint output with and without this fix: - without fix: 28821.074 sock:sock_exceed_buf_limit:proto:UDP sysctl_mem=-1741233440,19,322156906942464 allocated