[PATCH 0/3] tracing: Remove eventfs_files by use of callbacks

2023-09-12 Thread Steven Rostedt
...@goodmis.org/ - Rebased on mainline and some minor clean ups. - Fixed kprobe selftest Steven Rostedt (Google) (3): tracefs: Add show_events_dentries eventfs: Remove eventfs_file and just use eventfs_inode tracing/selftests: Update kprobe args char/string to match new functions fs

[PATCH 1/3] tracefs: Add show_events_dentries

2023-09-12 Thread Steven Rostedt
From: "Steven Rostedt (Google)" Add a file in tracefs that shows the "events" allocated entries and the dentries that are attached to them. This is used to see what dentries have been dynamically allocated as well as their current ref counts. ~# cat /sys/kernel/

Re: [PATCH v5] eventfs: Fix the NULL pointer dereference bug in eventfs_remove_rec()

2023-09-12 Thread Steven Rostedt
On Tue, 12 Sep 2023 21:47:52 +0800 Jinjie Ruan wrote: > v5: > - Move the ef below dir to keep the "upside-down x-mas tree" format. That was quick! I'll add it to my queue and start testing it. Thanks Ruan! -- Steve

Re: [PATCH v4] eventfs: Fix the NULL pointer dereference bug in eventfs_remove_rec()

2023-09-12 Thread Steven Rostedt
On Tue, 12 Sep 2023 10:58:08 +0800 Jinjie Ruan wrote: This looks good. But I have a small nit. > diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c > index ed367d713be0..8e0593d4c6a6 100644 > --- a/kernel/trace/trace_events.c > +++ b/kernel/trace/trace_events.c > @@ -2296,6

Re: [RESEND][PATCH] tracing/synthetic: Fix order of struct trace_dynamic_info

2023-09-11 Thread Steven Rostedt
On Mon, 11 Sep 2023 09:26:12 +0900 Masami Hiramatsu (Google) wrote: > > Fix this and just to be safe also add "__packed". > > > > Link: > > https://lore.kernel.org/all/20230908154417.5172e...@gandalf.local.home/ > > Good catch! I'm not sure why this worked. Maybe we don't have any testcase

Re: suspicious RCU usage warning on tracing/urgent

