Re: [PATCH 1/8] perf: Allow to block process in syscall tracepoints

2018-12-08 Thread Steven Rostedt
On Sat, 8 Dec 2018 11:44:23 +0100 Peter Zijlstra wrote: > It's a tool I haven't used in years, given we have so many better tools > around these days. So because you don't use it, it's useless? As you don't care about lost events I can see why you may think there are better tools out there. But

Re: [PATCH 1/8] perf: Allow to block process in syscall tracepoints

2018-12-08 Thread Steven Rostedt
On Sat, 8 Dec 2018 11:41:21 +0100 Peter Zijlstra wrote: > > [root@seventh bpf]# trace -e augmented_raw_syscalls.c --filter-pids > > 2279,1643 > > > > 19766.027 ( 0.003 ms): gcc/27524 openat(dfd: CWD, filename: > > /lib64/libz.so.1, flags: CLOEXEC ) = 5 > > 19766.035 ( 0.001 ms):

Re: [PATCH 1/8] perf: Allow to block process in syscall tracepoints

2018-12-07 Thread Steven Rostedt
On Fri, 7 Dec 2018 16:11:05 +0100 Peter Zijlstra wrote: > On Fri, Dec 07, 2018 at 08:41:18AM -0500, Steven Rostedt wrote: > > On Fri, 7 Dec 2018 09:58:39 +0100 > > Peter Zijlstra wrote: > > > > > These patches give no justification *what*so*ever* for why we'r

Re: [PATCH 1/8] perf: Allow to block process in syscall tracepoints

2018-12-07 Thread Steven Rostedt
On Fri, 7 Dec 2018 09:58:39 +0100 Peter Zijlstra wrote: > These patches give no justification *what*so*ever* for why we're doing > ugly arse things like this. And why does this, whatever this is, need to > be done in perf? > > IOW, what problem are we solving ? I guess the cover letter should

Re: [PATCH] riscv: remove unused variable in ftrace

2018-12-06 Thread Steven Rostedt
ror messages when I did my cross-compiling of the architectures. I fixed this issue in other places, not sure how I missed riscv. Thanks for fixing it. Acked-by: Steven Rostedt (VMware) -- Steve > > [..] > > > > Signed-off-by: David Abdurachmanov > > Please add a: &g

Re: [GIT PULL] Uprobes: Fix kernel oops with delayed_uprobe_remove()

2018-12-06 Thread Steven Rostedt
SDT markers having reference > > count (semaphore)") > > Signed-off-by: Ravi Bangoria > > Signed-off-by: Steven Rostedt (VMware) > > > > No cc:stable? Fixes is still in this -rc release. -- Steve

Re: [PATCH 1/8] perf: Allow to block process in syscall tracepoints

2018-12-06 Thread Steven Rostedt
On Thu, 6 Dec 2018 09:34:00 +0100 Peter Zijlstra wrote: > > > > I don't understand this.. why are we using schedule_timeout() and all > > that? > > Urgh.. in fact, the more I look at this the more I hate it. > > We want to block in __perf_output_begin(), but we cannot because both >

Re: [PATCH] kernel/kcov.c: mark func write_comp_data() as notrace

2018-12-06 Thread Steven Rostedt
t; config KCOV_ENABLE_COMPARISONS > depends on $(cc-option,-fsanitize-coverage=trace-cmp) > > That code path isn't hit with gcc-7. However, it were that with gcc-8. > > Co-developed-by: Arnd Bergmann > Signed-off-by: Arnd Bergmann > Signed-off-by: Anders Roxell Acked-by: Steven Ro

[GIT PULL] Uprobes: Fix kernel oops with delayed_uprobe_remove()

2018-12-06 Thread Steven Rostedt
Reviewed-by: Srikar Dronamraju Reported-by: syzbot+cb1fb754b771caca0...@syzkaller.appspotmail.com Fixes: 1cc33161a83d ("uprobes: Support SDT markers having reference count (semaphore)") Signed-off-by: Ravi Bangoria Signed-off-by: Steven Rostedt (VMware) diff --git a/ker

Re: [PATCH 2/2] arm64: ftrace: Set FTRACE_SCHEDULABLE before ftrace_modify_all_code()

2018-12-06 Thread Steven Rostedt
On Thu, 6 Dec 2018 13:20:07 + Will Deacon wrote: > On Wed, Dec 05, 2018 at 12:48:54PM -0500, Steven Rostedt wrote: > > From: "Steven Rostedt (VMware)" > > > > It has been reported that ftrace_replace_code() which is called by > > ftrace_modify_all_c

Re: [for-next][PATCH 05/30] arm64: function_graph: Remove use of FTRACE_NOTRACE_DEPTH

