[for-next][PATCH 0/5] tracing: Last minute updates for 5.12

2021-02-15 Thread Steven Rostedt
Masami Hiramatsu (3): tracing: Show real address for trace event arguments tracing: Update the stage 3 of trace event macro comment tracing: Add ptr-hash option to show the hashed pointer value Steven Rostedt (VMware) (1): tracing: Make hash-ptr option default Viktor

Re: [PATCH] Add the latency-collector to tools

2021-02-15 Thread Steven Rostedt
On Mon, 15 Feb 2021 11:54:08 + wrote: > Just a quick update: I was able to reproduce this weird behavior that I wrote > about but it turned out to be a problem with my testing. > > The test was faulty because of a mistake that I had made. > > Sorry for the extra noise. No problem. Thanks

Re: [tip: objtool/urgent] objtool: Fix seg fault with Clang non-section symbols

2021-02-15 Thread Steven Rostedt
On Sun, 14 Feb 2021 09:51:47 -0600 Josh Poimboeuf wrote: > Steve, looks like recordmcount avoids referencing weak symbols directly > by their function symbol. Maybe it can just skip weak symbols which > don't have a section symbol, since this seems like a rare scenario. When does the

Re: [tip: objtool/urgent] objtool: Fix seg fault with Clang non-section symbols

2021-02-13 Thread Steven Rostedt
On Sat, 13 Feb 2021 15:09:02 +0100 Greg Kroah-Hartman wrote: > Thanks for the patch, but no, still fails with: > > Cannot find symbol for section 8: .text.unlikely. > kernel/kexec_file.o: failed > make[1]: *** [scripts/Makefile.build:277: kernel/kexec_file.o] Error 1 > make[1]: *** Deleting

[PATCH] tracing: Make hash-ptr option default