2023-09-11 Thread Steven Rostedt
On Mon, 11 Sep 2023 12:00:53 +0900 Masami Hiramatsu (Google) wrote: > But it seems correctly taking srcu_read_lock(). > > 452 > 453 ei = ti->private; > 454 idx = srcu_read_lock(_srcu); > 455 list_for_each_entry_rcu(ef, >e_top_files, list) { > 456

Re: [PATCH 1/2] mm/damon/core: add a tracepoint for damos apply target regions

2023-09-11 Thread Steven Rostedt
On Mon, 11 Sep 2023 20:36:42 + SeongJae Park wrote: > > Then tracing is fully enabled here, and now we enter: > > > > if (trace_damos_before_apply_enabled()) { > > trace_damos_before_apply(cidx, sidx, tidx, r, > > damon_nr_regions(t)); > > } >

Re: [PATCH 1/2] mm/damon/core: add a tracepoint for damos apply target regions

2023-09-11 Thread Steven Rostedt
On Tue, 12 Sep 2023 01:43:08 + SeongJae Park wrote: > Nevertheless, since the variable is unsigned int, I would need to use UINT_MAX > instead. To make the code easier to understand, I'd prefer to add a third > parameter, as you suggested as another option at the original reply, like >

Re: [PATCH v3] eventfs: Fix the NULL pointer dereference bug in eventfs_remove_rec()

2023-09-11 Thread Steven Rostedt
On Mon, 11 Sep 2023 20:51:25 +0900 Masami Hiramatsu (Google) wrote: > Instead, > > ef = eventfs_add_subsystem_dir(name, parent); > if (IS_ERR(ef)) { > ... > } else > dir->ef = ef; Note, as the error has a goto out_free, it just needs to be:

[PATCH] tracefs/eventfs: Use list_for_each_srcu() in dcache_dir_open_wrapper()

2023-09-11 Thread Steven Rostedt
From: "Steven Rostedt (Google)" The eventfs files list is protected by SRCU. In earlier iterations it was protected with just RCU, but because it needed to also call sleepable code, it had to be switch to SRCU. The dcache_dir_open_wrapper() list_for_each_rcu() was missed and d

[PATCH] tracefs/eventfs: Use list_for_each_srcu() in dcache_dir_open_wrapper()

2023-09-11 Thread Steven Rostedt
From: "Steven Rostedt (Google)" The eventfs files list is protected by SRCU. In earlier iterations it was protected with just RCU, but because it needed to also call sleepable code, it had to be switch to SRCU. The dcache_dir_open_wrapper() list_for_each_rcu() was missed and d

Re: [PATCH 1/2] mm/damon/core: add a tracepoint for damos apply target regions

2023-09-11 Thread Steven Rostedt
On Mon, 11 Sep 2023 04:59:07 + SeongJae Park wrote: > --- a/mm/damon/core.c > +++ b/mm/damon/core.c > @@ -950,6 +950,28 @@ static void damos_apply_scheme(struct damon_ctx *c, > struct damon_target *t, > struct timespec64 begin, end; > unsigned long sz_applied = 0; > int

Re: [PATCH 1/2] mm/damon/core: add a tracepoint for damos apply target regions

2023-09-11 Thread Steven Rostedt
On Mon, 11 Sep 2023 19:05:04 + SeongJae Park wrote: > > Also, this if statement is only done when the trace event is enabled, so > > it's equivalent to: > > > > if (trace_damos_before_apply_enabled()) { > > if (sdx >= 0) > > trace_damos_before_apply(cidx,

Re: [FIX PATCH] selftests: tracing: Fix to unmount tracefs for recovering environment

2023-09-11 Thread Steven Rostedt
On Sat, 9 Sep 2023 18:36:39 +0900 "Masami Hiramatsu (Google)" wrote: > From: Masami Hiramatsu (Google) > > Fix to unmount the tracefs if the ftracetest mounted it for recovering > system environment. If the tracefs is already mounted, this does nothing. > > Suggested-by: Mark Brown > Link:

Re: [tracing] 9c0dee54eb: WARNING:at_kernel/tracepoint.c:#tracepoint_probe_register_prio

2021-04-20 Thread Steven Rostedt
Added the Perf folks as this is a perf event probe. From the call trace: [ 59.695946] [ cut here ] [ 59.696788] WARNING: CPU: 0 PID: 1199 at kernel/tracepoint.c:143 tracepoint_probe_register_prio+0x2f0/0x360 [ 59.698385] Modules linked in: rapl input_leds

Re: [PATCH][RFC] tracing: Enable tracepoints via module parameters

2021-04-20 Thread Steven Rostedt
On Tue, 20 Apr 2021 12:54:39 -0700 Dan Williams wrote: > On Tue, Apr 20, 2021 at 5:55 AM Steven Rostedt wrote: > > > > > > The dev_dbg() filter language is attractive, it's too bad > > > > Not sure what you mean by that. What filter language. Tracepoints do

[GIT PULL] tracing: Fix checking event hash pointer logic when tp_printk is enabled

2021-04-20 Thread Steven Rostedt
: 39ed1af76146f9f995c224de1987f14babc9aa28 Head SHA1: 0e1e71d34901a633825cd5ae78efaf8abd9215c6 Steven Rostedt (VMware) (1): tracing: Fix checking event hash pointer logic when tp_printk is enabled kernel/trace/trace.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions

Re: [PATCH][RFC] tracing: Enable tracepoints via module parameters

2021-04-20 Thread Steven Rostedt
On Tue, 20 Apr 2021 11:15:10 -0400 (EDT) Mathieu Desnoyers wrote: > That sounds fine. So that would be within the "trace_event" (and not > tracepoint) > namespace for module load parameters as well ? Right, it would be "trace_event=" not "tracepoint=..." -- Steve

Re: [PATCH][RFC] tracing: Enable tracepoints via module parameters

2021-04-20 Thread Steven Rostedt
On Tue, 20 Apr 2021 09:29:27 -0400 (EDT) Mathieu Desnoyers wrote: > - On Apr 20, 2021, at 8:55 AM, rostedt rost...@goodmis.org wrote: > [...] > > > > Would adding automatic module parameters be an issue? That is, you can add > > in the insmod command line a parameter that will enable

Re: [PATCH][RFC] tracing: Enable tracepoints via module parameters

2021-04-20 Thread Steven Rostedt
On Mon, 19 Apr 2021 18:25:54 -0700 Dan Williams wrote: > On Mon, Apr 19, 2021 at 3:11 PM Steven Rostedt wrote: > > > > On Mon, 19 Apr 2021 21:54:13 + > > "Williams, Dan J" wrote: > > > > > [ drop Rusty, add Jessica and Emmanuel ] > &

[ANNOUNCE] 5.10.30-rt37

2021-04-19 Thread Steven Rostedt
Dear RT Folks, I'm pleased to announce the 5.10.30-rt37 stable release. This release is just an update to the new stable 5.10.30 version and no RT specific changes have been made. You can get this release via the git tree at:

Re: [PATCH][RFC] tracing: Enable tracepoints via module parameters

2021-04-19 Thread Steven Rostedt
On Mon, 19 Apr 2021 21:54:13 + "Williams, Dan J" wrote: > [ drop Rusty, add Jessica and Emmanuel ] Probably could have kept Jessica on as she's the module maintainer. > > On Wed, 2013-08-14 at 23:32 -0400, Steven Rostedt wrote: > > On Thu, 15 Aug 2013 11:32:10 +

Re: [PATCH v3 1/3] tracing: Show real address for trace event arguments

2021-04-19 Thread Steven Rostedt
On Mon, 19 Apr 2021 14:08:14 +0100 Jon Hunter wrote: > I have encountered the following crash on a couple of our ARM64 Jetson > platforms and bisect is pointing to this change. The crash I am seeing > is on boot when I am directing the trace prints to the console by adding > 'tp_printk

[for-next][PATCH 7/7] ftrace: Reuse the output of the function tracer for func_repeats

2021-04-16 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The func_repeats event shows the output of the function tracer followed by a count of the number of repeats the previous function had made, as well as the timestamp of the last function that was repeated. The printing of the function should b

[for-next][PATCH 6/7] tracing: Add "func_no_repeats" option for function tracing

2021-04-16 Thread Steven Rostedt
following by event showing the number of repeats. Link: https://lkml.kernel.org/r/20210415181854.147448-7-y.kar...@gmail.com Signed-off-by: Yordan Karadzhov (VMware) Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_functions.c | 162 - 1 file ch

[for-next][PATCH 5/7] tracing: Unify the logic for function tracing options

2021-04-16 Thread Steven Rostedt
that new options can be easily added. Link: https://lkml.kernel.org/r/20210415181854.147448-6-y.kar...@gmail.com Signed-off-by: Yordan Karadzhov (VMware) Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_functions.c | 65 -- 1 file changed, 38 insert

[for-next][PATCH 4/7] tracing: Add method for recording "func_repeats" events

2021-04-16 Thread Steven Rostedt
ov (VMware) Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace.c | 34 ++ kernel/trace/trace.h | 4 2 files changed, 38 insertions(+) diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index 82833be07c1e..66a4ad93b5e9 100644 --- a/kernel/trace/tra

[for-next][PATCH 3/7] tracing: Add "last_func_repeats" to struct trace_array

2021-04-16 Thread Steven Rostedt
ink: https://lkml.kernel.org/r/20210415181854.147448-4-y.kar...@gmail.com Signed-off-by: Yordan Karadzhov (VMware) Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace.c | 1 + kernel/trace/trace.h | 12 2 files changed, 13 insertions(+) diff --git a/kernel/trace/trace.c b/ke

[for-next][PATCH 1/7] tracing: Define static void trace_print_time()

2021-04-16 Thread Steven Rostedt
ot;func_repeats". The new static method, defined here, will be used by this new event to print the time of the last repeat of a function that is consecutively called number of times. Link: https://lkml.kernel.org/r/20210415181854.147448-2-y.kar...@gmail.com Signed-off-by: Yordan Karadzhov (VMware)

[for-next][PATCH 2/7] tracing: Define new ftrace event "func_repeats"

2021-04-16 Thread Steven Rostedt
). The new ftrace event can be used to show repeated function events with a single event and save space on the ring buffer Link: https://lkml.kernel.org/r/20210415181854.147448-3-y.kar...@gmail.com Signed-off-by: Yordan Karadzhov (VMware) Signed-off-by: Steven Rostedt (VMware) --- kernel/tra

[for-next][PATCH 0/7] tracing: Add func_no_repeats option

2021-04-16 Thread Steven Rostedt
Steven Rostedt (VMware) , Yordan Karadzhov (VMware) git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git for-next Head SHA1: e1db6338d6fa0d409e45cf20ab5aeaca704f68e7 Steven Rostedt (VMware) (1): ftrace: Reuse the output of the function tracer for func_repeats Yordan

Re: [PATCH v2] X86: Makefile: Replace -pg with CC_FLAGS_FTRACE

2021-04-16 Thread Steven Rostedt
On Fri, 16 Apr 2021 10:12:58 -0500 Josh Poimboeuf wrote: > Adding Steven Rostedt (ftrace maintainer). Thanks. > > On Fri, Apr 16, 2021 at 01:39:28PM +0800, zhaoxiao wrote: > > In preparation for x86 supporting ftrace built on other compiler > > options, let's have the

Re: Bisections with different bug manifestations

2021-04-16 Thread Steven Rostedt
On Fri, 16 Apr 2021 09:51:45 +0200 Dmitry Vyukov wrote: > > If you look at substantial base of bisection logs, you will find lots > of cases where bug types, functions don't match. Kernel crashes > differently even on the same revision. And obviously things change if > you change revisions. Also

Re: [RFC PATCH 3/5] tracing/hwlat: Implement the per-cpu mode

2021-04-15 Thread Steven Rostedt
On Thu, 15 Apr 2021 15:22:52 +0200 Daniel Bristot de Oliveira wrote: > >> --- a/kernel/trace/trace_hwlat.c > >> +++ b/kernel/trace/trace_hwlat.c > >> @@ -34,7 +34,7 @@ > >> * Copyright (C) 2008-2009 Jon Masters, Red Hat, Inc. > >> * Copyrig

Re: [RFC PATCH 2/5] tracing/hwlat: Implement the mode config option

2021-04-15 Thread Steven Rostedt
On Thu, 15 Apr 2021 15:16:04 +0200 Daniel Bristot de Oliveira wrote: > That was my initial intention with the NONE mode, but I feared breaking > something by removing the "migrate_disable" logic. If you do not think it is > a problem, I will remove the migrate disable and just change the mode.

Re: [RFC PATCH 1/5] tracing/hwlat: Add a cpus file specific for hwlat_detector

2021-04-15 Thread Steven Rostedt
On Thu, 15 Apr 2021 15:09:50 +0200 Daniel Bristot de Oliveira wrote: > But for the osnoise tracer the cpus file is really useful. For instance, on a > system with the CPU 7 isolated: > > - %< - > # echo 7 > osnoise/cpus > # echo target_cpu == 7 > events/sched/sched_wakeup/filter >

Re: [RFC PATCH 5/5] tracing: Add the osnoise tracer

2021-04-14 Thread Steven Rostedt
sample_threshold. The reason roots in the tracing overhead and in > the overhead of the entry and exit code that happens before and after > any interference execution. This justifies the dual approach: measuring > thread and tracing. I'm not sure the tracing overhead had much to do

Re: [RFC PATCH 3/5] tracing/hwlat: Implement the per-cpu mode

2021-04-14 Thread Steven Rostedt
running on multiple CPUs at the same time. And totally slow down the entire system in the process ;-) > > Cc: Jonathan Corbet > Cc: Steven Rostedt > Cc: Ingo Molnar > Cc: Peter Zijlstra > Cc: Thomas Gleixner > Cc: Alexandre Chartre > Cc: Clark Willaims > Cc: John Kacu