2018-12-06 Thread Steven Rostedt
On Thu, 6 Dec 2018 15:49:32 + Will Deacon wrote: > On Wed, Dec 05, 2018 at 06:47:54PM -0500, Steven Rostedt wrote: > > From: "Steven Rostedt (VMware)" > > > > Functions in the set_graph_notrace no longer subtract FTRACE_NOTRACE_DEPTH > > from curr_ret_

Re: [for-next][PATCH 05/30] arm64: function_graph: Remove use of FTRACE_NOTRACE_DEPTH

2018-12-05 Thread Steven Rostedt
On Wed, 05 Dec 2018 18:47:54 -0500 Steven Rostedt wrote: > From: "Steven Rostedt (VMware)" > > Functions in the set_graph_notrace no longer subtract FTRACE_NOTRACE_DEPTH > from curr_ret_stack, as that is now implemented via the trace_recursion > flags. Access to curr_

Re: [PATCH 1/3] stackleak: mark stackleak_track_stack() as notrace

2018-12-05 Thread Steven Rostedt
On Wed, 5 Dec 2018 19:29:11 -0800 Kees Cook wrote: > On Wed, Dec 5, 2018 at 6:29 PM Steven Rostedt wrote: > > > > On Wed, 5 Dec 2018 21:26:51 -0500 > > Steven Rostedt wrote: > > > > > On Wed, 5 Dec 2018 17:08:34 -0800 > > > Kees Cook wro

Re: [PATCH 1/3] stackleak: mark stackleak_track_stack() as notrace

2018-12-05 Thread Steven Rostedt
On Wed, 5 Dec 2018 21:26:51 -0500 Steven Rostedt wrote: > On Wed, 5 Dec 2018 17:08:34 -0800 > Kees Cook wrote: > > I'll Ack the Makefile > change in the tracing directory, but the rest belongs to others. > I see I already acked that patch. BTW, when sending a patch serie

Re: [PATCH 1/3] stackleak: mark stackleak_track_stack() as notrace

2018-12-05 Thread Steven Rostedt
On Wed, 5 Dec 2018 17:08:34 -0800 Kees Cook wrote: > > diff --git a/kernel/stackleak.c b/kernel/stackleak.c > > index e42892926244..5de3bf596dd7 100644 > > --- a/kernel/stackleak.c > > +++ b/kernel/stackleak.c > > @@ -102,7 +102,7 @@ asmlinkage void stackleak_erase(void) > >

[for-next][PATCH 02/30] tracing: Do not line wrap short line in function_graph_enter()

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Commit 588ca1786f2dd ("function_graph: Use new curr_ret_depth to manage depth instead of curr_ret_stack") removed a parameter from the call ftrace_push_return_trace() that made it so that the entire call was under 80 characters, but it did

[for-next][PATCH 01/30] function_graph: Remove unused task_curr_ret_stack()

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The static inline function task_curr_ret_stack() is unused, remove it. Reviewed-by: Joel Fernandes (Google) Reviewed-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- include/linux/ftrace.h | 10 -- 1 file changed, 10 deletion

[for-next][PATCH 00/30] tracing: Updates for the next merge window

2018-12-05 Thread Steven Rostedt
events tracing: Remove unneeded synth_event_mutex tracing: Add generic event-name based remove event method selftests/ftrace: Add testcases for dynamic event Steven Rostedt (VMware) (17): function_graph: Remove unused task_curr_ret_stack() tracing: Do not line wrap

[for-next][PATCH 03/30] fgraph: Create a fgraph.c file to store function graph infrastructure

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" As the function graph infrastructure can be used by thing other than tracing, moving the code to its own file out of the trace_functions_graph.c code makes more sense. The fgraph.c file will only contain the infrastructure required to hook into

[for-next][PATCH 04/30] fgraph: Have set_graph_notrace only affect function_graph tracer

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" In order to make the function graph infrastructure more generic, there can not be code specific for the function_graph tracer in the generic code. This includes the set_graph_notrace logic, that stops all graph calls when a function in the set_graph_notr

[for-next][PATCH 11/30] fgraph: Add new fgraph_ops structure to enable function graph hooks

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Currently the registering of function graph is to pass in a entry and return function. We need to have a way to associate those functions together where the entry can determine to run the return hook. Having a structure that contains both functions will

[for-next][PATCH 12/30] function_graph: Move ftrace_graph_ret_addr() to fgraph.c

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Move the function function_graph_ret_addr() to fgraph.c, as the management of the curr_ret_stack is going to change, and all the accesses to ret_stack needs to be done in fgraph.c. Reviewed-by: Joel Fernandes (Google) Signed-off-by: Steven Roste

[for-next][PATCH 14/30] tracing: Have trace_stack nr_entries compare not be so subtle

2018-12-05 Thread Steven Rostedt
onal slightly more efficient. Link: http://lkml.kernel.org/r/20180620110758.crunhd5bfep7zuiz@kili.mountain Signed-off-by: Dan Carpenter Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_stack.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/trace/tr

