(2013/10/30 23:03), David Ahern wrote:
> On 10/29/13 11:59 PM, Masami Hiramatsu wrote:
>> (2013/10/29 11:58), David Ahern wrote:
>>> To back out a bit, my end goal is to be able to create and merge
>>> perf-events from any context on a KVM-based host -- guest usersp
x27;t
depends on the arch specific feature. However, since physical timer(clock)
interfaces and virtualization interfaces strongly depends on the arch,
I guess the optimized implementations will become different on each arch.
For example, maybe we can export tsc-offset to the guest to adjust clock
o
(2010/12/16 19:20), Avi Kivity wrote:
> On 12/13/2010 01:20 PM, Masami Hiramatsu wrote:
>> (2010/12/13 2:47), Avi Kivity wrote:
>> > On 12/12/2010 07:43 PM, Arnaldo Carvalho de Melo wrote:
>> >> Em Sun, Dec 12, 2010 at 07:42:06PM +0200, Avi Kivity escreveu:
>
lly, pagefaults could happen on fetching variables. But
fetching argument routines should handle it...
I'd like to check it, could you tell me details? for example, that exception
log,
kprobe-tracer's event definition(you can see it via
debugfs/tracing/kprobe-events)
and the result of `perf probe
;
>
> Joerg
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majord...@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at http://www.tux.or
Frederic Weisbecker wrote:
> On Thu, Aug 13, 2009 at 04:59:19PM -0400, Masami Hiramatsu wrote:
>> This program converts probe point in C expression to kprobe event
>> format for kprobe-based event tracer. This helps to define kprobes
>> events by C source line number or fun
Change trace_arg_string() and parse_trace_arg() to probe_arg_string()
and parse_probe_arg(), since those are kprobe-tracer local functions.
Signed-off-by: Masami Hiramatsu
Cc: Jim Keniston
Cc: H. Peter Anvin
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
$ cat /debug/tracing/events/kprobes/event/format
...
field: unsigned long ip;offset:16; size:8;
field: int nargs; offset:24; size:4;
...
Signed-off-by: Masami Hiramatsu
Cc: Jim Keniston
Cc: H. Peter Anvin
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Check some awk features which old mawk doesn't support.
Signed-off-by: Masami Hiramatsu
Cc: Jim Keniston
Cc: H. Peter Anvin
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jason Baro
Fix x86 instruction decoder selftest to check only .text because other
sections (e.g. .notes) will have random bytes which don't need to be checked.
Signed-off-by: Masami Hiramatsu
Cc: Jim Keniston
Cc: H. Peter Anvin
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Chri
tracing/kprobes
So you can send patches on top of this one.
Great! I've found another trivial bugs, so I'll fix those on it.
Cool :)
Btw, here is the result of your stress test in a PIII (attaching the log
and the config).
Thanks, I'll check that.
Thank you,
--
Mas
Frederic Weisbecker wrote:
On Thu, Aug 13, 2009 at 04:57:20PM -0400, Masami Hiramatsu wrote:
This script tests kprobes to probe on all symbols in the kernel and finds
symbols which must be blacklisted.
Usage
-
kprobestest [-s SYMLIST] [-b BLACKLIST] [-w WHITELIST]
Run stress test
Frederic Weisbecker wrote:
On Thu, Aug 20, 2009 at 12:16:05PM -0400, Masami Hiramatsu wrote:
Frederic Weisbecker wrote:
On Thu, Aug 20, 2009 at 11:03:40AM -0400, Masami Hiramatsu wrote:
Frederic Weisbecker wrote:
On Thu, Aug 20, 2009 at 01:42:31AM +0200, Frederic Weisbecker wrote:
On Thu
Frederic Weisbecker wrote:
On Thu, Aug 20, 2009 at 11:03:40AM -0400, Masami Hiramatsu wrote:
Frederic Weisbecker wrote:
On Thu, Aug 20, 2009 at 01:42:31AM +0200, Frederic Weisbecker wrote:
On Thu, Aug 13, 2009 at 04:34:13PM -0400, Masami Hiramatsu wrote:
Add x86 instruction decoder to arch
Frederic Weisbecker wrote:
On Thu, Aug 20, 2009 at 01:42:31AM +0200, Frederic Weisbecker wrote:
On Thu, Aug 13, 2009 at 04:34:13PM -0400, Masami Hiramatsu wrote:
Add x86 instruction decoder to arch-specific libraries. This decoder
can decode x86 instructions used in kernel into prefix, opcode
Frederic Weisbecker wrote:
On Thu, Aug 13, 2009 at 04:34:13PM -0400, Masami Hiramatsu wrote:
Add x86 instruction decoder to arch-specific libraries. This decoder
can decode x86 instructions used in kernel into prefix, opcode, modrm,
sib, displacement and immediates. This can also show the
Frederic Weisbecker wrote:
> On Thu, Aug 13, 2009 at 04:35:01PM -0400, Masami Hiramatsu wrote:
>> Use TRACE_FIELD_ZERO(type, item) instead of TRACE_FIELD_ZERO_CHAR(item).
>> This also includes a fix of TRACE_ZERO_CHAR() macro.
>
>
> I can't find what the fix is ab
Frederic Weisbecker wrote:
> On Tue, Aug 18, 2009 at 07:17:39PM -0400, Masami Hiramatsu wrote:
>> Frederic Weisbecker wrote:
>>>> + while (addr < paddr) {
>>>> + kernel_insn_init(&insn, (void *)addr);
>>>> + insn_get_o
Frederic Weisbecker wrote:
> On Thu, Aug 13, 2009 at 04:34:28PM -0400, Masami Hiramatsu wrote:
>> Ensure safeness of inserting kprobes by checking whether the specified
>> address is at the first byte of a instruction on x86.
>> This is done by decoding probed function from
tiple probepoints from stdin.
- Better kmodule support.
- Use elfutils-libdw?
- Merge into trace-cmd or perf-tools?
--
Masami Hiramatsu
Software Engineer
Hitachi Computer Products (America), Inc.
Software Solutions Division
e-mail: mhira...@redhat.com
/*
* c2kpe : C expression to kprobe even
- This script just gives us some clues to the blacklisted functions.
In some cases, a combination of probe points will cause a problem, but
each of them doesn't cause the problem alone.
Thank you,
--
Masami Hiramatsu
Software Engineer
Hitachi Computer Products (America), Inc.
S
Ensure safeness of inserting kprobes by checking whether the specified
address is at the first byte of a instruction on x86.
This is done by decoding probed function from its head to the probe point.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi
the kernel stack.
- regs_get_kernel_stack_nth(struct pt_regs *reg, unsigned int nth)
Get Nth entry of the kernel stack. (N >= 0)
- regs_get_argument_nth(struct pt_regs *reg, unsigned int nth)
Get Nth argument at function call. (N >= 0)
Signed-off-by: Masami Hiramatsu
Reviewed-by: Fre
Assigns new event ids for each kprobes event. This doesn't clear ring_buffer
when unregistering each kprobe event. Thus, if you mind 'Unknown event'
messages, clear the buffer manually after changing kprobe events.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Support up to 128 arguments for each kprobes event.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: H. Peter Anvin
Cc: Ingo Molnar
Cc: Jason Baron
Cc: Jim Keniston
Cc
ss.
- Use call->data instead of container_of() macro.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: H. Peter Anvin
Cc: Ingo Molnar
Cc: Jason Baron
Cc: Jim Kenisto
Add profiling interaces for each kprobes event. This interface provides
how many times each probe hit or missed.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: H. Peter
Generate names for each kprobe event based on the probe point,
and remove generic k*probe event types because there is no user
of those types.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic
Use TRACE_FIELD_ZERO(type, item) instead of TRACE_FIELD_ZERO_CHAR(item).
This also includes a fix of TRACE_ZERO_CHAR() macro.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc
:
- Define remove_subsystem_dir() always (revirt a2ca5e03), because
trace_remove_event_call() uses it.
- Modify syscall tracer because of ftrace_event_call change.
Signed-off-by: Masami Hiramatsu
Acked-by: Frederic Weisbecker
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc
Cleanup fix_riprel() in arch/x86/kernel/kprobes.c by using x86 instruction
decoder.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: H. Peter Anvin
Cc: Ingo Molnar
Cc: Jason
hows when the kernel hits a probe, and <- SYMBOL means kernel
returns from SYMBOL(e.g. "sys_open+0x1b/0x1d <- do_sys_open" means kernel
returns from do_sys_open to sys_open+0x1b).
Thank you,
---
Masami Hiramatsu (12):
tracing: Add kprobes event profiling interface
trac
: Masami Hiramatsu
Signed-off-by: Jim Keniston
Acked-by: H. Peter Anvin
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: Ingo Molnar
Cc: Jason Baron
Cc: K.Prasad
Cc: Lai Jiangshan
Cc: Li Zefan
Cc: Przemysław
are no differences.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: Ananth N Mavinakayanahalli
Cc: Avi Kivity
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Frank Ch. Eigler
Cc: Frederic Weisbecker
Cc: H. Peter Anvin
Cc: Ingo Molnar
Cc: Jason Baron
Cc: K.Prasad
Cc: Lai
are no differences.
Changes from v12:
- Remove user_include.h.
- Use $(OBJDUMP) instead of native objdump.
- Use hostprogs-y and include insn.c and inat.c directly from test_gen_insn.c.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: Sam Ravnborg
Cc: H. Peter Anvin
Cc: Steven
:
- Use arch/x86/tools dir instead of arch/x86/scripts.
- Remove all EXPORT_SYMBOL_GPL() and linux/module.h.
- Replace all types defined in linux/types.h.
- Use inline functions instead of macros.
- Add VIA's RNG/ACE instructions.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Ken
Add profiling interaces for each kprobes event. This interface provides
how many times each probe hit or missed.
Changes from v12:
- Reformat profile data.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic
rch/x86/lib/inat.c
create mode 100644 arch/x86/lib/insn.c
create mode 100644 arch/x86/lib/x86-opcode-map.txt
create mode 100644 arch/x86/tools/Makefile
create mode 100644 arch/x86/tools/distill.awk
create mode 100644 arch/x86/tools/gen-insn-attr-x86.awk
create mode 100644 arch/x86/tools/test_get_len.
Generate names for each kprobe event based on the probe point,
and remove generic k*probe event types because there is no user
of those types.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc
vent Tracer
+ =
+
+ Documentation is written by Masami Hiramatsu
+
+
+Overview
+
+This tracer is similar to the events tracer which is based on Tracepoint
+infrastructure. Instead of Tracepoint, this tracer is based on kprobes(kprobe
+an
Support up to 128 arguments for each kprobes event.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Tom Zanussi
---
Documentation/trace/kprobetrace.txt |2 +-
kernel/trace
the kernel stack.
- regs_get_kernel_stack_nth(struct pt_regs *reg, unsigned int nth)
Get Nth entry of the kernel stack. (N >= 0)
- regs_get_argument_nth(struct pt_regs *reg, unsigned int nth)
Get Nth argument at function call. (N >= 0)
Signed-off-by: Masami Hiramatsu
Reviewed-by: Fre
: Masami Hiramatsu
Acked-by: Frederic Weisbecker
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
---
include/linux/ftrace_event.h | 13 +---
include/trace/ftrace.h | 22 ++---
kernel/trace/trace_events.c | 72 --
kernel/trace
Use TRACE_FIELD_ZERO(type, item) instead of TRACE_FIELD_ZERO_CHAR(item).
This also includes a fix of TRACE_ZERO_CHAR() macro.
Signed-off-by: Masami Hiramatsu
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
Cc: Frederic Weisbecker
---
kernel/trace/trace_event_types.h |4 ++--
kernel
Cleanup fix_riprel() in arch/x86/kernel/kprobes.c by using x86 instruction
decoder.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo Molnar
---
arch/x86/kernel/kprobes.c | 128 -
1 files changed, 23
Ensure safeness of inserting kprobes by checking whether the specified
address is at the first byte of a instruction on x86.
This is done by decoding probed function from its head to the probe point.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo
Sam Ravnborg wrote:
> On Thu, Jul 16, 2009 at 01:28:54PM -0400, Masami Hiramatsu wrote:
>> Sam Ravnborg wrote:
>>>> diff --git a/arch/x86/include/asm/inat.h b/arch/x86/include/asm/inat.h
>>>> new file mode 100644
>>>> index 000..01e079a
>>>
st is little-endian?
> If it does then it would fail on a power-pc target despite using the
> correct objdump.
Hmm, as far as I can see, the result of get_next() macro with the types
more than two bytes(s16, s32...) might be effected.
But it doesn't effect get_insn_len test because those
Masami Hiramatsu wrote:
>> You are using the native objdump here.
>> But I assume this fails miserably when you build x86 on a powerpc host.
>> In other words - you broke an allyesconfig build for -next...
>> We have $(OBJDUMP) for this.
>
> Ah, I see... Would you k
Sam Ravnborg wrote:
> On Thu, Jul 16, 2009 at 11:57:06AM -0400, Masami Hiramatsu wrote:
>> Add a user-space selftest of x86 instruction decoder at kernel build time.
>> When CONFIG_X86_DECODER_SELFTEST=y, Kbuild builds a test harness of x86
>> instruction decoder and perfo
?
Thank you,
>
> Same for the other files that requred the types.h hack.
>
> Sam
>
--
Masami Hiramatsu
Software Engineer
Hitachi Computer Products (America), Inc.
Software Solutions Division
e-mail: mhira...@redhat.com
--
To unsubscribe from this list: send the line "unsub
On 2009年07月16日 12:19, H. Peter Anvin wrote:
> Masami Hiramatsu wrote:
>>
>> These opcode maps do NOT include most of SSE and FP opcodes, because
>> those opcodes are not used in the kernel.
>>
>
> That is not true.
Ah, these opcode maps include some SSE/FP s
Ensure safeness of inserting kprobes by checking whether the specified
address is at the first byte of a instruction on x86.
This is done by decoding probed function from its head to the probe point.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo
cess string bug in trace_arg_string().
- Remove redundant checks.
- Fix buffer overflow in probes_write().
- Fix probes_write() to support inputs ended without a new-line.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo
are no differences.
Changes from v10:
- Use "unsigned int" instead of "unsigned".
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbe
Add profiling interaces for each kprobes event.
Changes from v11:
- Fix a typo and remove redundant check.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Tom Zanussi
Cc: Li Zefan
Each line shows when the kernel hits a probe, and <- SYMBOL means kernel
returns from SYMBOL(e.g. "sys_open+0x1b/0x1d <- do_sys_open" means kernel
returns from do_sys_open to sys_open+0x1b).
Thank you,
---
Masami Hiramatsu (11):
tracing: Add kprobes event profiling i
Generate names for each kprobe event based on the probe point,
and remove generic k*probe event types because there is no user
of those types.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc
Support up to 128 arguments for each kprobes event.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Tom Zanussi
---
Documentation/trace/kprobetrace.txt |2 +-
kernel/trace
get_argument_nth().
- Use "unsigned int" instead of "unsigned".
Signed-off-by: Masami Hiramatsu
Reviewed-by: Frederic Weisbecker
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Rolan
: Masami Hiramatsu
Signed-off-by: Jim Keniston
Acked-by: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Andi Kleen
Cc: Vegard Nossum
Cc: Avi Kivity
Cc: Przemysław Pawełczyk
---
arch/x86/include/asm/inat.h
Use TRACE_FIELD_ZERO(type, item) instead of TRACE_FIELD_ZERO_CHAR(item).
This also includes a fix of TRACE_ZERO_CHAR() macro.
Signed-off-by: Masami Hiramatsu
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
Cc: Frederic Weisbecker
---
kernel/trace/trace_event_types.h |4 ++--
kernel
:
- Call remove_subsystem_dir() when unregistering an event call.
Signed-off-by: Masami Hiramatsu
Acked-by: Frederic Weisbecker
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
---
include/linux/ftrace_event.h | 13 +---
include/trace/ftrace.h | 22 ++---
kernel
Cleanup fix_riprel() in arch/x86/kernel/kprobes.c by using x86 instruction
decoder.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo Molnar
---
arch/x86/kernel/kprobes.c | 128 -
1 files changed, 23
t; +if (!trace_seq_puts(s, " <- "))
>> +goto partial;
>> +
>> +if (!seq_print_ip_sym(s, field->func, flags & ~TRACE_ITER_SYM_OFFSET))
>> + goto partial;
>> +
>
> and $pf?
>
>> +if (!trace_seq_puts(
gt;> +if (tp == NULL)
>> +return 0;
>> +
>
> tp will never be NULL, which is guaranteed by seq_file
OK, fixed.
>> +seq_printf(m, "%s", tp->call.name);
>> +
>> +seq_printf(m, "\t%8lu %8lu\n", tp->nhits,
>
Support up to 128 arguments for each kprobes event.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Tom Zanussi
---
Documentation/trace/kprobetrace.txt |2 +-
kernel/trace
n the kernel hits a probe, and <- SYMBOL means kernel
returns from SYMBOL(e.g. "sys_open+0x1b/0x1d <- do_sys_open" means kernel
returns from do_sys_open to sys_open+0x1b).
Thank you,
---
Masami Hiramatsu (11):
tracing: Add kprobes event profiling interface
tracing
Add profiling interaces for each kprobes event.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Tom Zanussi
---
Documentation/trace/kprobetrace.txt |8 ++
kernel/trace
- Make kprobe_trace_entry and kretprobe_trace_entry variable array.
- Use TRACE_FIELD_ZERO()
- Rename the document to kprobetrace.txt.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Tom Zan
Generate names for each kprobe event based on the probe point,
and remove generic k*probe event types because there is no user
of those types.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc
are no differences.
Changes from v10:
- Use "unsigned int" instead of "unsigned".
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbe
get_argument_nth().
- Use "unsigned int" instead of "unsigned".
Signed-off-by: Masami Hiramatsu
Reviewed-by: Frederic Weisbecker
Cc: Andi Kleen
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Rolan
Use TRACE_FIELD_ZERO(type, item) instead of TRACE_FIELD_ZERO_CHAR(item).
This also includes a fix of TRACE_ZERO_CHAR() macro.
Signed-off-by: Masami Hiramatsu
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
Cc: Frederic Weisbecker
---
kernel/trace/trace_event_types.h |4 ++--
kernel
: Masami Hiramatsu
Signed-off-by: Jim Keniston
Acked-by: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Andi Kleen
Cc: Vegard Nossum
Cc: Avi Kivity
Cc: Przemysław Pawełczyk
---
arch/x86/include/asm/inat.h
Cleanup fix_riprel() in arch/x86/kernel/kprobes.c by using x86 instruction
decoder.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo Molnar
---
arch/x86/kernel/kprobes.c | 128 -
1 files changed, 23
: Masami Hiramatsu
Acked-by: Frederic Weisbecker
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
---
include/linux/ftrace_event.h | 13 +---
include/trace/ftrace.h | 22 +++--
kernel/trace/trace_events.c | 70 --
kernel/trace
Ensure safeness of inserting kprobes by checking whether the specified
address is at the first byte of a instruction on x86.
This is done by decoding probed function from its head to the probe point.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo
Masami Hiramatsu wrote:
> Frederic Weisbecker wrote:
>> On Tue, Jul 07, 2009 at 05:31:25PM -0400, Masami Hiramatsu wrote:
>>> Frederic Weisbecker wrote:
>>>> On Tue, Jul 07, 2009 at 04:42:32PM -0400, Masami Hiramatsu wrote:
>>>>> Frederic Weisbecker wro
Frederic Weisbecker wrote:
> On Tue, Jul 07, 2009 at 05:31:25PM -0400, Masami Hiramatsu wrote:
>> Frederic Weisbecker wrote:
>>> On Tue, Jul 07, 2009 at 04:42:32PM -0400, Masami Hiramatsu wrote:
>>>> Frederic Weisbecker wrote:
>>>>> On Tue, Jul 07, 200
Frederic Weisbecker wrote:
> On Tue, Jul 07, 2009 at 04:42:32PM -0400, Masami Hiramatsu wrote:
>> Frederic Weisbecker wrote:
>>> On Tue, Jul 07, 2009 at 03:55:28PM -0400, Masami Hiramatsu wrote:
>>>> Frederic Weisbecker wrote:
>>>>>> diff --g
Frederic Weisbecker wrote:
> On Tue, Jul 07, 2009 at 03:55:28PM -0400, Masami Hiramatsu wrote:
>> Frederic Weisbecker wrote:
>>>> diff --git a/kernel/trace/trace.h b/kernel/trace/trace.h
>>>> index 206cb7d..65945eb 100644
>>>> --- a/kernel/
, func)
>> +TRACE_FIELD(unsigned long, ret_ip, ret_ip)
>> +TRACE_FIELD(int, nargs, nargs)
>> +TRACE_FIELD_SPECIAL(unsigned long args[TRACE_KPROBE_ARGS],
>> +args, TRACE_KPROBE_ARGS, args)
>> +
Andi Kleen wrote:
> On Mon, Jul 06, 2009 at 03:28:02PM -0400, Masami Hiramatsu wrote:
>> I'm not so sure about your idea.
>> Would you mean below code?
>>
>> int offs_table[NR_REGPARMS] = {
>
> not REGPARMS of course
>
>> [0] = offsetof(
Andi Kleen wrote:
> Masami Hiramatsu writes:
>
>> Add following APIs for accessing registers and stack entries from pt_regs.
>
> You forgot to state who calls these functions/why are they added?
> Who only has strings for registers?
Oh, yes. This patch is needed for kprob
argument. (N >= 0)
rv: Fetch return value.
ra: Fetch return address.
+|-offs(FETCHARG) : fetch memory at FETCHARG +|- offs address.
See Documentation/trace/kprobes.txt for details.
Changes from v9:
- Select CONFIG_GENERIC_TRACER when CONFIG_KPROBE_TRACER=y.
Signed-off-by: Masam
: Masami Hiramatsu
Signed-off-by: Jim Keniston
Acked-by: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Andi Kleen
Cc: Vegard Nossum
Cc: Avi Kivity
Cc: Przemysław Pawełczyk
---
arch/x86/include/asm/inat.h
Each line shows when the kernel hits a probe, and <- SYMBOL means kernel
returns from SYMBOL(e.g. "sys_open+0x1b/0x1d <- do_sys_open" means kernel
returns from do_sys_open to sys_open+0x1b).
Thank you,
---
Masami Hiramatsu (7):
tracing: add kprobe-based event tracer
Cleanup fix_riprel() in arch/x86/kernel/kprobes.c by using x86 instruction
decoder.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo Molnar
---
arch/x86/kernel/kprobes.c | 128 -
1 files changed, 23
Ensure safeness of inserting kprobes by checking whether the specified
address is at the first byte of a instruction on x86.
This is done by decoding probed function from its head to the probe point.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo
: Masami Hiramatsu
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
Cc: Frederic Weisbecker
---
include/linux/ftrace_event.h | 13 +---
include/trace/ftrace.h | 22 +++--
kernel/trace/trace_events.c | 70 --
kernel/trace
k. (N >= 0)
- regs_get_argument_nth(struct pt_regs *reg, unsigned nth)
Get Nth argument at function call. (N >= 0)
Changes from v9:
-Fix a typo in a comment.
Signed-off-by: Masami Hiramatsu
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Ingo Molnar
Cc: Frederic Weisbe
are no differences.
Signed-off-by: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Andi Kleen
Cc: Vegard Nossum
Cc: Avi Kivity
Cc: Przemysław Pawełczyk
Cc
Cleanup fix_riprel() in arch/x86/kernel/kprobes.c by using x86 instruction
decoder.
Signed-off-by: Masami Hiramatsu
Cc: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo Molnar
---
arch/x86/kernel/kprobes.c | 128 -
1 files changed, 23
: Masami Hiramatsu
Cc: Steven Rostedt
Cc: Ingo Molnar
Cc: Tom Zanussi
Cc: Frederic Weisbecker
---
include/linux/ftrace_event.h | 13 +---
include/trace/ftrace.h | 22 +++--
kernel/trace/trace_events.c | 70 --
kernel/trace
x4041c6 0x98800 0x10
<...>-1447 [001] 1038282.286976: sys_open+0x1b/0x1d <- do_sys_open:
0x3 0x81367a3a
Each line shows when the kernel hits a probe, and <- SYMBOL means kernel
returns from SYMBOL(e.g. "sys_open+0x1b/0x1d <- do_sys_open" means kernel
r
argument. (N >= 0)
rv: Fetch return value.
ra: Fetch return address.
+|-offs(FETCHARG) : fetch memory at FETCHARG +|- offs address.
See Documentation/trace/kprobes.txt for details.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Christoph Hellwig
: Masami Hiramatsu
Signed-off-by: Jim Keniston
Cc: H. Peter Anvin
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Srikar Dronamraju
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Andi Kleen
Cc: Vegard Nossum
Cc: Avi Kivity
Cc: Przemysław Pawełczyk
---
arch/x86/include/asm/inat.h
k. (N >= 0)
- regs_get_argument_nth(struct pt_regs *reg, unsigned nth)
Get Nth argument at function call. (N >= 0)
Signed-off-by: Masami Hiramatsu
Cc: Christoph Hellwig
Cc: Steven Rostedt
Cc: Ananth N Mavinakayanahalli
Cc: Ingo Molnar
Cc: Frederic Weisbecker
Cc: Roland McGrath
Cc: linux-a...
Ensure safeness of inserting kprobes by checking whether the specified
address is at the first byte of a instruction on x86.
This is done by decoding probed function from its head to the probe point.
Signed-off-by: Masami Hiramatsu
Acked-by: Ananth N Mavinakayanahalli
Cc: Jim Keniston
Cc: Ingo
1 - 100 of 183 matches
Mail list logo