Hello Andrew,
On Sat, Aug 24, 2019 at 04:58:29PM -0700, Andrew Morton wrote:
> (cc printk maintainers).
Ah, I wasn't aware there is something like them. Thanks
> On Sun, 25 Aug 2019 01:37:23 +0200 Uwe Kleine-König
> wrote:
>
> > pr_info("probing failed (%dE)\n", ret);
> >
> > expands to
This series introduces a new ftrace feature CONFIG_FTRACE_FUNC_PROTOTYPE to
record function parameters and return value. It can be enabled/disabled at
runtime by a new trace option "record-funcproto".
To achieve this, we need the function prototype infomation and the location of
parameters. A new
Move ftrace tools to its own directory. We will add another tool later.
Cc: John F. Reiser
Signed-off-by: Changbin Du
---
scripts/.gitignore | 1 -
scripts/Makefile | 2 +-
scripts/Makefile.build | 10 +-
scripts/ftrace/.gitignore
This is a new ftrace tool to implement CONFIG_FTRACE_FUNC_PROTOTYPE
feature which allow ftrace record function parameters and return value
(see later patches).
Essentially funcprototype extracts only necessary information from
the DWARF debug sections in the ELF object file, including function
ret
When CONFIG_FTRACE_FUNC_PROTOTYPE is enabled, thousands of
ftrace_func_entry instances are created. So create a dedicated
memcache to enhance performance.
Signed-off-by: Changbin Du
---
kernel/trace/ftrace.c | 17 -
1 file changed, 16 insertions(+), 1 deletion(-)
diff --git a/ke
We will reuse ftrace_hash to lookup function prototype information. So
we need an additional field to bind ftrace_func_entry to prototype
information.
Signed-off-by: Changbin Du
---
kernel/trace/ftrace.c | 17 +++--
kernel/trace/trace.h | 6 ++
2 files changed, 13 insertions(+)
Add generic DWARF constant definitions. We will use it later.
Signed-off-by: Changbin Du
---
include/asm-generic/dwarf.h | 199
1 file changed, 199 insertions(+)
create mode 100644 include/asm-generic/dwarf.h
diff --git a/include/asm-generic/dwarf.h b/inclu
Walk through the '__funcproto' section in vmlinux and kernel modules.
For each item we add it to a new ftrace hash table ftrace_prototype_hash.
When unloading a module, its items are removed from hash table.
Signed-off-by: Changbin Du
---
include/asm-generic/vmlinux.lds.h | 18
include/
This patch implements the arch_fgraph_record_params() function for x86_64
platform and deliver the return value of function to ftrace core part.
Signed-off-by: Changbin Du
---
arch/x86/Kconfig| 1 +
arch/x86/kernel/ftrace.c| 84 +++--
arch/x86/ker
This patch introduces the core part of our new CONFIG_FTRACE_FUNC_PROTOTYPE
feature. For arch which supports this feature must implement a new
arch-specific interface arch_fgraph_record_params().
In this patch, we add a new trace option "record-funcproto", and by now
only function graph tracer is
Just add the doc for our new feature.
Signed-off-by: Changbin Du
---
Documentation/trace/ftrace.rst | 6 ++
1 file changed, 6 insertions(+)
diff --git a/Documentation/trace/ftrace.rst b/Documentation/trace/ftrace.rst
index f60079259669..c68fbbedb8bd 100644
--- a/Documentation/trace/ftrace.r
To record function parameter and return value, we need the arch specific
code to pass the saved register context. It is only valid if the
CONFIG_FTRACE_FUNC_PROTOTYPE feature is enabled. This patch only changes
the interfaces, real implementation will be added later.
Signed-off-by: Changbin Du
--
Make scripts/ftrace/ maintained and I would like to help with reviewing
related patches.
Signed-off-by: Changbin Du
---
MAINTAINERS | 2 ++
1 file changed, 2 insertions(+)
diff --git a/MAINTAINERS b/MAINTAINERS
index 9cbcf167bdd0..ca012ea260d7 100644
--- a/MAINTAINERS
+++ b/MAINTAINERS
@@ -1629
On Sat, 24 Aug 2019 19:09:30 -0400
"Theodore Y. Ts'o" wrote:
> If you haven't pushed out your doc tree, can you please drop it? I've
> already applied an (improved) version of this patch to the ext4 tree,
> and I actually have some plans to do further fixups of ext4 on-disk
> format documentatio
Add /proc/sup_cmdline which shows the list of key-value pairs
in SKC data. Since after boot, all SKC data and tree are
removed, this interface just keep a copy of key-value
pairs in text.
Signed-off-by: Masami Hiramatsu
---
MAINTAINERS |1
fs/proc/Makefile |1
fs/proc/su
Supplemental kernel command line (SKC) allows admin to pass a
tree-structured supplemental kernel commandline file (SKC file)
when boot up kernel. This expands the kernel command line in
efficient way.
SKC file will contain some key-value commands, e.g.
key.word = value1;
another.key.word = value
Add a documentation for supplemental kernel cmdline under
admin-guide, since it is including the syntax of SKC file.
Signed-off-by: Masami Hiramatsu
---
Documentation/admin-guide/index.rst |1
Documentation/admin-guide/kernel-parameters.txt |1
Documentation/admin-guide/skc
Add a boot setup routine from cmdline option "skc=ADDR,SIZE".
Bootloader has to setup this cmdline option when it loads
the skc file on memory. The ADDR must be a physical address.
Signed-off-by: Masami Hiramatsu
---
Documentation/admin-guide/kernel-parameters.txt |5 ++
init/main.c
Hello,
This is the 3rd version of RFC series for the boot-time tracing.
Previous thread is here.
https://lkml.kernel.org/r/156316746861.23477.5815110570539190650.stgit@devnote2
On that thread and offline talk with Frank Rowand at OSS Japan2019
last month, we agreed that the devicetree is only f
Apply soft-disabled and the filter rule of the trace events to
the printk output of tracepoints (a.k.a. tp_printk kernel parameter)
as same as trace buffer output.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace.c |7 +++
1 file changed, 7 insertions(+)
diff --git a/kernel/trace/
Since kprobe-events use event_trigger_unlock_commit_regs() directly,
that events doesn't show up in printk buffer if "tp_printk" is set.
Use trace_event_buffer_commit() in kprobe events so that it can
invoke output_printk() as same as other trace events.
Signed-off-by: Masami Hiramatsu
---
incl
Since ftrace_set_clr_event is already exported by EXPORT_SYMBOL_GPL,
it should not be static.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace_events.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/trace/trace_events.c b/kernel/trace/trace_events.c
index 22c
Register kprobe event to dynevent in subsys_initcall level.
This will allow kernel to register new kprobe events in
fs_initcall level via trace_run_command.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace_kprobe.c | 19 +++
1 file changed, 15 insertions(+), 4 deletions(-
Make the synthetic event accepts a different type field to record.
However, the size and signed flag must be same.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace_events_hist.c |7 +--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/kernel/trace/trace_events_hist.c b
Add NULL trace-array check in print_synth_event(), because
if we enable tp_printk option, iter->tr can be NULL.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace_events_hist.c |2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/kernel/trace/trace_events_hist.c b/kernel/tr
Setup tracing options by supplemental kernel cmdline (skc) in addition
to kernel parameters. In this patch, add following commands support
- ftrace.options = OPT1[,OPT2...];
Enable given ftrace options.
- ftrace.trace_clock = CLOCK;
Set given CLOCK to ftrace's trace_clock.
- ftrace.dump
Add kprobe event support on event node. If the group name of event
is "kprobes", boottime trace defines new probe event according
to "probes" values.
- ftrace.event.kprobes.EVENT.probes = PROBE[, PROBE2...];
Defines new kprobe event based on PROBEs. It is able to define
multiple probes on o
Add synthetic event node support. The synthetic event is a kind of
event node, but the group name is "synthetic".
- ftrace.event.synthetic.EVENT.fields = FIELD[, FIELD2...];
Defines new synthetic event with FIELDs. Each field should be
"type varname".
The synthetic node requires "fields" s
Add per-event settings for boottime tracing. User can set filter,
actions and enable on each event on boot. The event entries are
under ftrace.event.GROUP.EVENT node (note that the option key
includes event's group name and event name.) This supports below
commands.
- ftrace.event.GROUP.EVENT.ena
Add instance node support to boottime tracing. User can set
some options and event nodes under instance node.
- ftrace.instance.INSTANCE[...];
Add new INSTANCE instance. Some options and event nodes
are acceptable for instance node.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace_
Add ftrace.cpumask option support for setting trace
cpumask.
- ftrace.[instance.INSTANCE.]cpumask = CPUMASK;
Set the trace cpumask. Note that the CPUMASK should be a string
which /tracing_cpumask can accepts.
Signed-off-by: Masami Hiramatsu
---
kernel/trace/trace.c | 41 ++
Add below function-tracer filter options to boottime tracer.
- ftrace.[instance.INSTANCE.]ftrace.filters
This will take an array of tracing function filter rules
- ftrace.[instance.INSTANCE.]ftrace.notraces
This will take an array of NON-tracing function filter rules
Signed-off-by: Masam
Add a documentation about boot-time tracing options for
SKC file.
Signed-off-by: Masami Hiramatsu
---
Documentation/trace/boottime-trace.rst | 185
1 file changed, 185 insertions(+)
create mode 100644 Documentation/trace/boottime-trace.rst
diff --git a/Documen
Add following function-graph tracer related options
- ftrace.fgraph.filters = FILTER[, FILTER2...];
Add fgraph tracing function filters.
- ftrace.fgraph.notraces = FILTER[, FILTER2...];
Add fgraph non tracing function filters.
- ftrace.fgraph.max_depth = MAX_DEPTH;
Set MAX_DEPTH to m
On (08/24/19 16:58), Andrew Morton wrote:
> On Sun, 25 Aug 2019 01:37:23 +0200 Uwe Kleine-König
> wrote:
>
> > pr_info("probing failed (%dE)\n", ret);
> >
> > expands to
> >
> > probing failed (EIO)
> >
> > if ret holds -EIO (or EIO). This introduces an array of error codes. If
> > th
35 matches
Mail list logo