[for-next][PATCH 17/30] tracing: Add tracefs file buffer_percentage

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Add a "buffer_percentage" file, that allows users to specify how much of the buffer (percentage of pages) need to be filled before waking up a task blocked on a per cpu trace_pipe_raw file. Signed-off-by: Steven Rostedt (VMware) --- kernel

[for-next][PATCH 07/30] ftrace: Create new ftrace_internal.h header

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" In order to move function graph infrastructure into its own file (fgraph.h) it needs to access various functions and variables in ftrace.c that are currently static. Create a new file called ftrace-internal.h that holds the function prototypes and

[for-next][PATCH 09/30] fgraph: Move function graph specific code into fgraph.c

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" To make the function graph infrastructure more managable, the code needs to be in its own file (fgraph.c). Move the code that is specific for managing the function graph infrastructure out of ftrace.c and into fgraph.c Reviewed-by: Joel Fernandes (Googl

[for-next][PATCH 06/30] function_graph: Remove the use of FTRACE_NOTRACE_DEPTH

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The curr_ret_stack is no longer set to a negative value when a function is not to be traced by the function graph tracer. Remove the usage of FTRACE_NOTRACE_DEPTH, as it is no longer needed. Reviewed-by: Joel Fernandes (Google) Signed-off-by: Stev

[for-next][PATCH 24/30] tracing/kprobes: Use dyn_event framework for kprobe events

2018-12-05 Thread Steven Rostedt
om Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- Documentation/trace/kprobetrace.rst | 3 + kernel/trace/Kconfig| 1 + kernel/trace/trace_kprobe.c | 319 +++- kernel/trace/tra

[for-next][PATCH 10/30] tracing: Rearrange functions in trace_sched_wakeup.c

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Rearrange the functions in trace_sched_wakeup.c so that there are fewer #ifdef CONFIG_FUNCTION_TRACER and #ifdef CONFIG_FUNCTION_GRAPH_TRACER, instead of having the #ifdefs spread all over. No functional change is made. Signed-off-by: Steven Roste

[for-next][PATCH 22/30] tracing: Integrate similar probe argument parsers

2018-12-05 Thread Steven Rostedt
Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_kprobe.c | 48 ++--- kernel/trace/trace_probe.c | 47 +--- kernel/trace/trace_probe.h | 7 ++ kernel/trace/trace_uprobe.c | 44 ++ 4

[for-next][PATCH 19/30] tracing/uprobes: Add busy check when cleanup all uprobes

2018-12-05 Thread Steven Rostedt
/154140841557.17322.12653952888762532401.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_uprobe.c | 7 +++ 1 file changed, 7 insertions(+) diff --git a/kernel/trace/trace_uprobe.c b/kernel/trace/trace_uprobe.c

[for-next][PATCH 15/30] scripts/recordmcount.{c,pl}: support -ffunction-sections .text.* section names

2018-12-05 Thread Steven Rostedt
nel.org/r/1542745158-25392-2-git-send-email-joe.lawre...@redhat.com Signed-off-by: Joe Lawrence Signed-off-by: Steven Rostedt (VMware) --- scripts/recordmcount.c | 2 +- scripts/recordmcount.pl | 13 + 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/scripts/reco

[for-next][PATCH 18/30] tracing: Change default buffer_percent to 50

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" After running several tests, it appears that having the reader wait till half the buffer is full before starting to read (and causing its own events to fill up the ring buffer constantly), works well. It keeps trace-cmd (the main user of this inter

[for-next][PATCH 29/30] tracing: Add generic event-name based remove event method

2018-12-05 Thread Steven Rostedt
nk: http://lkml.kernel.org/r/154140869774.17322.8887303560398645347.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_dynevent.c | 15 +++ 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/ke

[for-next][PATCH 16/30] ring-buffer: Add percentage of ring buffer full to wake up reader

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Instead of just waiting for a page to be full before waking up a pending reader, allow the reader to pass in a "percentage" of pages that have content before waking up a reader. This should help keep the process of reading the event

[for-next][PATCH 08/30] function_graph: Do not expose the graph_time option when profiler is not configured

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" When the function profiler is not configured, the "graph_time" option is meaningless, as the function profiler is the only thing that makes use of it. Do not expose it if the profiler is not configured. Link: http://lkml.kernel.org/r/

[for-next][PATCH 27/30] tracing: Remove unneeded synth_event_mutex

2018-12-05 Thread Steven Rostedt
there is no resource conflict. For safety, I added lockdep_assert_held(_mutex) for each function. Link: http://lkml.kernel.org/r/154140864134.17322.4796059721306031894.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware

[for-next][PATCH 13/30] function_graph: Have profiler use new helper ftrace_graph_get_ret_stack()

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The ret_stack processing is going to change, and that is going to break anything that is accessing the ret_stack directly. One user is the function graph profiler. By using the ftrace_graph_get_ret_stack() helper function, the profiler can access the