2021-02-12 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Since the original behavior of the trace events is to hash the %p pointers, make that the default, and have developers have to enable the option in order to have them unhashed. [ Based off of these patches: https://lore.kerne

Re: [tip: objtool/urgent] objtool: Fix seg fault with Clang non-section symbols

2021-02-12 Thread Steven Rostedt
On Fri, 12 Feb 2021 11:07:50 -0600 Josh Poimboeuf wrote: > > Any ideas are appreciated. > > [ Adding Steve Rostedt ] > > This error message comes from recordmcount. It probably can't handle > the missing STT_SECTION symbols which are getting stripped by the new > binutils. (Objtool also

Re: [PATCH v3 3/3] tracing: Add ptr-hash option to show the hashed pointer value

2021-02-12 Thread Steven Rostedt
Hi Masami, I noticed theses sitting in my patchwork and I said I was going to hold off to the next merge window, and these got pushed down in my stack :-/ On Thu, 15 Oct 2020 23:55:25 +0900 Masami Hiramatsu wrote: > Add tracefs/options/hash-ptr option to show hashed pointer > value by %p in

Re: [PATCH 5/6] tracefs: Add FS_GENERATED_CONTENT to filesystem flags

2021-02-12 Thread Steven Rostedt
On Fri, 12 Feb 2021 12:44:04 +0800 Nicolas Boichat wrote: > tracefs content is generated at runtime. > > Signed-off-by: Nicolas Boichat Acked-by: Steven Rostedt (VMware) -- Steve > --- > > fs/tracefs/inode.c | 1 + > 1 file changed, 1 insertion(+) > > diff -

[GIT PULL] tracing: Check length before giving out the filter buffer

2021-02-12 Thread Steven Rostedt
Steven Rostedt (VMware) Linus, tracing: Fix buffer overflow in trace event filter It was reported that if a trace event was larger than a page and was filtered, that it caused memory corruption. The reason is that filtered events first go into a buffer to test the filter before being written

Re: [PATCH] RFC: x86/jump_label: Mark arguments as const to satisfy asm constraints

2021-02-12 Thread Steven Rostedt
const` label. Yes this makes sense. The "i" constraint needs to be a constant. Reviewed-by: Steven Rostedt (VMware) -- Steve > > Signed-off-by: Jason Gerecke > Cc: Steven Rostedt > Cc: Ard Biesheuvel > --- > Marked RFC since I'm not familiar with this subsys

Re: linux-next: Fixes tag needs some work in the ftrace tree

2021-02-11 Thread Steven Rostedt
On Fri, 12 Feb 2021 07:57:28 +1100 Stephen Rothwell wrote: > Hi all, > > In commit > > b5e7014fe1c4 ("selftests/ftrace: Update synthetic event syntax errors") > > Fixes tag > > Fixes: 81ff92a93d95 (selftests/ftrace: Add test case for synthetic > > has these problem(s): > > - Subject

Re: [PATCH] Add the latency-collector to tools

2021-02-11 Thread Steven Rostedt
On Thu, 11 Feb 2021 17:17:42 +0100 Viktor Rosendahl wrote: > It seems to work but I discovered during testing that it seems like newer > kernels have a tendency to lose some latencies in longer bursts. I guess this > is likely to be another regression in the preemptirqsoff tracer. Not sure what

[for-next][PATCH 09/12] tracing: Update synth command errors

2021-02-10 Thread Steven Rostedt
in place of CMD_INCOMPLETE, which is removed, and remove CMD_TOO_LONG, since it's no longer used. Link: https://lkml.kernel.org/r/b9dd434dc6458dcff11adc6ed616fe93a8794770.1612208610.git.zanu...@kernel.org Signed-off-by: Tom Zanussi Signed-off-by: Steven Rostedt (VMware) --- kernel/trace

[for-next][PATCH 11/12] selftests/ftrace: Update synthetic event syntax errors

2021-02-10 Thread Steven Rostedt
/ftrace: Add test case for synthetic event syntax errors) Link: https://lkml.kernel.org/r/51402656433455baead34f068c6e9466b64df9c0.1612208610.git.zanu...@kernel.org Reported-by: Masami Hiramatsu Signed-off-by: Tom Zanussi Signed-off-by: Steven Rostedt (VMware) --- .../trigger

[for-next][PATCH 10/12] tracing: Add a backward-compatibility check for synthetic event creation

2021-02-10 Thread Steven Rostedt
://lkml.kernel.org/r/74fcc500d561b40ce91c5ee94818c70c6b0c9330.1612208610.git.zanu...@kernel.org [ zanussi: added check_field_version() comment from rost...@goodmis.org ] Signed-off-by: Tom Zanussi Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_events_synth.c | 93

[for-next][PATCH 12/12] selftests/ftrace: Add !event synthetic event syntax check

2021-02-10 Thread Steven Rostedt
From: Tom Zanussi Add a check confirming that '!event' alone will remove a synthetic event. Link: https://lkml.kernel.org/r/1dff3f03d18542cece08c10d6323d8a8dba11e42.1612208610.git.zanu...@kernel.org Signed-off-by: Tom Zanussi Signed-off-by: Steven Rostedt (VMware) --- .../trigger/inter

[for-next][PATCH 07/12] tracing/dynevent: Delegate parsing to create function

2021-02-10 Thread Steven Rostedt
.1612208610.git.zanu...@kernel.org Signed-off-by: Masami Hiramatsu [ zanu...@kernel.org: added synthetic event modifications ] Signed-off-by: Tom Zanussi Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace.c | 23 ++-- kernel/trace/trace.h | 3 +- kernel

[for-next][PATCH 08/12] tracing: Rework synthetic event command parsing

2021-02-10 Thread Steven Rostedt
-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_events_synth.c | 245 +- 1 file changed, 143 insertions(+), 102 deletions(-) diff --git a/kernel/trace/trace_events_synth.c b/kernel/trace/trace_events_synth.c index b2588a5650c9..4f6c5a104ee2 100644 --- a/kernel

[for-next][PATCH 05/12] ftrace: Remove unused ftrace_force_update()

2021-02-10 Thread Steven Rostedt
ngson.cn Signed-off-by: Jinyang He Signed-off-by: Steven Rostedt (VMware) --- include/linux/ftrace.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/include/linux/ftrace.h b/include/linux/ftrace.h index 9a8ce28e4485..86e5028bfa20 100644 --- a/include/linux/ftrace.h +++ b/include/linux/ftrac

[for-next][PATCH 06/12] kprobes: Warn if the kprobe is reregistered

2021-02-10 Thread Steven Rostedt
-by: Ananth N Mavinakayanahalli Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- kernel/kprobes.c | 13 - 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/kernel/kprobes.c b/kernel/kprobes.c index d5a3eb74a657..dd1d027455c4 100644 --- a/kernel

[for-next][PATCH 03/12] tracepoints: Do not punish non static call users

2021-02-10 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" With static calls, a tracepoint can call the callback directly if there is only one callback registered to that tracepoint. When there is more than one, the static call will call the tracepoint's "iterator" function, which needs to reload the

[for-next][PATCH 04/12] tracepoints: Code clean up

2021-02-10 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Restructure the code a bit to make it simpler, fix some formatting problems and add READ_ONCE/WRITE_ONCE to make sure there's no compiler load/store tearing to the variables that can be accessed across CPUs. Started with Mathieu Desnoyers's patch: Li

[for-next][PATCH 00/12] tracing: Updates for 5.12

2021-02-10 Thread Steven Rostedt
Jinyang He (1): ftrace: Remove unused ftrace_force_update() Masami Hiramatsu (2): kprobes: Warn if the kprobe is reregistered tracing/dynevent: Delegate parsing to create function Steven Rostedt (VMware) (4): tracing: Do not create "enable" or "filter&qu

[for-next][PATCH 02/12] tracepoints: Remove unnecessary "data_args" macro parameter

2021-02-10 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" While working on a clean up that would restructure the difference between architectures that have static calls vs those that do not, I was stumbling over the "data_args" parameter that includes "__data" in the arguments. The issue wa

[for-next][PATCH 01/12] tracing: Do not create "enable" or "filter" files for ftrace event subsystem

2021-02-10 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The ftrace event subsystem is only created for showing the format files of events created by the ftrace tracers, and are not trace events. The ftrace subsystem currently has both the "enable" and "filter" files that in other subsyst

Re: KASAN: vmalloc-out-of-bounds Read in bpf_trace_run3

2021-02-10 Thread Steven Rostedt
On Wed, 10 Feb 2021 19:23:38 +0100 Eric Dumazet wrote: > >> The problem here is a kmalloc failure injection into > >> tracepoint_probe_unregister, but the error is ignored -- so the bpf > >> program is freed even though the tracepoint is never unregistered. > >> > >> I have a first pass at a

Re: [PATCH 0/3][RESEND] add support for never printing hashed addresses

2021-02-10 Thread Steven Rostedt
On Thu, 11 Feb 2021 02:07:21 +0900 Tetsuo Handa wrote: > I'm not refusing to use kernel command line options. I'm expecting that we can > also hardcode using kernel config options. Since boot-time switching via > kernel > command line options makes the kernel behave differently, less boot-time

Re: [PATCH 0/3][RESEND] add support for never printing hashed addresses

2021-02-10 Thread Steven Rostedt
On Thu, 11 Feb 2021 01:39:41 +0900 Tetsuo Handa wrote: > On 2021/02/11 1:18, Steven Rostedt wrote: > > The point of this exercise is to be able to debug the *same* kernel that > > someone is having issues with. And this is to facilitate that debugging. > > That's

Re: [PATCH 0/3][RESEND] add support for never printing hashed addresses

2021-02-10 Thread Steven Rostedt
On Thu, 11 Feb 2021 00:46:15 +0900 Tetsuo Handa wrote: > Oh, I was wishing > > diff --git a/lib/vsprintf.c b/lib/vsprintf.c > index 3b53c73580c5..34c7e145ac3c 100644 > --- a/lib/vsprintf.c > +++ b/lib/vsprintf.c > @@ -802,7 +802,7 @@ static char *ptr_to_id(char *buf, char *end, const void >

Re: [PATCH] tee: optee: add invoke_fn tracepoints

2021-02-10 Thread Steven Rostedt
--- > > Since v1: > - add BUILD_BUG_ON() macro usage to make sure that the size of what is being >copied, is not smaller than the amount being copied. Thank Steve. > - move optee_trace.h to keep include headers sorted >From a tracing point of view: Reviewed-by: Steven Rostedt (VMware) -- Steve

Re: [PATCH v7 0/6] tracing: More synthetic event error fixes

2021-02-09 Thread Steven Rostedt
On Tue, 09 Feb 2021 16:58:12 -0600 Tom Zanussi wrote: > Did you apply '[PATCH v7 5/6] selftests/ftrace: Update synthetic event > syntax errors' before you ran the test? It actually removes the test > that failed. Here's what I get with all patches applied: I thought I did, but I forgot that I

Re: [PATCH v7 0/6] tracing: More synthetic event error fixes

2021-02-09 Thread Steven Rostedt
On Mon, 1 Feb 2021 13:48:10 -0600 Tom Zanussi wrote: > Hi, > > This is v7 of the synthetic event error fix patchset. This version > addresses the comments from v6: > > - moved check_command() from '[PATCH v6 3/6] tracing: Update synth > command errors' to '[PATCH v6 2/6] tracing:

Re: [PATCH] sched: Use SCHED_WARN_ON() instead of WARN_ON_ONCE() with CONFIG_SCHED_DEBUG

2021-02-09 Thread Steven Rostedt
On Wed, 3 Feb 2021 17:50:12 +0800 Yue Hu wrote: > From: Yue Hu > > Since SCHED_WARN_ON() is provided as a wrapper for WARN_ON_ONCE(). Reviewed-by: Steven Rostedt (VMware) Peter, care to take this? Also, looks like we can get rid of the #ifdef CONFIG_SCHED_DEBUG in set

Re: [PATCH] kprobes: Warn if the kprobe is reregistered

2021-02-09 Thread Steven Rostedt
On Wed, 3 Feb 2021 23:59:27 +0900 Masami Hiramatsu wrote: > Warn if the kprobe is reregistered, since there must be > a software bug (actively used resource must not be re-registered) > and caller must be fixed. > > Signed-off-by: Masami Hiramatsu > --- Applied. Thanks Masami! -- Steve

Re: [PATCH] tee: optee: add invoke_fn tracepoints

2021-02-09 Thread Steven Rostedt
On Tue, 9 Feb 2021 19:02:15 +0800 Jisheng Zhang wrote: > Add tracepoints to retrieve information about the invoke_fn. This would > help to measure how many invoke_fn are triggered and how long it takes > to complete one invoke_fn call. > > Signed-off-by: Jisheng Zhang > --- >

Re: [GIT PULL] x86/urgent for v5.11-rc7

2021-02-09 Thread Steven Rostedt
On Tue, 9 Feb 2021 09:32:34 +0100 (CET) Miroslav Benes wrote: > powerpc has this > > static inline unsigned long klp_get_ftrace_location(unsigned long faddr) > > { >

[PATCH 0/2 v3] tracepoints: Stop punishing non-static call users

2021-02-08 Thread Steven Rostedt
Broke this up into two patches now. See the second patch for the description of waht this series is doing. Changes since v2: Added a patch to remove "data_args", as it was causing issues with handling of "__data", especially when it wasn't needed. Steven

[PATCH 2/2 v3] tracepoints: Do not punish non static call users

2021-02-08 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" With static calls, a tracepoint can call the callback directly if there is only one callback registered to that tracepoint. When there is more than one, the static call will call the tracepoint's "iterator" function, which needs to reload the

[PATCH 1/2 v3] tracepoints: Remove unnecessary "data_args" macro parameter

2021-02-08 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" While working on a clean up that would restructure the difference between architectures that have static calls vs those that do not, I was stumbling over the "data_args" parameter that includes "__data" in the arguments. The issue wa

[GIT PULL] tracing: Fix output of top level event "enable" file

2021-02-08 Thread Steven Rostedt
Steven Rostedt (VMware) Linus, tracing: Fix output of top level event "enable" file When writing a tool for enabling events in the tracing system, an anomaly was discovered. The top level event "enable" file would never show "1" when all events were enabled. The s

Re: [GIT PULL] x86/urgent for v5.11-rc7

2021-02-08 Thread Steven Rostedt
On Mon, 8 Feb 2021 16:47:05 +0100 Peter Zijlstra wrote: > > /* > > * Convert a function address into the appropriate ftrace location. > > * > > * Usually this is just the address of the function, but on some > > architectures > > * it's more complicated so allow them to provide a custom

[for-linus][PATCH] tracing: Do not count ftrace events in top level enable output

2021-02-08 Thread Steven Rostedt
Steven Rostedt (VMware) (1): tracing: Do not count ftrace events in top level enable output kernel/trace/trace_events.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) --- commit 256cfdd6fdf70c6fcf0f7c8ddb0ebd73ce8f3bc9 Author: Steven Rostedt (VMware

Re: [GIT PULL] x86/urgent for v5.11-rc7

2021-02-08 Thread Steven Rostedt
On Sun, 7 Feb 2021 16:45:40 -0600 Josh Poimboeuf wrote: > > I do suspect involved people should start thinking about how they want > > to deal with functions starting with > > > > endbr64 > > call __fentry__ > > > > instead of the call being at the very top of the function. >

Re: [PATCH] printk: Userspace format enumeration support

2021-02-05 Thread Steven Rostedt
On Fri, 5 Feb 2021 22:45:19 + Chris Down wrote: > >I'm not against the idea. I don't think it belongs in /proc. Perhaps > >debugfs is a better place to put it. > > Any location is fine with me, as long as it gets to userspace. How does > /printk/formats or /printk/formats/ sound to you?

[PATCH v2] tracepoints: Do not punish non static call users

2021-02-05 Thread Steven Rostedt
From: Steven Rostedt With static calls, a tracepoint can call the callback directly if there is only one callback registered to that tracepoint. When there is more than one, the static call will call the tracepoint's "iterator" function, which needs to reload the tracepoint's "fun

Re: [PATCH 1/2] x86/unwind/orc: Disable KASAN checking in the ORC unwinder, part 2

2021-02-05 Thread Steven Rostedt
ccesses. This finishes the job started by commit 881125bfe65b > ("x86/unwind: Disable KASAN checking in the ORC unwinder"), which only > partially fixed the issue. > > Fixes: ee9f8fce9964 ("x86/unwind: Add the ORC unwinder") > Reported-by: Ivan Babrou > Cc: sta...@vger.kernel.org > Signed-off-by: Josh Poimboeuf Reviewed-by: Steven Rostedt (VMware) -- Steve

Re: [PATCH] lib: Replace obscene word with a better one :)

2021-02-05 Thread Steven Rostedt
On Fri, 5 Feb 2021 17:45:43 +0530 Bhaskar Chowdhury wrote: > s/fucked/messed/ Rules about obscene language is about new code coming into the kernel. We don't want to encourage people to do sweeping changes of existing code. It just causes unwanted churn, and adds noise to the git logs. Sorry,

Re: [PATCH] printk: Userspace format enumeration support

2021-02-05 Thread Steven Rostedt
On Fri, 5 Feb 2021 17:42:55 +0100 Petr Mladek wrote: > Hi, > > I would like to hear opinion from a bigger audience. It is an > userspace interface that we might need to maintain forewer. > Adding few more people in to CC: > > Steven Rostedt : printk co-maintainer

Re: [PATCH] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-04 Thread Steven Rostedt
On Thu, 4 Feb 2021 15:59:21 -0600 Timur Tabi wrote: > I think the reason behind the large banner has less to do how insecure > the system is, and more about making sure vendors and sysadmins don't > enable it by default everywhere. +100 -- Steve

Re: [PATCH] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-04 Thread Steven Rostedt
On Thu, 4 Feb 2021 22:49:44 +0100 Pavel Machek wrote: > This machine is insecure. Yet I don't see ascii-art *** all around.. > > "Kernel memory addresses are exposed, which is bad for security." > would be quite enough, I'd say... Well, the alternative is that you go back to patching your own

Re: [PATCH] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-04 Thread Steven Rostedt
On Thu, 4 Feb 2021 21:48:35 +0100 Pavel Machek wrote: > > + pr_warn("** Kernel memory addresses are exposed, which may **\n"); > > + pr_warn("** compromise security on your system. > > **\n"); > > This is lies, right? And way too verbose. Not really. More of an

Re: [PATCH] tracepoints: Do not punish non static call users

2021-02-04 Thread Steven Rostedt
again to the functions that are loaded. But sure, because of the double load too (and the NULL check is only because of the load ;-) > > > architectures with static calls, and just call the iterator function > > directly for architectures without static calls. > > > > [ Tested o

[PATCH v2] tracepoints: Code clean up

2021-02-04 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Restructure the code a bit to make it simpler, fix some formatting problems and add READ_ONCE/WRITE_ONCE to make sure there's no compiler load/store tearing to the variables that can be accessed across CPUs. Started with Mathieu Desnoyers's patch: Li

Re: [PATCH] tracepoints: Code clean up

2021-02-04 Thread Steven Rostedt
On Thu, 4 Feb 2021 14:13:59 -0500 (EST) Mathieu Desnoyers wrote: > - On Feb 4, 2021, at 1:27 PM, rostedt rost...@goodmis.org wrote: > > > From: "Steven Rostedt (VMware)" > > > > Restructure the code a bit to make it simpler, fix some formatting problem

[PATCH] tracepoints: Do not punish non static call users

2021-02-04 Thread Steven Rostedt
s with static calls, will test on those without later ] Signed-off-by: Steven Rostedt (VMware) --- diff --git a/include/linux/tracepoint.h b/include/linux/tracepoint.h index dc1d4c612cc3..966bfa6a861c 100644 --- a/include/linux/tracepoint.h +++ b/include/linux/tracepoint.h @@ -152,9 +152,18 @@ s

[PATCH] tracepoints: Code clean up

2021-02-04 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" Restructure the code a bit to make it simpler, fix some formatting problems and add READ_ONCE/WRITE_ONCE to make sure there's no compiler tear downs on changes to variables that can be accessed across CPUs. Started with Mathieu Desnoyers's patch: Li

Re: [PATCH 1/1] tracepoint: cleanup: do not fail unregistration

2021-02-04 Thread Steven Rostedt
On Wed, 3 Feb 2021 12:57:41 -0500 Mathieu Desnoyers wrote: > This patch is only compile-tested. > Yes it is. (crashed on boot) > Signed-off-by: Mathieu Desnoyers > --- > include/linux/tracepoint.h | 2 +- > kernel/tracepoint.c| 80 +- > 2 files

Re: [for-next][PATCH 14/15] tracepoint: Do not fail unregistering a probe due to memory failure

2021-02-04 Thread Steven Rostedt
On Wed, 3 Feb 2021 12:57:24 -0500 (EST) Mathieu Desnoyers wrote: > > @@ -147,14 +154,34 @@ func_add(struct tracepoint_func **funcs, struct > > tracepoint_func *tp_func, > > if (old[nr_probes].func == tp_func->func && > > old[nr_probes].data ==

Re: BUG: KASAN: stack-out-of-bounds in unwind_next_frame+0x1df5/0x2650

2021-02-03 Thread Steven Rostedt
On Tue, 2 Feb 2021 19:09:44 -0800 Ivan Babrou wrote: > On Thu, Jan 28, 2021 at 7:35 PM Ivan Babrou wrote: > > > > Hello, > > > > We've noticed the following regression in Linux 5.10 branch: > > > > [ 128.367231][C0] > > == > >

Re: [PATCH][RESEND] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-03 Thread Steven Rostedt
On Wed, 3 Feb 2021 15:56:20 -0600 Timur Tabi wrote: > On 2/3/21 2:47 PM, Steven Rostedt wrote: > > static void __init > > plain(void) > > { > > int err; > > > > + if (debug_never_hash_pointers) > > + return; > >

Re: [PATCH][RESEND] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-03 Thread Steven Rostedt
On Wed, 3 Feb 2021 12:35:07 -0800 Kees Cook wrote: > > With a big notice that all pointers of unhashed, I don't think we need to > > print it failed when we expect it to fail. > > > > If anything, skip the test and state: > > > > test_printf: hash test skipped because

Re: [PATCH][RESEND] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-03 Thread Steven Rostedt
On Wed, 3 Feb 2021 12:02:05 -0800 Kees Cook wrote: > On Wed, Feb 03, 2021 at 12:58:41PM -0600, Timur Tabi wrote: > > On 2/3/21 7:31 AM, Petr Mladek wrote: > > > Also please make sure that lib/test_printf.c will work with > > > the new option. > > > > As you suspected, it doesn't work: > >

Re: [for-next][PATCH 14/15] tracepoint: Do not fail unregistering a probe due to memory failure

2021-02-03 Thread Steven Rostedt
On Wed, 3 Feb 2021 18:09:27 +0100 Peter Zijlstra wrote: > On Wed, Feb 03, 2021 at 11:05:31AM -0500, Steven Rostedt wrote: > > + if (new) { > > + for (i = 0; old[i].func; i++) > > + if ((old[i].

[for-next][PATCH 03/15] tracing: Remove get/put_cpu() from function_trace_init

2021-02-03 Thread Steven Rostedt
Qiujun Huang Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_functions.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel/trace/trace_functions.c b/kernel/trace/trace_functions.c index c5095dd28e20..f67aec5bb771 100644 --- a/kernel/trace/trace_functions.c

[for-next][PATCH 04/15] ring-buffer: Remove cpu_buffer argument from the rb_inc_page()

2021-02-03 Thread Steven Rostedt
ink: https://lkml.kernel.org/r/20201225140356.23008-1-hqjag...@gmail.com Signed-off-by: Qiujun Huang Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/ring_buffer.c | 35 --- 1 file changed, 16 insertions(+), 19 deletions(-) diff --git a/kernel/trace/ring_buffer.c b/ke

[for-next][PATCH 07/15] tracing: Inline tracing_gen_ctx_flags()

2021-02-03 Thread Steven Rostedt
-by: Steven Rostedt Link: https://lkml.kernel.org/r/20210125140323.6b1ff...@gandalf.local.home Signed-off-by: Sebastian Andrzej Siewior Signed-off-by: Steven Rostedt (VMware) --- include/linux/trace_events.h | 54 ++-- kernel/trace/trace.c | 38

[for-next][PATCH 15/15] kernel: trace: preemptirq_delay_test: add cpu affinity

2021-02-03 Thread Steven Rostedt
-by: Steven Rostedt (VMware) --- kernel/trace/Kconfig | 4 kernel/trace/preemptirq_delay_test.c | 14 ++ 2 files changed, 18 insertions(+) diff --git a/kernel/trace/Kconfig b/kernel/trace/Kconfig index 4f976f8d9a38..799dbcfe65ad 100644 --- a/kernel/trace/Kconfig

[for-next][PATCH 14/15] tracepoint: Do not fail unregistering a probe due to memory failure

2021-02-03 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" The list of tracepoint callbacks is managed by an array that is protected by RCU. To update this array, a new array is allocated, the updates are copied over to the new array, and then the list of functions for the tracepoint is switched over to the

[for-next][PATCH 10/15] tracing: Fix spelling mistake in Kconfig "infinit" -> "infinite"

2021-02-03 Thread Steven Rostedt
From: Colin Ian King There is a spelling mistake in the Kconfig help text. Fix it. Link: https://lkml.kernel.org/r/20201216114051.12056-1-colin.k...@canonical.com Signed-off-by: Colin Ian King Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/Kconfig | 2 +- 1 file changed, 1

[for-next][PATCH 09/15] tracing: Remove NULL check from current in tracing_generic_entry_update().

2021-02-03 Thread Steven Rostedt
ent' never returns a NULL pointer and remove the check. Link: https://lkml.kernel.org/r/20210125194511.3924915-5-bige...@linutronix.de Signed-off-by: Sebastian Andrzej Siewior Signed-off-by: Steven Rostedt (VMware) --- include/linux/trace_events.h | 4 +--- 1 file changed, 1 insertion(+), 3 deletion

[for-next][PATCH 13/15] tracing: Remove definition of DEBUG in trace_mmiotrace.c

2021-02-03 Thread Steven Rostedt
From: Tom Rix Defining DEBUG should only be done in development. So remove DEBUG. Link: https://lkml.kernel.org/r/20210115153348.131791-1-t...@redhat.com Signed-off-by: Tom Rix Reviewed-by: Karol Herbst Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_mmiotrace.c | 2 -- 1

[for-next][PATCH 08/15] tracing: Use in_serving_softirq() to deduct softirq status.

2021-02-03 Thread Steven Rostedt
rnel.org/r/20210125194511.3924915-4-bige...@linutronix.de Signed-off-by: Sebastian Andrzej Siewior Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index 584fa2a1304a..75620c29e

[for-next][PATCH 12/15] tracing: Fix a kernel doc warning

2021-02-03 Thread Steven Rostedt
of the original fixes was already fixed by someone else ] Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace.c | 1 + 1 file changed, 1 insertion(+) diff --git a/kernel/trace/trace.c b/kernel/trace/trace.c index 75620c29e904..7fd432334ff5 100644 --- a/kernel/trace/trace.c +++ b/kernel/trace

[for-next][PATCH 11/15] tracing: Fix spelling of controlling in uprobes

2021-02-03 Thread Steven Rostedt
From: Bhaskar Chowdhury s/controling/controlling/p Link: https://lkml.kernel.org/r/20210112045008.29834-1-unixbhas...@gmail.com Signed-off-by: Bhaskar Chowdhury Acked-by: Randy Dunlap Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_uprobe.c | 2 +- 1 file changed, 1 insertion

[for-next][PATCH 05/15] ring-buffer: Drop unneeded check in ring_buffer_resize()

2021-02-03 Thread Steven Rostedt
From: Qiujun Huang Remove the cpumask check, as we has done it at the beginning of the function. Also fix a typo. s/also the on the/also on the/ Link: https://lkml.kernel.org/r/20201224144634.3210-1-hqjag...@gmail.com Signed-off-by: Qiujun Huang Signed-off-by: Steven Rostedt (VMware

[for-next][PATCH 01/15] tracing: Add printf attribute to log function

2021-02-03 Thread Steven Rostedt
From: Tom Rix Attributing the function allows the compiler to more thoroughly check the use of the function with -Wformat and similar flags. Link: https://lkml.kernel.org/r/20201221162715.3757291-1-t...@redhat.com Signed-off-by: Tom Rix Signed-off-by: Steven Rostedt (VMware) --- include

[for-next][PATCH 00/15] tracing: Updates for 5.12

2021-02-03 Thread Steven Rostedt
counter. tracing: Inline tracing_gen_ctx_flags() tracing: Use in_serving_softirq() to deduct softirq status. tracing: Remove NULL check from current in tracing_generic_entry_update(). Song Chen (1): kernel: trace: preemptirq_delay_test: add cpu affinity Ste

[for-next][PATCH 02/15] tracing: Update trace_ignore_this_task() kernel-doc comment

2021-02-03 Thread Steven Rostedt
From: Qiujun Huang Update kernel-doc parameter after commit b3b1e6ededa4 ("ftrace: Create set_ftrace_notrace_pid to not trace tasks") added @filtered_no_pids. Link: https://lkml.kernel.org/r/20201231153558.4804-1-hqjag...@gmail.com Signed-off-by: Qiujun Huang Signed-off-by: Stev

[GIT PULL] tracing: Fixes for 5.11-rc5

2021-02-03 Thread Steven Rostedt
n unloaded modules Steven Rostedt (VMware) (1): fgraph: Initialize tracing_graph_pause at task creation Viktor Rosendahl (1): tracing: Use pause-on-trace with the latency tracers Wang ShaoBo (1): kretprobe: Avoid re-registration of the same kretprobe earlier include/linux

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-02-03 Thread Steven Rostedt
On Wed, 3 Feb 2021 22:33:28 +0900 Masami Hiramatsu wrote: > Ah, that is what I worried about. ftrace and kprobes handler usually want to > know "what is the actual status of the system where the probe hits". > > If the new kernel_exception_enter() for ftrace/kprobes or any other kernel >

Re: [PATCH] lib/vsprintf: make-printk-non-secret printks all addresses as unhashed

2021-02-02 Thread Steven Rostedt
On Tue, 2 Feb 2021 16:19:20 -0600 Timur Tabi wrote: > On 2/2/21 3:52 PM, Kees Cook wrote: > >> A large warning message is displayed if this option is enabled, > >> because unhashed addresses, while useful for debugging, exposes > >> kernel addresses which can be a security risk. > > > Linus

[for-linus][PATCH 3/5] tracing/kprobe: Fix to support kretprobe events on unloaded modules

2021-02-02 Thread Steven Rostedt
Lv Signed-off-by: Masami Hiramatsu Signed-off-by: Steven Rostedt (VMware) --- include/linux/kprobes.h | 2 +- kernel/kprobes.c| 34 +- kernel/trace/trace_kprobe.c | 10 ++ 3 files changed, 32 insertions(+), 14 deletions(-) diff --git a/

[for-linus][PATCH 5/5] tracepoint: Fix race between tracing and removing tracepoint

2021-02-02 Thread Steven Rostedt
tra (Intel) Signed-off-by: Alexey Kardashevskiy Signed-off-by: Steven Rostedt (VMware) --- include/linux/tracepoint.h | 12 +++- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/include/linux/tracepoint.h b/include/linux/tracepoint.h index 0f21617f1a66..966ed8980327 100644 ---

[for-linus][PATCH 4/5] kretprobe: Avoid re-registration of the same kretprobe earlier

2021-02-02 Thread Steven Rostedt
e kprobe") [ The above commit should have been done for kretprobes too ] Acked-by: Naveen N. Rao Acked-by: Ananth N Mavinakayanahalli Acked-by: Masami Hiramatsu Signed-off-by: Wang ShaoBo Signed-off-by: Cheng Jian Signed-off-by: Steven Rostedt (VMware) --- kernel/kprobes.c | 4 1 fi

[for-linus][PATCH 2/5] tracing: Use pause-on-trace with the latency tracers

2021-02-02 Thread Steven Rostedt
e0a548bad0 ("tracing: Do not disable tracing when reading the trace file") Signed-off-by: Viktor Rosendahl Signed-off-by: Steven Rostedt (VMware) --- kernel/trace/trace_irqsoff.c | 4 1 file changed, 4 insertions(+) diff --git a/kernel/trace/trace_irqsoff.c b/kernel/trace/t

[for-linus][PATCH 1/5] fgraph: Initialize tracing_graph_pause at task creation

2021-02-02 Thread Steven Rostedt
From: "Steven Rostedt (VMware)" On some archs, the idle task can call into cpu_suspend(). The cpu_suspend() will disable or pause function graph tracing, as there's some paths in bringing down the CPU that can have issues with its return address being modified. The task_struct str

[for-linus][PATCH 0/5] tracing: Fixes for 5.11-rc5

2021-02-02 Thread Steven Rostedt
to support kretprobe events on unloaded modules Steven Rostedt (VMware) (1): fgraph: Initialize tracing_graph_pause at task creation Viktor Rosendahl (1): tracing: Use pause-on-trace with the latency tracers Wang ShaoBo (1): kretprobe: Avoid re-registration of the same kretpro

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-02-02 Thread Steven Rostedt
On Tue, 2 Feb 2021 19:30:34 +0100 Peter Zijlstra wrote: > That does mean that kprobes are then fundamentally running from > in_nmi(), which is what started all this. I just thought about the fact that tracing records the context of the function it is called in. If you set "in_nmi()" for all

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-02-02 Thread Steven Rostedt
On Tue, 2 Feb 2021 17:45:47 +0100 Peter Zijlstra wrote: > On Tue, Feb 02, 2021 at 09:52:49AM -0500, Steven Rostedt wrote: > > > But from a handler, you could do: > > > > if (in_nmi()) > > return; > > local_irq_save(flags); > >

[ANNOUNCE] 5.4.93-rt51

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

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-02-02 Thread Steven Rostedt
On Tue, 2 Feb 2021 11:45:41 +0100 Peter Zijlstra wrote: > > The stack tracer checks the size of the stack, compares it to the > > largest recorded size, and if it's bigger, it will save the stack. But > > if this happens on two CPUs at the same time, only one can do the > > recording at the same

Re: [PATCH 0/4 v2] tracing: Merge irqflags + preempt counter.

2021-02-01 Thread Steven Rostedt
On Mon, 1 Feb 2021 19:23:45 +0100 Sebastian Andrzej Siewior wrote: > On 2021-01-25 20:45:07 [+0100], To linux-kernel@vger.kernel.org wrote: > > The merge irqflags + preempt counter, v2. > > > > v1…v2: > > - Helper functions renamed. > > - Added patch #2 which inlines the helper functions. > >

Re: [PATCH v5] tracepoint: Do not fail unregistering a probe due to memory failure

2021-02-01 Thread Steven Rostedt
On Mon, 1 Feb 2021 12:18:34 +1100 Alexey Kardashevskiy wrote: > > Just curious, does the following patch fix it for v5? > > > Yes it does! Thanks for verifying. > > > > > > -- Steve > > > > diff --git a/kernel/tracepoint.c b/kernel/tracepoint.c > > index 7261fa0f5e3c..cf3a6d104fdb

Re: [PATCH 3/3] MIPS: ftrace: Add DYNAMIC_FTRACE_WITH_REGS support

2021-02-01 Thread Steven Rostedt
On Sun, 31 Jan 2021 16:14:38 +0800 Jinyang He wrote: > In the past, we have always used the address of _mcount as the address of > ftrace_caller. It reduces one ftrace_modify_code operation when do ftrace > on modules on 64Bit platform in this way. In order to provide > DYNAMIC_FTRACE_WITH_REGS,

Re: [PATCH v5] tracepoint: Do not fail unregistering a probe due to memory failure

2021-01-30 Thread Steven Rostedt
On Sat, 30 Jan 2021 09:36:26 -0500 Steven Rostedt wrote: > Do you still have the same crash with v3 (that's the one I'm going to > go with for now.) > > https://lore.kernel.org/r/20201118093405.7a6d2...@gandalf.local.home Just curious, does the following patch fix it for v5? --

Re: [PATCH v5] tracepoint: Do not fail unregistering a probe due to memory failure

2021-01-30 Thread Steven Rostedt
On Sat, 30 Jan 2021 23:30:18 +1100 Alexey Kardashevskiy wrote: > I still need the following chunk (same "if (it_func_ptr)" as in the v2's > reply) in order to stop crashes: > > And this is on powerpc, correct? Do you still have the same crash with v3 (that's the one I'm going to go with for

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-01-30 Thread Steven Rostedt
On Sat, 30 Jan 2021 09:28:32 +0100 Peter Zijlstra wrote: > On Fri, Jan 29, 2021 at 04:24:54PM -0500, Steven Rostedt wrote: > > Specifically, kprobe and ftrace callbacks may have this: > > > > if (in_nmi()) > > return; > > >

Re: [PATCH] kernel: trace: preemptirq_delay_test: add cpu affinity

2021-01-29 Thread Steven Rostedt
Joel, Can you ack this patch? -- Steve On Thu, 28 Jan 2021 09:35:13 +0800 Song Chen wrote: > The kernel thread executing test can run on any cpu, which might be > different cpu latency tracer is running on, as a result, the > big latency caused by preemptirq delay test can't be detected. >

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-01-29 Thread Steven Rostedt
On Fri, 29 Jan 2021 14:01:03 -0500 Steven Rostedt wrote: > On Fri, 29 Jan 2021 18:59:43 +0100 > Peter Zijlstra wrote: > > > On Fri, Jan 29, 2021 at 09:45:48AM -0800, Alexei Starovoitov wrote: > > > Same things apply to bpf side. We can statically prove safety for

Re: kprobes broken since 0d00449c7a28 ("x86: Replace ist_enter() with nmi_enter()")

2021-01-29 Thread Steven Rostedt
On Fri, 29 Jan 2021 18:59:43 +0100 Peter Zijlstra wrote: > On Fri, Jan 29, 2021 at 09:45:48AM -0800, Alexei Starovoitov wrote: > > Same things apply to bpf side. We can statically prove safety for > > ftrace and kprobe attaching whereas to deal with NMI situation we > > have to use run-time

<    9   10   11   12   13   14   15   16   17   18   >