Re: [RFC PATCH 2/5] tracing/hwlat: Implement the mode config option

2021-04-14 Thread Steven Rostedt
On Thu, 8 Apr 2021 16:13:20 +0200 Daniel Bristot de Oliveira wrote: > +/** > + * hwlat_mode_write - Write function for "mode" entry > + * @filp: The active open file structure > + * @ubuf: The user buffer that contains the value to write > + * @cnt: The maximum number of bytes to write to

Re: [RFC PATCH 1/5] tracing/hwlat: Add a cpus file specific for hwlat_detector

2021-04-14 Thread Steven Rostedt
On Thu, 8 Apr 2021 16:13:19 +0200 Daniel Bristot de Oliveira wrote: > Provides a "cpus" interface to the hardware latency detector. By > default, it lists all CPUs, allowing hwlatd threads to run on any online > CPU of the system. > > It serves to restrict the execution of hwlatd to the set of

[GIT PULL] tracing/dynevent: Fix a memory leak in an error handling path

2021-04-13 Thread Steven Rostedt
by: Masami Hiramatsu Signed-off-by: Christophe JAILLET Signed-off-by: Steven Rostedt (VMware) diff --git a/kernel/trace/trace_dynevent.c b/kernel/trace/trace_dynevent.c index dc971a68dda4..e57cc0870892 100644 --- a/kernel/trace/trace_dynevent.c +++ b/kernel/trace/trace_dynevent.c @@

Re: [PATCH v3 1/5] tracing: Define new ftrace event "func_repeats"

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 15:17:36 -0400 Steven Rostedt wrote: > Running this with trace-cmd record, this displays: > > -0 [001] 261.848848: function: > next_zone > -0 [001] 261.848849: func_repeats: next_zone

Re: [PATCH v3 1/5] tracing: Define new ftrace event "func_repeats"

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 15:17:36 -0400 Steven Rostedt wrote: > Running this with trace-cmd record, this displays: > > -0 [001] 261.848848: function: > next_zone > -0 [001] 261.848849: func_repeats: next_zone

Re: [PATCH v3 1/5] tracing: Define new ftrace event "func_repeats"

2021-04-13 Thread Steven Rostedt
On Fri, 9 Apr 2021 21:10:27 +0300 "Yordan Karadzhov (VMware)" wrote: > --- > kernel/trace/trace.h | 3 +++ > kernel/trace/trace_entries.h | 22 + > kernel/trace/trace_output.c | 47 > 3 files changed, 72 insertions(+) > > diff

Re: [syzbot] possible deadlock in del_gendisk

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 14:40:09 -0400 Steven Rostedt wrote: > [ cut here ] > raw_local_irq_restore() called with IRQs enabled > WARNING: CPU: 0 PID: 8777 at kernel/locking/irqflag-debug.c:9 > warn_bogus_irq_restore kernel/locking/irqflag-debug.c:9 [inline] >

Re: [syzbot] possible deadlock in del_gendisk

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 20:24:00 +0200 Dmitry Vyukov wrote: > On Tue, Apr 13, 2021 at 7:43 PM Steven Rostedt wrote: > > > > On Tue, 13 Apr 2021 13:41:47 -0400 > > Steven Rostedt wrote: > > > > > As the below splats look like it has nothing to do with this

Re: [PATCH v3 2/5] tracing: Add "last_func_repeats" to struct trace_array

2021-04-13 Thread Steven Rostedt
On Fri, 9 Apr 2021 21:10:28 +0300 "Yordan Karadzhov (VMware)" wrote: > --- a/kernel/trace/trace.h > +++ b/kernel/trace/trace.h > @@ -262,6 +262,17 @@ struct cond_snapshot { > cond_update_fn_tupdate; > }; > > +/* > + * struct trace_func_repeats - used to keep track of

Re: [PATCH v3 3/5] tracing: Add method for recording "func_repeats" events

2021-04-13 Thread Steven Rostedt
On Fri, 9 Apr 2021 21:10:29 +0300 "Yordan Karadzhov (VMware)" wrote: > @@ -342,6 +342,12 @@ FTRACE_ENTRY(hwlat, hwlat_entry, > #define FUNC_REPEATS_GET_DELTA_TS(entry) \ > (((u64)entry->top_delta_ts << 32) | entry->bottom_delta_ts) \ > > +#define

Re: [PATCH v3 1/5] tracing: Define new ftrace event "func_repeats"

2021-04-13 Thread Steven Rostedt
On Fri, 9 Apr 2021 21:10:27 +0300 "Yordan Karadzhov (VMware)" wrote: > The event aims to consolidate the function tracing record in the cases > when a single function is called number of times consecutively. > > while (cond) > do_func(); > > This may happen in various

Re: [syzbot] possible deadlock in del_gendisk

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 13:41:47 -0400 Steven Rostedt wrote: > As the below splats look like it has nothing to do with this patch, and > this patch will add a WARN() if there's broken logic somewhere, I bet the > bisect got confused (if it is automated and does a panic_on_warning),

Re: [syzbot] possible deadlock in del_gendisk

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 10:33:19 -0700 syzbot wrote: > Hello, > > syzbot found the following issue on: > > HEAD commit:e99d8a84 Add linux-next specific files for 20210409 > git tree: linux-next > console output: https://syzkaller.appspot.com/x/log.txt?x=13b01681d0 > kernel config:

Re: [PATCH] sched: remove the redundant comments

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 10:36:07 +0200 Dietmar Eggemann wrote: > > @@ -897,11 +897,6 @@ DECLARE_STATIC_KEY_FALSE(sched_uclamp_used); > > struct rq { > > /* runqueue lock: */ > > raw_spinlock_t lock; > > - > > - /* > > -* nr_running and cpu_load should be in the same cacheline

Re: [syzbot] WARNING in bpf_test_run

2021-04-13 Thread Steven Rostedt
On Tue, 13 Apr 2021 09:56:40 +0200 Dmitry Vyukov wrote: > Thanks for looking into this. > If this is not a kernel bug, then it must not use WARN_ON[_ONCE]. It > makes the kernel untestable for both automated systems and humans: > > https://lwn.net/Articles/769365/ > > > Greg Kroah-Hartman

[ANNOUNCE] libtracececmd 1.0.0

2021-04-10 Thread Steven Rostedt
This is the initial official release of libtracecmd 1.0.0. This is needed by KernelShark in order to be in a stand alone repository: https://git.kernel.org/pub/scm/utils/trace-cmd/kernel-shark.git/ All new development for KernelShark now takes place in the above repository, which will depend

[ANNOUNCE] libtracefs 1.1.0

2021-04-10 Thread Steven Rostedt
I'm pleased to announce the new version of libtracefs library has been released: libtracefs: 1.1.0 https://git.kernel.org/pub/scm/libs/libtrace/libtracefs.git/snapshot/libtracefs-1.1.0.tar.gz https://git.kernel.org/pub/scm/libs/libtrace/libtracefs.git/ Changes since 1.0.2: - Depends on

[ANNOUNCE] libtraceevent 1.2.0

2021-04-10 Thread Steven Rostedt
I'm pleased to announce the new version of libtraceevent library has been released: libtraceevent: 1.2.0 https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/snapshot/libtraceevent-1.2.0.tar.gz https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/ Changes since 1.1.3:

Re: [PATCH 1/2] zram: fix crashes due to use of cpu hotplug multistate

2021-04-08 Thread Steven Rostedt
On Thu, 8 Apr 2021 08:18:21 +0200 Greg KH wrote: > And I would love a taint for rmmod, but what is that going to help out > with? Just like any other taint. If a rmmod can cause the system to lose integrity, the rmmod could cause a subtle issue that manifests itself into something more serious

[ANNOUNCE] 5.10.27-rt36

2021-04-07 Thread Steven Rostedt
Dear RT Folks, I'm pleased to announce the 5.10.27-rt36 stable release. This release is just an update to the new stable 5.10.27 version and no RT specific changes have been made. You can get this release via the git tree at:

Re: [PATCH -next] arm: patch: FUNCTION_GRAPH_TRACER depends on CPU_ENDIAN_BE8 or !CPU_ENDIAN_BE32

2021-04-06 Thread Steven Rostedt
On Tue, 6 Apr 2021 18:23:51 +0800 Zhang Jianhua wrote: > If CONFIG_FUNCTION_GRAPH_TRACER=y, the following errors will be seen > while compiling patch.c > > arch/arm/kernel/patch.c: In function ‘__patch_text_real’: > arch/arm/kernel/patch.c:94:11: error: implicit declaration of function >

Re: [PATCH] ftrace: Check if pages were allocated before calling free_pages()

2021-04-06 Thread Steven Rostedt
On Tue, 6 Apr 2021 14:51:45 +0800 Jiapeng Chong wrote: > It is possible that on error pg->size can be zero when getting its > order,which would return a -1 value. It is dangerous to pass in an > order of -1 to free_pages(). Check if order is greater than or equal > to zero before calling

Re: [PATCH v4] sched/debug: Use sched_debug_lock to serialize use of cgroup_path[] only

2021-04-05 Thread Steven Rostedt
On Mon, 5 Apr 2021 19:42:03 -0400 Waiman Long wrote: > +/* > + * All the print_cpu() callers from sched_debug_show() will be allowed > + * to contend for sched_debug_lock and use group_path[] as their SEQ_printf() > + * calls will be much faster. However only one print_cpu() caller from > + *

Re: [PATCH v2 5/5] tracing: Add "func_no_repeats" option for function tracing

2021-04-05 Thread Steven Rostedt
On Mon, 29 Mar 2021 16:05:33 +0300 "Yordan Karadzhov (VMware)" wrote: > If the option is activated the function tracing record gets > consolidated in the cases when a single function is called number > of times consecutively. Instead of having an identical record for > each call of the function

Re: [PATCH v2 4/5] tracing: Unify the logic for function tracing options

2021-04-05 Thread Steven Rostedt
On Mon, 29 Mar 2021 16:05:32 +0300 "Yordan Karadzhov (VMware)" wrote: > Currently the logic for dealing with the options for function tracing > has two different implementations. One is used when we set the flags > (in "static int func_set_flag()") and another used when we initialize > the

Re: [PATCH v2 1/5] tracing: Define new ftrace event "func_repeats"

2021-04-05 Thread Steven Rostedt
On Mon, 29 Mar 2021 16:05:29 +0300 "Yordan Karadzhov (VMware)" wrote: > The event aims to consolidate the function tracing record in the cases > when a single function is called number of times consecutively. > > while (cond) > do_func(); > > This may happen in various

Re: [PATCH v3] sched/debug: Use sched_debug_lock to serialize use of cgroup_path[] only

2021-04-05 Thread Steven Rostedt
On Sun, 4 Apr 2021 21:27:00 -0400 Waiman Long wrote: > Thanks for the suggestion, but it also sound complicated. It's not that complicated. Similar tricks have been used elsewhere in the kernel. > > I think we can fix this lockup problem if we are willing to lose some It's not a lockup

Re: [PATCH v3] sched/debug: Use sched_debug_lock to serialize use of cgroup_path[] only

2021-04-04 Thread Steven Rostedt
On Fri, 2 Apr 2021 23:09:09 -0400 Waiman Long wrote: > The main problem with sched_debug_lock is that under certain > circumstances, a lock waiter may wait a long time to acquire the lock > (in seconds). We can't insert touch_nmi_watchdog() while the cpu is > waiting for the spinlock. The

[for-next][PATCH 4/4] ftrace: Simplify the calculation of page number for ftrace_page->records some more

2021-04-03 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Commit b40c6eabfcd40 ("ftrace: Simplify the calculation of page number for ftrace_page->records") simplified the calculation of the number of pages needed for each page group without having any empty pages, but it can be simplified even

[for-next][PATCH 3/4] ftrace: Store the order of pages allocated in ftrace_page

2021-04-03 Thread Steven Rostedt
-=whyMxheOqXAORt9a7JK9gc9eHTgCJ55Pgs4p=x3rrq...@mail.gmail.com/ Signed-off-by: Linus Torvalds [ change log written by Steven Rostedt ] Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/ftrace.c | 35 +-- 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/kernel/trace/ftrace.c

[for-next][PATCH 1/4] tracing: Remove duplicate struct declaration in trace_events.h

2021-04-03 Thread Steven Rostedt
From: Wan Jiabing struct trace_array is declared twice. One has been declared at forward declaration. Remove the duplicate. Link: https://lkml.kernel.org/r/20210330034056.2266969-1-wanjiab...@vivo.com Signed-off-by: Wan Jiabing Signed-off-by: Steven Rostedt (VMware) --- include/linux

[for-next][PATCH 2/4] tracing: Remove unused argument from "ring_buffer_time_stamp()

2021-04-03 Thread Steven Rostedt
From: "Yordan Karadzhov (VMware)" The "cpu" parameter is not being used by the function. Link: https://lkml.kernel.org/r/20210329130331.199402-1-y.kar...@gmail.com Signed-off-by: Yordan Karadzhov (VMware) Signed-off-by: Steven Rostedt (VMware) --- include/linux/ring_buf

[for-next][PATCH 0/4] tracing: More updates for 5.13

2021-04-03 Thread Steven Rostedt
git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git for-next Head SHA1: ceaaa12904df07d07ea8975abbf04c4d60e46956 Linus Torvalds (1): ftrace: Store the order of pages allocated in ftrace_page Steven Rostedt (VMware) (1): ftrace: Simplify the calculation of page

Re: [PATCH v3] sched/debug: Use sched_debug_lock to serialize use of cgroup_path[] only

2021-04-02 Thread Steven Rostedt
On Thu, 1 Apr 2021 14:10:30 -0400 Waiman Long wrote: > The handling of sysrq key can be activated by echoing the key to > /proc/sysrq-trigger or via the magic key sequence typed into a terminal > that is connected to the system in some way (serial, USB or other mean). > In the former case, the

[GIT PULL] tracing: Fix stack trace event size

2021-04-02 Thread Steven Rostedt
which can be found at: git://git.kernel.org/pub/scm/linux/kernel/git/rostedt/linux-trace.git trace-v5.12-rc5-2 Tag SHA1: cb39aeb904fb1dc0fff7e13799d9ad287fb4697f Head SHA1: 9deb193af69d3fd6dd8e47f292b67c805a787010 Steven Rostedt (VMware) (1): tracing: Fix stack trace event size ke

Re: [GIT PULL] ftrace: Check if pages were allocated before calling free_pages()

2021-04-01 Thread Steven Rostedt
On Thu, 1 Apr 2021 13:18:59 -0700 Linus Torvalds wrote: > On Thu, Apr 1, 2021 at 1:07 PM Steven Rostedt wrote: > > > > On Wed, 31 Mar 2021 11:03:21 -0700 > > Linus Torvalds wrote: > > > > > @@ -6231,7 +6231,8 @@ static int ftrace_process_locs(struct module

Re: [GIT PULL] ftrace: Check if pages were allocated before calling free_pages()

2021-04-01 Thread Steven Rostedt
On Thu, 1 Apr 2021 16:07:10 -0400 Steven Rostedt wrote: > > @@ -6231,7 +6231,8 @@ static int ftrace_process_locs(struct module *mod, > > if (!addr) > > continue; > > > > - if (pg->index == pg->size) { > > +

Re: [GIT PULL] ftrace: Check if pages were allocated before calling free_pages()

2021-04-01 Thread Steven Rostedt
On Wed, 31 Mar 2021 11:03:21 -0700 Linus Torvalds wrote: > @@ -6231,7 +6231,8 @@ static int ftrace_process_locs(struct module *mod, > if (!addr) > continue; > > - if (pg->index == pg->size) { > + end_offset = (pg->index+1) *

Re: [PATCH] kernel: initialize cpumask before parsing

2021-04-01 Thread Steven Rostedt
nd_next_bit() accesses uninitialized cpu mask variable. Fix this > problem by replacing alloc_cpumask_var() with zalloc_cpumask_var(). > > Signed-off-by: Tetsuo Handa > --- > kernel/irq/proc.c| 4 ++-- > kernel/profile.c | 2 +- > kernel/trace/trace.c | 2 +- Acked-by: Steven Rostedt (VMware) -- Steve

Re: User stacktrace garbage when USER_STACKTRACE_SUPPORT is not enabled

2021-03-31 Thread Steven Rostedt
On Thu, 1 Apr 2021 00:02:57 +0200 Vasily Gorbik wrote: > I only tested it on s390 (manually + ftrace selftest), quite frankly. > If it qualifies: You reported the bug, thus tested-by from the reporter always qualifies ;-) > > Tested-by: Vasily Gorbik # s390 only Thanks, -- Steve

Re: User stacktrace garbage when USER_STACKTRACE_SUPPORT is not enabled

2021-03-31 Thread Steven Rostedt
On Wed, 31 Mar 2021 22:51:15 +0200 Vasily Gorbik wrote: > It does! Thanks for the explanation and for the fix. I wonder why nobody > noticed and complained about that since v5.6. Because it didn't lose data, just added extra junk. > > Acked-by: Vasily Gorbik Want to give a "tested-by" too?

Re: [GIT PULL] ftrace: Check if pages were allocated before calling free_pages()

2021-03-31 Thread Steven Rostedt
On Wed, 31 Mar 2021 11:03:21 -0700 Linus Torvalds wrote: > I found another bug in there, for example: > > ftrace_number_of_pages -= 1 << order; > > is also wrong if order is negative. True, but ftrace_number_of_pages is only used for accounting (used to display the number of

Re: [GIT PULL] ftrace: Check if pages were allocated before calling free_pages()

2021-03-31 Thread Steven Rostedt
On Wed, 31 Mar 2021 10:45:01 -0700 Linus Torvalds wrote: > On Wed, Mar 31, 2021 at 6:27 AM Steven Rostedt wrote: > > > > order = get_count_order(pg->size / ENTRIES_PER_PAGE); > > - free_pages((unsigned long)pg->records, order); > &g

Re: User stacktrace garbage when USER_STACKTRACE_SUPPORT is not enabled

2021-03-31 Thread Steven Rostedt
On Wed, 31 Mar 2021 13:52:45 +0200 Vasily Gorbik wrote: > Hi Steven, > > At least on s390 since commit cbc3b92ce037 ("tracing: Set kernel_stack's > caller size properly") kernel stack trace contains 8 garbage values in the > end. > I assume those are supposed to be filled by

Re: [PATCH 2/3] tracing: Use pr_crit() instead of long fancy messages

2021-03-31 Thread Steven Rostedt
On Wed, 31 Mar 2021 11:31:03 +0200 Geert Uytterhoeven wrote: > This reduces kernel size by ca. 0.5 KiB. If you are worried about size, disable tracing and it will go away entirely. 0.5KiB is a drop in the bucket compared to what tracing adds in size overhead. Sorry, but NAK. This has been

[GIT PULL] ftrace: Check if pages were allocated before calling free_pages()

2021-03-31 Thread Steven Rostedt
pub/scm/linux/kernel/git/rostedt/linux-trace.git trace-v5.12-rc5 Tag SHA1: 30ee29d701d2b6848cfa1c7a163745fb68aabd36 Head SHA1: 59300b36f85f254260c81d9dd09195fa49eb0f98 Steven Rostedt (VMware) (1): ftrace: Check if pages were allocated before calling free_pages() kernel/trace/ftrace.c

Re: [PATCH] riscv: kprobes/ftrace: Add recursion protection to the ftrace callback

2021-03-30 Thread Steven Rostedt
recursion protection to the > ftrace callback"), so do similar modifications as the commit does. > > Fixes: 829adda597fe ("riscv: Add KPROBES_ON_FTRACE supported") > Signed-off-by: Jisheng Zhang Looks fine to me. Reviewed-by: Steven Rostedt (VMware) -- Steve

Re: [PATCH] ftrace: Modify parameter transfer type

2021-03-30 Thread Steven Rostedt
On Tue, 30 Mar 2021 18:02:26 +0800 Jiapeng Chong wrote: > Fix the following whitescan warning: > > "order" is passed to a parameter that cannot be negative. > > Reported-by: Abaci Robot > Signed-off-by: Jiapeng Chong > --- > kernel/trace/ftrace.c | 2 +- > 1 file changed, 1 insertion(+), 1

Re: [PATCH] linux/trace_events.h: Remove duplicate struct declaration

2021-03-29 Thread Steven Rostedt
On Tue, 30 Mar 2021 09:55:17 +0800 Wan Jiabing wrote: > struct trace_array is declared twice. One has been declared > at forward struct declaration. Remove the duplicate. > And sort these forward declarations alphabetically. Um, no that's not how we sort things. > > Signed-off-by: Wan Jiabing

Re: [PATCH 6/9] debugfs: Implement debugfs_create_str()

2021-03-27 Thread Steven Rostedt
On Sat, 27 Mar 2021 22:24:45 + Al Viro wrote: > On Fri, Mar 26, 2021 at 11:33:58AM +0100, Peter Zijlstra wrote: > > > +again: > > + rcu_read_lock(); > > + str = rcu_dereference(*(char **)file->private_data); > > + len = strlen(str) + 1; > > + > > + if (!copy || copy_len < len) { > >

[for-next][PATCH 3/6] tracing: Fix various typos in comments

2021-03-26 Thread Steven Rostedt
-by: Ingo Molnar Signed-off-by: Steven Rostedt (VMware) --- arch/microblaze/include/asm/ftrace.h | 2 +- arch/nds32/kernel/ftrace.c | 2 +- arch/powerpc/include/asm/ftrace.h| 4 ++-- arch/sh/kernel/ftrace.c | 2 +- arch/sparc/include/asm/ftrace.h | 2 +- fs/tracefs

[for-next][PATCH 0/6] tracing: More updates for 5.13

2021-03-26 Thread Steven Rostedt
Qiujun Huang (2): tracing: A minor cleanup for create_system_filter() tracing: Update create_system_filter() kernel-doc comment Steven Rostedt (VMware) (2): scripts/recordmcount.pl: Make indent spacing consistent scripts/recordmcount.pl: Make vim and emacs indent the same

[for-next][PATCH 1/6] scripts/recordmcount.pl: Make indent spacing consistent

2021-03-26 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Emacs by default will have perl files have 4 space indents, where 8 spaces are represented with a single tab. There are some places in recordmcount.pl that has 8 spaces where a tab should be used. Replace them to make the file consistent. No function

[for-next][PATCH 2/6] scripts/recordmcount.pl: Make vim and emacs indent the same

2021-03-26 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" By default, emacs indents Perl files with 4 spaces, but will use tabs where 8 spaces are used. Add a vim command of softtabstop=4, to make vim behave the same. This should remove the issue of developers using vim having causing different indentati

[for-next][PATCH 4/6] kernel: trace: Mundane typo fixes in the file trace_events_filter.c

2021-03-26 Thread Steven Rostedt
From: Bhaskar Chowdhury s/callin/calling/ Link: https://lkml.kernel.org/r/20210317095401.1854544-1-unixbhas...@gmail.com Acked-by: Randy Dunlap Signed-off-by: Bhaskar Chowdhury [ Other fixes already done by Ingo Molnar ] Signed-off-by: Steven Rostedt (VMware) --- kernel/trace

[for-next][PATCH 5/6] tracing: A minor cleanup for create_system_filter()

2021-03-26 Thread Steven Rostedt
From: Qiujun Huang The first two parameters should be reduced to one, as @tr is simply @dir->tr. Link: https://lkml.kernel.org/r/20210324205642.65e03...@oasis.local.home Link: https://lkml.kernel.org/r/20210325163752.128407-1-hqjag...@gmail.com Suggested-by: Steven Rostedt (VMware) Signed-

[for-next][PATCH 6/6] tracing: Update create_system_filter() kernel-doc comment

2021-03-26 Thread Steven Rostedt
er from @system to @dir. Link: https://lkml.kernel.org/r/20210325161911.123452-1-hqjag...@gmail.com Signed-off-by: Qiujun Huang Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_events_filter.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/kernel/trace/trace_ev

Re: [PATCH -tip v4 10/12] x86/kprobes: Push a fake return address at kretprobe_trampoline

2021-03-26 Thread Steven Rostedt
On Fri, 26 Mar 2021 21:03:49 +0900 Masami Hiramatsu wrote: > I confirmed this is not related to this series, but occurs when I build > kernels with different > configs without cleanup. > > Once I build kernel with CONFIG_UNWIND_GUESS=y (for testing), and after that, > I build kernel again with

[ANNOUNCE] KernelShark 1.3

2021-03-25 Thread Steven Rostedt
I'm happy to announce KernelShark Version 1.3 *** NOTICE *** KernelShark is now in its own repository (and will depend on libtracecmd). This is the last version that will home KernelShark in the trace-cmd.git repo. New development of KernelShark now lives here:

[ANNOUNCE] trace-cmd 2.9.2

2021-03-25 Thread Steven Rostedt
I'm happy to announce trace-cmd version 2.9.2! *** NOTICE *** This is the last version that is self contained for interacting with the tracefs directory and parsing the events. The parsing of events is now a separate repository: https://git.kernel.org/pub/scm/libs/libtrace/libtraceevent.git/

Re: [RFC][PATCH] task_struct::state frobbing

2021-03-25 Thread Steven Rostedt
On Thu, 25 Mar 2021 19:11:37 +0100 Peter Zijlstra wrote: > diff --git a/drivers/net/ethernet/qualcomm/qca_spi.c > b/drivers/net/ethernet/qualcomm/qca_spi.c > index 5a3b65a6eb4f..17ee771e0051 100644 > --- a/drivers/net/ethernet/qualcomm/qca_spi.c > +++ b/drivers/net/ethernet/qualcomm/qca_spi.c >

Re: [PATCH 2/2] streamline_config.pl: Add softtabstop=4 for vim users

2021-03-25 Thread Steven Rostedt
On Thu, 25 Mar 2021 23:09:38 +0900 Masahiro Yamada wrote: > > > Not all people use vim. > > > > I don't use it either. I was trying to make vim match emacs. Of course for > > those that use something else, it wont help. I'm curious, what's your main > > editor that you use? > > > I use

<    5   6   7   8   9   10   11   12   13   14   >