[for-next][PATCH 26/30] tracing: Use dyn_event framework for synthetic events

2018-12-05 Thread Steven Rostedt
Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/Kconfig | 1 + kernel/trace/trace.c | 8 + kernel/trace/trace_events_hist.c | 265 +++ 3 files changed, 176 insertions(+), 98 deletions(-) diff

[for-next][PATCH 21/30] tracing: Simplify creation and deletion of synthetic events

2018-12-05 Thread Steven Rostedt
the error code. It succeeds only if it has no error. Link: http://lkml.kernel.org/r/154140847194.17322.17960275728005067803.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_events_hist.c

[for-next][PATCH 20/30] tracing: Lock event_mutex before synth_event_mutex

2018-12-05 Thread Steven Rostedt
before synth_event_mutex to solve the lock dependency issue simpler. Link: http://lkml.kernel.org/r/154140844377.17322.13781091165954002713.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- include

[for-next][PATCH 30/30] selftests/ftrace: Add testcases for dynamic event

2018-12-05 Thread Steven Rostedt
ink: http://lkml.kernel.org/r/154140872590.17322.10394440849261743052.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- .../test.d/dynevent/add_remove_kprobe.tc | 30 +++ .../test.d/dynevent/add_remov

[for-next][PATCH 23/30] tracing: Add unified dynamic event framework

2018-12-05 Thread Steven Rostedt
: http://lkml.kernel.org/r/154140852824.17322.12250362185969352095.stgit@devbox Reviewed-by: Tom Zanussi Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/Kconfig | 3 + kernel/trace/Makefile | 1 + kernel/trace

[for-next][PATCH 25/30] tracing/uprobes: Use dyn_event framework for uprobe events

2018-12-05 Thread Steven Rostedt
si Tested-by: Tom Zanussi Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- Documentation/trace/uprobetracer.rst | 4 + kernel/trace/Kconfig | 1 + kernel/trace/trace_uprobe.c | 278 ++- 3 files changed, 153 insertio

[for-next][PATCH 28/30] tracing: Consolidate trace_add/remove_event_call back to the nolock functions

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The trace_add/remove_event_call_nolock() functions were added to allow the tace_add/remove_event_call() code be called when the event_mutex lock was already taken. Now that all callers are done within the event_mutex, there's no reason to have two

[for-next][PATCH 05/30] arm64: function_graph: Remove use of FTRACE_NOTRACE_DEPTH

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Functions in the set_graph_notrace no longer subtract FTRACE_NOTRACE_DEPTH from curr_ret_stack, as that is now implemented via the trace_recursion flags. Access to curr_ret_stack no longer needs to worry about checking for this. curr_ret_stack is still i

[PATCH 03/14 v2] arm64: function_graph: Remove use of FTRACE_NOTRACE_DEPTH

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Functions in the set_graph_notrace no longer subtract FTRACE_NOTRACE_DEPTH from curr_ret_stack, as that is now implemented via the trace_recursion flags. Access to curr_ret_stack no longer needs to worry about checking for this. curr_ret_stack is still i

[PATCH 0/2] tracing: arm64: Make ftrace_replace_code() schedulable for arm64

2018-12-05 Thread Steven Rostedt
This is a little more involved, and I would like to push this through my tree. Can I get a reviewed-by/ack for the second (arm64) patch? Anders, can you also test this to make sure that it fixes the issue you see? Thanks! -- Steve Steven Rostedt (VMware) (2): ftrace: Allow

[PATCH 2/2] arm64: ftrace: Set FTRACE_SCHEDULABLE before ftrace_modify_all_code()

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" It has been reported that ftrace_replace_code() which is called by ftrace_modify_all_code() can cause a soft lockup warning for an allmodconfig kernel. This is because all the debug options enabled causes the loop in ftrace_replace_code() (which loop

[PATCH 1/2] ftrace: Allow ftrace_replace_code() to be schedulable

2018-12-05 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The function ftrace_replace_code() is the ftrace engine that does the work to modify all the nops into the calls to the function callback in all the functions being traced. The generic version which is normally called from stop machine, but an archit

Re: [PATCH 1/8] perf: Allow to block process in syscall tracepoints

2018-12-05 Thread Steven Rostedt
On Wed, 5 Dec 2018 17:05:02 +0100 Jiri Olsa wrote: > diff --git a/arch/x86/entry/common.c b/arch/x86/entry/common.c > index 3b2490b81918..e55cf9169a03 100644 > --- a/arch/x86/entry/common.c > +++ b/arch/x86/entry/common.c > @@ -60,6 +60,32 @@ static void do_audit_syscall_entry(struct pt_regs

Re: [PATCH 3/9] tools/lib/traceevent: Install trace-seq.h API header file

2018-12-05 Thread Steven Rostedt
On Wed, 5 Dec 2018 13:25:17 +0100 Jiri Olsa wrote: > On Tue, Dec 04, 2018 at 02:41:45PM -0500, Steven Rostedt wrote: > > On Tue, 4 Dec 2018 16:47:39 +0900 > > Namhyung Kim wrote: > > > > > > > > @@ -302,6 +302,7 @@ install_headers: > &

Re: [PATCH v2] tracing: add cond_resched to ftrace_replace_code()

2018-12-05 Thread Steven Rostedt
On Wed, 5 Dec 2018 11:43:12 +0100 Anders Roxell wrote: > > > + schedulable = !irqs_disabled() && !preempt_count(); > > > > Is there a reason not to use preemptible() here? > > As I understand it preemptible() is defined to 0 if > CONFIG_PREEMPT_COUNT is disabled. > Thats no good right ?

Re: [PATCH v2 0/4] Static calls

2018-12-04 Thread Steven Rostedt
Where did this end up BTW? I know that there's controversy about the CONFIG_HAVE_STATIC_CALL_OPTIMIZED option, but I don't think the CONFIG_HAVE_STATIC_CALL_UNOPTIMIZED version was controversial. From the v1 patch 0 description: There are three separate implementations, depending on what the

Re: [PATCH v3] tracing: add cond_resched to ftrace_replace_code()

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 20:40:44 +0100 Anders Roxell wrote: > When running in qemu on an kernel built with allmodconfig and debug > options (in particular kcov and ubsan) enabled, ftrace_replace_code > function call take minutes. The ftrace selftest calls > ftrace_replace_code to look >4 through

Re: [PATCH 3/9] tools/lib/traceevent: Install trace-seq.h API header file

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 16:47:39 +0900 Namhyung Kim wrote: > > @@ -302,6 +302,7 @@ install_headers: > > $(call QUIET_INSTALL, headers) \ > > $(call > > do_install,event-parse.h,$(prefix)/include/traceevent,644); \ > > $(call > >

Re: Strange hang with gcc 8 of kprobe multiple_kprobes test

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 09:15:06 +0100 Ingo Molnar wrote: > * Masami Hiramatsu wrote: > > > I remember I have fixed this, and actually WE did it :-D > > > > https://lkml.org/lkml/2018/8/23/1203 > > > > Ah, we hit a same bug... > > > > Ingo, could you pick the patch? Should I resend it? > >

Re: [PATCH] tracing: add cond_resched to ftrace_replace_code()

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 20:25:31 +0100 Anders Roxell wrote: > On Tue, 4 Dec 2018 at 20:21, Steven Rostedt wrote: > > > > On Tue, 4 Dec 2018 14:19:08 -0500 > > Steven Rostedt wrote: > > > > > > @@ -2435,6 +2438,13 @@ void __weak ftrace_replace_code(int enab

Re: [PATCH] tracing: add cond_resched to ftrace_replace_code()

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 14:19:08 -0500 Steven Rostedt wrote: > > @@ -2435,6 +2438,13 @@ void __weak ftrace_replace_code(int enable) > > /* Stop processing */ > > return; > > } > > + /* > > +

Re: [PATCH] tracing: add cond_resched to ftrace_replace_code()

2018-12-04 Thread Steven Rostedt
> occasionally. > > Rework so that we call cond_resched() if !irqs_disabled() && !preempt_count(). > > Suggested-by: Steven Rostedt (VMware) > Signed-off-by: Anders Roxell > --- > kernel/trace/ftrace.c | 10 ++ > 1 file changed, 10 insertions(+) >

Re: BUG: ftrace/perf dropping events at the begin of interrupt handlers

2018-12-04 Thread Steven Rostedt
On Thu, 22 Nov 2018 10:45:05 +0100 Daniel Bristot de Oliveira wrote: > While developing the automata [1], I've hit cases in which need resched > and/or sched wakeup events were being fired with preemption and/or > interrupts enabled. However, this is not possible because interrupts must > be

Re: [PATCH v2 10/12] tracing: Remove orphaned trace_add/remove_event_call functions

2018-12-04 Thread Steven Rostedt
r this patch. Honestly, I hate the "_nolock" name, and it makes no sense when 1) they still grab locks 2) there's no version without "_nolock" I added this patch in its place: -- Steve From: "Steven Rostedt (VMware)" Date: Tue, 4 Dec 2018 13:35:45 -0500 Subje

Re: [PATCH 3/3] arm64: ftrace: add cond_resched() to func ftrace_make_(call|nop)

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 19:07:16 +0100 Anders Roxell wrote: > > > > + schedulable = !irqs_disabled() & !preempt_count(); > > > > > > Looks suspiciously like a bitwise preemptible() to me! > > > > Ah, thanks. Yeah, that should have been &&. But what did you expect. > > I didn't even compile

Re: [PATCH v2 01/12] tracing/uprobes: Add busy check when cleanup all uprobes

2018-12-04 Thread Steven Rostedt
On Mon, 5 Nov 2018 18:00:15 +0900 Masami Hiramatsu wrote: > Add a busy check loop in cleanup_all_probes() before > trying to remove all events in uprobe_events as same as > kprobe_events does. > > Without this change, writing null to uprobe_events will > try to remove events but if one of them

Re: [PATCH 2/9] tools/lib/traceevent: Added support for pkg-config

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 16:32:35 +0900 Namhyung Kim wrote: > > +++ b/tools/lib/traceevent/libtraceevent.pc.template > > @@ -0,0 +1,10 @@ > > +prefix=INSTALL_PREFIX > > +libdir=${prefix}/lib64 > > Don't we care 32-bit systems anymore? :) No we don't ;-) But, I guess because some people still do,

Re: [PATCH 3/3] arm64: ftrace: add cond_resched() to func ftrace_make_(call|nop)

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 11:12:43 + Will Deacon wrote: > > diff --git a/kernel/trace/ftrace.c b/kernel/trace/ftrace.c > > index 8ef9fc226037..42e89397778b 100644 > > --- a/kernel/trace/ftrace.c > > +++ b/kernel/trace/ftrace.c > > @@ -2393,11 +2393,14 @@ void __weak ftrace_replace_code(int enable)

Re: [PATCH] tools: Fix diverse typos

2018-12-04 Thread Steven Rostedt
On Tue, 4 Dec 2018 10:41:22 -0300 Arnaldo Carvalho de Melo wrote: > Em Mon, Dec 03, 2018 at 11:22:00AM +0100, Ingo Molnar escreveu: > > Go over the tools/ files that are maintained in Arnaldo's tree and > > fix common typos: half of them were in comments, the other half > > in JSON files. > >

Re: [PATCH] Uprobes: Fix kernel oops with delayed_uprobe_remove()

2018-12-03 Thread Steven Rostedt
On Mon, 3 Dec 2018 11:52:41 +0530 Ravi Bangoria wrote: > Hi Steve, > > Please pull this patch. > Please send a v2 version of the patch with the updated change log. And should it have a Fixes and be tagged for stable? -- Steve > Thanks. > > On 11/15/18 6:13 PM, Oleg Nesterov wrote: > > On

Re: [PATCH 3/3] arm64: ftrace: add cond_resched() to func ftrace_make_(call|nop)

2018-12-03 Thread Steven Rostedt
On Mon, 3 Dec 2018 22:51:52 +0100 Arnd Bergmann wrote: > On Mon, Dec 3, 2018 at 8:22 PM Will Deacon wrote: > > > > Hi Anders, > > > > On Fri, Nov 30, 2018 at 04:09:56PM +0100, Anders Roxell wrote: > > > Both of those functions end up calling ftrace_modify_code(), which is > > > expensive

[PATCH 5/6] tools/lib/traceevent: Rename tep_is_file_bigendian() to tep_file_bigendian()

2018-11-30 Thread Steven Rostedt
From: Tzvetomir Stoyanov In order to make libtraceevent into a proper library, its API should be straightforward. After discussion with Steven Rostedt, we decided to rename a few APIs, to have more intuitive names. This patch renames tep_is_file_bigendian() to tep_file_bigendian(). Signed-off

[PATCH 1/6] tools/lib/traceevent: Initialize host_bigendian at tep_handle allocation

2018-11-30 Thread Steven Rostedt
-by: Steven Rostedt (VMware) --- tools/lib/traceevent/event-parse.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tools/lib/traceevent/event-parse.c b/tools/lib/traceevent/event-parse.c index 0923e331441e..5cd99bdb0517 100644 --- a/tools/lib/traceevent/event-parse.c +++ b

[PATCH 0/6] tools/lib/traceevent: Some more library updates

2018-11-30 Thread Steven Rostedt
Arnaldo and Jiri, Here's another set of patches to get us closer to having a legitimate standalone library for libtraceevent. There's still a lot of man pages to come, but I need to continue reviewing them. Please pull this tree (based on current tip/perf/core) or apply the patches.

[PATCH 4/6] tools/lib/traceevent: Changed return logic of tep_register_event_handler() API

2018-11-30 Thread Steven Rostedt
. To unify the return logic of tep_register_event_handler() with the other APIs, this patch introduces enum tep_reg_handler, which is used by this function as return value, to handle all possible successful return cases. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware

[PATCH 6/6] tools/lib/traceevent: Remove tep_data_event_from_type() API

2018-11-30 Thread Steven Rostedt
From: Tzvetomir Stoyanov In order to make libtraceevent into a proper library, its API should be straightforward. After discussion with Steven Rostedt, we decided to remove the tep_data_event_from_type() API and to replace it with tep_find_event(), as it does the same. Signed-off-by: Tzvetomir

[PATCH 2/6] tools/lib/traceevent: Rename struct cmdline to struct tep_cmdline

2018-11-30 Thread Steven Rostedt
r Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/event-parse-local.h | 4 +-- tools/lib/traceevent/event-parse.c | 36 tools/lib/traceevent/event-parse.h | 8 +++--- 3 files changed, 24 insertions(+), 24 deletions(-) diff --git a

[PATCH 3/6] tools/lib/traceevent: Changed return logic of trace_seq_printf() and trace_seq_vprintf() APIs

2018-11-30 Thread Steven Rostedt
() and trace_seq_vprintf() - to return the number of printed characters, as the other trace_seq_* related APIs. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/trace-seq.c | 17 - 1 file changed, 12 insertions(+), 5 deletions(-) diff

Re: [PATCH v2 4/4] x86/static_call: Add inline static call implementation for x86-64

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 12:59:36 -0800 Andy Lutomirski wrote: > For all I know, the SMI handler will explode and the computer will catch fire. That sounds like an AWESOME feature!!! -- Steve

Re: [PATCH RFC 00/15] Zero ****s, hugload of hugs <3

2018-11-30 Thread Steven Rostedt
[ Cleared out the Cc list to something more reasonable ] On Fri, 30 Nov 2018 20:45:57 + Abuse wrote: > On Friday, 30 November 2018 20:42:28 GMT David Miller wrote: > > From: Abuse > > Date: Fri, 30 Nov 2018 20:39:01 + > > > > > I assume I will now be barred. > > > > Perhaps, but

Re: [PATCH v2 4/4] x86/static_call: Add inline static call implementation for x86-64

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 12:18:33 -0800 Andy Lutomirski wrote: > Or we could replace that IPI with x86's bona fide serialize-all-cpus > primitive and then we can just retry instead of emulating. It's a > piece of cake -- we just trigger an SMI :) /me runs away. I must have fallen on my head one

Re: [PATCH 7/9] tools/lib/traceevent: traceevent API cleanup

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 16:18:56 -0300 Arnaldo Carvalho de Melo wrote: > Em Fri, Nov 30, 2018 at 10:44:10AM -0500, Steven Rostedt escreveu: > > From: Tzvetomir Stoyanov > > > > In order to make libtraceevent into a proper library, its API > > should be straightforwar

Re: [PATCH 7/9] tools/lib/traceevent: traceevent API cleanup

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 14:37:36 -0500 Steven Rostedt wrote: > What branch are you applying it against? Just to make sure I'm testing > the same thing you are. Nevermind, I just downloaded your repo. BTW, should I be basing these patches off of your repo or tip/perf/core? -- Steve

Re: [PATCH RFC 14/15] lib: replace **** with a hug

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 11:27:23 -0800 Jarkko Sakkinen wrote: > In order to comply with the CoC, replace with a hug. > > Signed-off-by: Jarkko Sakkinen > --- > lib/vsprintf.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/lib/vsprintf.c b/lib/vsprintf.c > index

Re: [PATCH 7/9] tools/lib/traceevent: traceevent API cleanup

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 16:18:56 -0300 Arnaldo Carvalho de Melo wrote: > Em Fri, Nov 30, 2018 at 10:44:10AM -0500, Steven Rostedt escreveu: > > From: Tzvetomir Stoyanov > > > > In order to make libtraceevent into a proper library, its API > > should be straightforwar

Re: [PATCH 0/2] [GIT PULL] tracing: More fixes for 4.20

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 10:56:06 -0800 Linus Torvalds wrote: > This way I got the matching diffstat from your pull requests, but more > importantly also the independent merge messages. > > The history looks slightly odd this way (with two adjacent merges of > continuous history), but I thought I'd

Re: [PATCH 0/2] [GIT PULL] tracing: More fixes for 4.20

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 09:41:00 -0800 Linus Torvalds wrote: > On Thu, Nov 29, 2018 at 7:19 PM Steven Rostedt wrote: > > > > Note, this is on top of a previous git pull that I have submitted: > > > > http://lkml.kernel.org/r/20181127224031.76681...@vmware.local.

Re: [RFC PATCH v3] ftrace: support very early function tracing

2018-11-30 Thread Steven Rostedt
On Wed, 24 Oct 2018 19:22:30 + Abderrahmane Benbachir wrote: > --- a/include/linux/ftrace.h > +++ b/include/linux/ftrace.h > @@ -239,6 +239,16 @@ static inline void ftrace_free_init_mem(void) { } > static inline void ftrace_free_mem(struct module *mod, void *start, > void *end) { } >

[PATCH 1/9] tools/lib/traceevent: Implemented new API tep_get_ref()

2018-11-30 Thread Steven Rostedt
by the library users, the API is used to get the reference counter. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/event-parse.c | 7 +++ tools/lib/traceevent/event-parse.h | 1 + 2 files changed, 8 insertions(+) diff --git a/tools/lib/traceev

[PATCH 5/9] tools/lib/traceevent: Rename tep_free_format() to tep_free_event()

2018-11-30 Thread Steven Rostedt
-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/event-parse.c | 6 +++--- tools/lib/traceevent/event-parse.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/tools/lib/traceevent/event-parse.c b/tools/lib/traceevent/event-parse.c

[PATCH 2/9] tools/lib/traceevent: Added support for pkg-config

2018-11-30 Thread Steven Rostedt
From: Tzvetomir Stoyanov This patch implements integration with pkg-config framework. pkg-config can be used by the library users to determine required CFLAGS and LDFLAGS in order to use the library Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib

[PATCH 0/9] tools/lib/traceevent: More udpates to make libtraceevent into a library

2018-11-30 Thread Steven Rostedt
Arnaldo and Jiri, Here's more patches to get us a step closer to having a legitimate standalone library for libtraceevent. I'm currently reviewing man pages, which I want finished before we call it done. Please pull this tree (based on current tip/perf/core) or apply the patches. Thanks! --

[PATCH 8/9] tools/lib/traceevent: Introduce new libtracevent API: tep_override_comm()

2018-11-30 Thread Steven Rostedt
From: Tzvetomir Stoyanov This patch adds a new API of tracevent library: tep_override_comm() It registers a pid / command mapping. If a mapping with the same pid already exists, the entry is updated with the new command. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware

[PATCH 6/9] tools/perf: traceevent API cleanup, remove __tep_data2host*()

2018-11-30 Thread Steven Rostedt
with tep_read_number() in perf. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/perf/util/trace-event-read.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tools/perf/util/trace-event-read.c b/tools/perf/util/trace-event-read.c index

[PATCH 7/9] tools/lib/traceevent: traceevent API cleanup

2018-11-30 Thread Steven Rostedt
(). The patch also alignes the libtraceevent summary man page with these API changes. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/event-parse-api.c | 6 +++--- tools/lib/traceevent/event-parse-local.h | 7 +++ tools/lib/traceevent/event-parse.c

[PATCH 9/9] tools/lib/traceevent: Add sanity check to is_timestamp_in_us()

2018-11-30 Thread Steven Rostedt
From: Tzvetomir Stoyanov This patch adds a sanity check to is_timestamp_in_us() input parameter trace_clock. It avoids a potential segfault in case trace_clock is NULL. Reported-by: Slavomir Kaslev Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib

[PATCH 4/9] tools/lib/traceevent, tools/perf: Rename struct tep_event_format to struct tep_event

2018-11-30 Thread Steven Rostedt
. Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/event-parse-api.c| 2 +- tools/lib/traceevent/event-parse-local.h | 6 +- tools/lib/traceevent/event-parse.c| 188 +- tools/lib/traceevent/event-parse.h

[PATCH 3/9] tools/lib/traceevent: Install trace-seq.h API header file

2018-11-30 Thread Steven Rostedt
From: Tzvetomir Stoyanov This patch installs trace-seq.h header file on "make install". Signed-off-by: Tzvetomir Stoyanov Signed-off-by: Steven Rostedt (VMware) --- tools/lib/traceevent/Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tools/lib/

Re: [PATCH 3/3] arm64: ftrace: add cond_resched() to func ftrace_make_(call|nop)

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 16:09:56 +0100 Anders Roxell wrote: > Both of those functions end up calling ftrace_modify_code(), which is > expensive because it changes the page tables and flush caches. > Microseconds add up because this is called in a loop for each dyn_ftrace > record, and this triggers

Re: [PATCH 2/3] tracing: instruct KCOV not to track tracing files

2018-11-30 Thread Steven Rostedt
a bit overkill, as there's functions in this directory that can (and probably should) be. Acked-by: Steven Rostedt (VMware) -- Steve > ifdef CONFIG_FTRACE_SELFTEST > # selftest needs instrumentation > CFLAGS_trace_selftest_dynamic.o = $(CC_FLAGS_FTRACE)

Re: [PATCH 1/3] stackleak: mark stackleak_track_stack() as notrace

2018-11-30 Thread Steven Rostedt
/irq/irqdesc.c:650 > \#9 0xff80081d52b4 in ftrace_graph_caller () at > ../arch/arm64/kernel/entry-ftrace.S:205 > > Rework so we mark stackleak_track_stack as notrace > > Co-developed-by: Arnd Bergmann > Signed-off-by: Arnd Bergmann > Signed-off-by: Anders Ro

Re: [PATCH v2] kernel/trace: fix watchdog soft lockup

2018-11-30 Thread Steven Rostedt
On Fri, 30 Nov 2018 15:56:22 +0100 Anders Roxell wrote: > When building a allmodconfig kernel for arm64 and boot that in qemu, > CONFIG_FTRACE_STARTUP_TEST gets enabled and that takes time so the > watchdog expires and prints out a message like this: > 'watchdog: BUG: soft lockup - CPU#0 stuck

  1   2   3   4   5   6   7   8   9   10   >