Re: Djprobes questions

2007-03-12 Thread Masami Hiramatsu
to release djprobe patch against latest kernel after developed it. Best regards, -- Masami HIRAMATSU Linux Technology Center Hitachi, Ltd., Systems Development Laboratory E-mail: [EMAIL PROTECTED] - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message

[RFC][Patch 1/4] kprobe fast unregistration

2007-03-23 Thread Masami Hiramatsu
(p); } commit_kprobes(); -- Best regards, Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- This patch introduces unregister_kprobe_fast() and commit_kprobes(). arch/i386/kernel/kprobes.c|2 arch/ia64/kernel/kprobes.c|2 arch/powerpc/kernel/kprobes.c |2 arch/s390/kernel

[RFC][Patch 2/4] kretprobe fast unregisteration

2007-03-23 Thread Masami Hiramatsu
This patch introduces unregister_kretprobe_fast() for kretprobe. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- include/linux/kprobes.h | 12 +++- kernel/kprobes.c| 44 2 files changed, 39 insertions(+), 17 deletions

[RFC][Patch 3/4] jprobe fast unregisteration

2007-03-23 Thread Masami Hiramatsu
This patch introduces unregister_jprobe_fast() for jprobe. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- This patch introduces unregister_jprobe_fast() for jprobe. include/linux/kprobes.h | 12 +++- kernel/kprobes.c|6 -- 2 files changed, 11 insertions(+), 7

[RFC][Patch 4/4] kprobes fast unregisteration documentation

2007-03-23 Thread Masami Hiramatsu
This patch adds the description of the fast unregisteration interfaces. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- Documentation/kprobes.txt | 30 ++ 1 file changed, 30 insertions(+) Index: linux-2.6.21-rc4-mm1/Documentation/kprobes.txt

Re: [RFC][Patch 1/4] kprobe fast unregistration

2007-03-25 Thread Masami Hiramatsu
(); ^^ Change this to unregister_disabled_kprobes(), which essentially unregisters all the disabled probes. And also, I'd like to change it to unregister_prepared_kprobes(). What would you think about this idea? Thanks, Thanks, Anil Keshavamurthy -- Masami HIRAMATSU Linux

Re: [RFC][Patch 1/4] kprobe fast unregistration

2007-03-26 Thread Masami Hiramatsu
Hi Anil, Keshavamurthy, Anil S wrote: On Mon, Mar 26, 2007 at 12:17:49PM +0900, Masami Hiramatsu wrote: Hi Christoph and Anil, Thank you for your comments. Christoph Hellwig wrote: Speeding up the unregistration is a very good idea, but this interface is rather horrible. It's almost

Re: [PATCHv2] kprobes: Introduce is_kprobe_fault()

2008-01-08 Thread Masami Hiramatsu
-by: Masami Hiramatsu [EMAIL PROTECTED] -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message

Re: [PATCH 2/2] kprobe: remove preempt_enable/disable from kprobe_handle_fault()

2008-01-09 Thread Masami Hiramatsu
explicitly for preemption and bail out before hitting kprobe_running(). Signed-off-by: Harvey Harrison [EMAIL PROTECTED] Tested on x86-64. Acked-by: Masami Hiramatsu [EMAIL PROTECTED] Thank you! -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions

Re: [PATCH 1/2] kprobes: Introduce kprobe_handle_fault()

2008-01-09 Thread Masami Hiramatsu
tested it on x86-64. Acked-by: Masami Hiramatsu [EMAIL PROTECTED] Thank you! -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from this list: send the line unsubscribe linux

Re: [PATCH] x86: trivial whitespace in kprobes.c

2008-01-10 Thread Masami Hiramatsu
Harvey Harrison wrote: Signed-off-by: Harvey Harrison [EMAIL PROTECTED] Acked-by: Masami Hiramatsu [EMAIL PROTECTED] --- Ingo, you could/should probably fold this into Masami's kprobe unification patch. The original code had these whitespace, because (I think) kretprobe_trampoline_holder

Re: [PATCH] x86: trivial whitespace in kprobes.c

2008-01-10 Thread Masami Hiramatsu
Masami Hiramatsu wrote: Harvey Harrison wrote: Signed-off-by: Harvey Harrison [EMAIL PROTECTED] Acked-by: Masami Hiramatsu [EMAIL PROTECTED] --- Ingo, you could/should probably fold this into Masami's kprobe unification patch. The original code had these whitespace, because (I think

Re: [patch] prepare kprobes code for x86 unification

2007-11-12 Thread Masami Hiramatsu
that annotation and users must take care of it. By the way, I'm porting boosters to x86-64 (and ia64). Since some parts of that will be covered by this patch, I'd like to know your unification plan. Best regards, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software

Re: FInal kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
? Ingo -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/ -- Masami Hiramatsu Software Engineer Hitachi

Re: [PATCH] x86: Unify cosmetic kprobes{32|64}.c

2007-12-17 Thread Masami Hiramatsu
-thread.debugctlmsr); +#endif } I think you can use wrmsr() on X86_64 too. So, we can merge it to wrmsr(). -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from this list: send

Re: Final kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
Hi Ingo, Ingo Molnar wrote: Masami, * Masami Hiramatsu [EMAIL PROTECTED] wrote: Hi Harvey and Ingo, I'm working on another version of patches for unification. Currently cleaning up the patches. http://sources.redhat.com/ml/systemtap/2007-q4/msg00457.html I'll cleanup and repost

[-mm][PATCH 0/6] (yet another) kprobes x86 code unification and boosters

2007-12-17 Thread Masami Hiramatsu
-booster and kretprobe-booster for x86-64[3/6, 4/6]. (x86-32 kprobes already has same functionalities) 3. Prepare unification[5/6]. 4. Unify kprobes code[6/6]. If you have any comment, please let me know. Best Regards, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America

[-mm][PATCH 2/6] kprobes bugfix and cleanup resume_execution

2007-12-17 Thread Masami Hiramatsu
next_rip local variable. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- arch/x86/kernel/kprobes_64.c | 37 - 1 file changed, 16 insertions(+), 21 deletions(-) Index: 2.6.24-rc4-mm1/arch/x86/kernel/kprobes_64.c

[-mm][PATCH 3/6] kprobe-booster for x86-64

2007-12-17 Thread Masami Hiramatsu
This patch adds kprobe-booster to kprobes_64.c. - Changes are based on x86-32. - Add REX prefix checking code. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] Signed-off-by: Jim Keniston [EMAIL PROTECTED] --- arch/x86/kernel/kprobes_64.c | 142

[-mm][PATCH 1/6] jprobe bugfix and cleanup

2007-12-17 Thread Masami Hiramatsu
on x86-64, it may get incorrect data, because pt_regs can not be get by using container_of(rsp)) - Change the type of stack pointer to unsigned long *. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] Acked-by: Ananth N Mavinakayanahalli [EMAIL PROTECTED] --- arch/x86/kernel/kprobes_32.c

[-mm][PATCH 4/6] return probe-booster for x86-64

2007-12-17 Thread Masami Hiramatsu
This patch adds kretprobe-booster to kprobes_64.c. - Changes are based on x86-32. - Rewrite register saving/restoring code Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- arch/x86/kernel/kprobes_64.c | 92 ++- 1 file changed, 65 insertions(+), 27

Re: Final kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
Hi Ingo, Ingo Molnar wrote: * Masami Hiramatsu [EMAIL PROTECTED] wrote: cool! Please Cc: lkml and Harvey as well so that there's less overlap in unification work - Harvey spent quite some time unifying and cleaning up the kprobes code during the past week. Should I rewrite it based

Re: [-mm][PATCH 0/6] (yet another) kprobes x86 code unification and boosters

2007-12-17 Thread Masami Hiramatsu
Hi, Ingo Molnar wrote: * Masami Hiramatsu [EMAIL PROTECTED] wrote: Hello all, I developed a series of patches which unifies kprobes code on x86 and introduces boosters on x86-64. These patches can be applied to 2.6.24-rc4-mm1. The purpose of this patchset is unifying kprobes_[32|64

Re: FInal kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
is MAX_INSN_SIZE, you can not copy instructions more than MAX_INSN_SIZE. BTW, in my patch, I unified MAX_INSN_SIZE to bigger one(16). I think it is enough for us. Thanks, Best Regards, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e

Re: FInal kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
Hi Harvey, Harvey Harrison wrote: On Mon, 2007-12-17 at 16:28 -0500, Masami Hiramatsu wrote: Hi Harvey, If you mention about a relative jump which is inserted by resume_execution(), I think you might misunderstand that relative jump. The size of that relative jump, which will be embedded

Re: FInal kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
Hi Harvey, Harvey Harrison wrote: On Mon, 2007-12-17 at 16:52 -0500, Masami Hiramatsu wrote: Hi Harvey, Before porting, could you tell me what differences are important to you? We can discuss about it. I just sent out a series of 4 patches equivalent to your patches 1-4/6 but based on my

Re: FInal kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
Hi Harvey, Harvey Harrison wrote: On Mon, 2007-12-17 at 18:14 -0500, Masami Hiramatsu wrote: Hi Harvey, Harvey Harrison wrote: On Mon, 2007-12-17 at 16:52 -0500, Masami Hiramatsu wrote: Hi Harvey, Before porting, could you tell me what differences are important to you? We can discuss

Re: FInal kprobes rollup patches

2007-12-17 Thread Masami Hiramatsu
Masami Hiramatsu wrote: These are: -add stack_addr() macro -I prefer the table defintion macros in mine as it avoids the need to cast the pointer passed to test_bit, but if you want them to be u32 as in your patch, I can change it. please do so. we'd like to reduce ifdefs as less

Re: [PATCH 3/4] x86: add kprobe-booster to X86_64

2007-12-18 Thread Masami Hiramatsu
); goto no_change; @@ -813,8 +813,6 @@ static void __kprobes resume_execution(struct kprobe *p, no_change: restore_btf(); - - return; } /* Thanks again! -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e

Re: [PATCH] x86: unify extable_{32|64}.c

2007-12-18 Thread Masami Hiramatsu
) -first = mid+1; -else -last = mid-1; -} -return NULL; -} -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from

[PATCH 2/2] x86: add reenter_kprobe helper

2007-12-18 Thread Masami Hiramatsu
Kprobe reenter logic from deeply indented section to helper function. This improves code readability. Signed-off-by: Harvey Harrison [EMAIL PROTECTED] Signed-off-by: Ingo Molnar [EMAIL PROTECTED] Signed-off-by: Thomas Gleixner [EMAIL PROTECTED] Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED

[PATCH 1/2] x86: fix kprobe_handler reenable preemption

2007-12-18 Thread Masami Hiramatsu
Fix a preemption bug in kprobe_handler(). It has to call preempt_enable() before returning. I think this is critical on preemptive kernel. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- arch/x86/kernel/kprobes.c |5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) Index: b/arch

Re: [PATCH 1/2] x86: fix kprobe_handler reenable preemption

2007-12-18 Thread Masami Hiramatsu
Hi Masami Hiramatsu wrote: Fix a preemption bug in kprobe_handler(). It has to call preempt_enable() before returning. I think this is critical on preemptive kernel. Sorry, this patch has a mistake. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- arch/x86/kernel/kprobes.c |5

Re: [PATCH 3/4] x86: add kprobe-booster to X86_64

2007-12-18 Thread Masami Hiramatsu
Harvey Harrison wrote: On Tue, 2007-12-18 at 08:50 -0500, Masami Hiramatsu wrote: Hi Harvey, Thank you for cleaning this up. Harvey Harrison wrote: Subject: [PATCH] x86: kprobes leftover cleanups Eliminate __always_inline, all of these static functions are only called once. Minor

Re: [PATCH] x86: __kprobes annotations

2007-12-18 Thread Masami Hiramatsu
Harvey Harrison wrote: __always_inline on some static functions was to ensure they ended up in the .kprobes.text section. Mark this explicitly. It is good to me. Thanks! Signed-off-by: Harvey Harrison [EMAIL PROTECTED] Acked-by: Masami Hiramatsu [EMAIL PROTECTED] --- arch/x86/kernel

Re: [PATCH 1/2] x86: fix kprobe_handler reenable preemption

2007-12-19 Thread Masami Hiramatsu
Hi Ingo, Ingo Molnar wrote: * Masami Hiramatsu [EMAIL PROTECTED] wrote: - return 1; + ret = 1; Here, return 1; is correct. After single step is done, preemption is enabled in post_kprobe_handler(). could you resend the fixed patch? (instead of me

[PATCH 2/3] x86: add reenter_kprobe helper

2007-12-19 Thread Masami Hiramatsu
; + reenter_kprobe(p, regs, kcb); return 1; } else { if (*addr != BREAKPOINT_INSTRUCTION) { -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED

[PATCH 3/3] x86: move deeply indented code to reenter_kprobe

2007-12-19 Thread Masami Hiramatsu
Move some deeply indented code related to re-entrance processing from kprobe_handler() to reenter_kprobe(). Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] Cc: Ananth N Mavinakayanahalli [EMAIL PROTECTED] Cc: Jim Keniston [EMAIL PROTECTED] --- arch/x86/kernel/kprobes.c | 46

[PATCH 1/3] x86: fix kprobe_handler reenable preemption

2007-12-19 Thread Masami Hiramatsu
Fix a preemption bug in kprobe_handler(). It has to call preempt_enable() before returning. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- arch/x86/kernel/kprobes.c |3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) Index: b/arch/x86/kernel/kprobes.c

Re: [PATCH] x86: Introduce REX prefix helper for kprobes

2007-12-29 Thread Masami Hiramatsu
regs-flags = ~X86_EFLAGS_TF; switch (*insn) { -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body

Re: [PATCH] x86: kprobes remove fix_riprel #ifdef

2007-12-29 Thread Masami Hiramatsu
+ if (can_boost(p-addr)) p-ainsn.boostable = 0; else -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from this list: send the line unsubscribe linux

Re: [PATCH] x86: kprobes change kprobe_handler flow

2007-12-30 Thread Masami Hiramatsu
); kcb-kprobe_status = KPROBE_HIT_SS; - return 1; + goto out; I think return 1 is better. -no_kprobe: +preempt_out: preempt_enable_no_resched(); +out: return ret; } -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software

Re: [PATCH] x86: Introduce REX prefix helper for kprobes

2007-12-30 Thread Masami Hiramatsu
this? --- (in case of CONFIG_X86_64) static inline int is_rex_prefix(int op) { return ((op 0xf0) == 0x40); } (in case of CONFIG_X86_32) #define is_rex_prefix(op) (0) --- About the name, I just used the previous inline function name. Thank you, -hpa -- Masami Hiramatsu Software

Re: [PATCH] x86: Introduce REX prefix helper for kprobes

2007-12-30 Thread Masami Hiramatsu
Masami Hiramatsu wrote: (in case of CONFIG_X86_64) static inline int is_rex_prefix(int op) Oops, s/int op/kprobe_opcode_t opcode/ About the name, I just used the previous inline function name. I re-think is_REX_prefix is better, because it is an architecture dependent notation(intel's

Re: [PATCH] x86: kprobes remove fix_riprel #ifdef

2007-12-30 Thread Masami Hiramatsu
Hello Ingo, Ingo Molnar wrote: * Masami Hiramatsu [EMAIL PROTECTED] wrote: Hello Harvey, A similar idea was already nack-ed by Ananth. http://sources.redhat.com/ml/systemtap/2007-q4/msg00468.html And I agree his thought. Especially, riprel does not exist on x86_32, so fix_riprel

Re: [PATCH] x86: kprobes remove fix_riprel #ifdef

2007-12-30 Thread Masami Hiramatsu
Ingo Molnar wrote: * Masami Hiramatsu [EMAIL PROTECTED] wrote: Indeed. By the way, flush_cache_page() is defined as a do-while(0) on x86. Would it better to define fix_riprel() as a do-while(0) on x86-32? I think this obviously indicates that function has no effect. NOPs should always

Re: [PATCH] x86: kprobes change kprobe_handler flow

2008-01-01 Thread Masami Hiramatsu
: - preempt_enable_no_resched(); + if (!ret) + preempt_enable_no_resched(); return ret; } -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe

Re: [PATCH] x86: kprobes change kprobe_handler flow

2008-01-02 Thread Masami Hiramatsu
Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- Thanks, Abhishek Sagar Thank you, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division

Re: [PATCH] x86: kprobes change kprobe_handler flow

2008-01-02 Thread Masami Hiramatsu
. return ret; } Thank you, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED], [EMAIL PROTECTED] -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL

Re: [PATCH] x86: kprobes change kprobe_handler flow

2008-01-02 Thread Masami Hiramatsu
Hi Abhishek, Abhishek Sagar wrote: On 1/2/08, Masami Hiramatsu [EMAIL PROTECTED] wrote: I think setup_singlestep() in your first patch is better, because it avoided code duplication(*). Will retain it then. Thank you very much. static int __kprobes reenter_kprobe(struct kprobe *p

Re: [PATCH] x86: Use is_kprobe_fault to better match usage

2008-01-02 Thread Masami Hiramatsu
(struct pt_regs *regs, goto bad_area_nosemaphore; } - if (notify_page_fault(regs)) + if (is_kprobe_fault(regs)) return; if (likely(regs-flags X86_EFLAGS_IF)) -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc

Re: [PATCH] x86: Use is_kprobe_fault to better match usage

2008-01-02 Thread Masami Hiramatsu
Harvey Harrison wrote: On Wed, 2008-01-02 at 21:36 -0500, Masami Hiramatsu wrote: Hi Harvey, Harvey Harrison wrote: Currently the notify_page_fault helper is used to test it the page fault was caused by a kprobe causing an early return from do_page_fault. Change the name of the helper

Re: [PATCH] kprobes: Introduce is_kprobe_fault()

2008-01-02 Thread Masami Hiramatsu
) { return NULL; } +static inline int is_kprobe_fault(struct pt_regs *regs, int trapnr) +{ + return 0; +} static inline int register_kprobe(struct kprobe *p) { return -ENOSYS; -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions

Re: [PATCH] x86: kprobes change kprobe_handler flow

2008-01-03 Thread Masami Hiramatsu
Abhishek Sagar wrote: Masami Hiramatsu wrote: ... Done. You should find the desired changed in this patch. Well done! This cleans it up very well. I have just one more comment. @@ -463,14 +487,26 @@ static int __kprobes reenter_kprobe(struct kprobe *p, struct pt_regs *regs

Re: [PATCH] x86: kprobes change kprobe_handler flow

2008-01-03 Thread Masami Hiramatsu
Hi Abhishek, Masami Hiramatsu wrote: Hmm, I can not agree, because it is possible to insert a kprobe into kprobe's instruction buffer. If it should be a bug, we must check it when registering the kprobe. I discussed it with other maintainers and knew that current kprobes does not allow

Re: [17/19] ftrace: dynamic enabling/disabling of function calls

2008-02-11 Thread Masami Hiramatsu
replacing the call instruction, you can safely remove the bypass. Here is an ols paper about djprobe. http://www.kernel.org/doc/ols/2007/ols2007v1-pages-189-200.pdf Thank you, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL

Re: [PATCH] kprobes: remove sparse warnings from x86

2008-02-14 Thread Masami Hiramatsu
and static. Signed-off-by: Harvey Harrison [EMAIL PROTECTED] It looks good to me. Acked-by: Masami Hiramatsu [EMAIL PROTECTED] Thank you, -- Masami Hiramatsu Software Engineer Hitachi Computer Products (America) Inc. Software Solutions Division e-mail: [EMAIL PROTECTED] -- To unsubscribe from

Re: [PATCH v2 1/1] perf tools: remove sscanf extension %as

2012-09-24 Thread Masami Hiramatsu
and %as with strtok_r calls in order to parse a given string into its components. This is needed in Android since bionic does not support %as extension for sscanf. OK, I've reviewed and tested, looks good! :) Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Thank you! Signed-off-by: Irina Tirdea

Re: [PATCH] x86, kprobes: Hide skip_singlestep forward declaration properly

2012-09-24 Thread Masami Hiramatsu
(2012/09/20 18:40), Ingo Molnar wrote: * Masami Hiramatsu masami.hiramatsu...@hitachi.com wrote: (2012/09/20 18:25), Ingo Molnar wrote: * Masami Hiramatsu masami.hiramatsu...@hitachi.com wrote: (2012/09/19 22:46), Borislav Petkov wrote: From: Borislav Petkov borislav.pet...@amd.com I

Re: [PATCH 1/3] virtio_console:Merge struct buffer_token into struct port_buffer

2012-09-25 Thread Masami Hiramatsu
amit.s...@redhat.com cc: Linus Walleij linus.wall...@linaro.org cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com --- drivers/char/virtio_console.c | 141 ++--- 1 files changed, 62 insertions(+), 79 deletions(-) diff --git a/drivers/char/virtio_console.c

Re: [QUESTION] Can uprobe_event support @ADDR, $retval, offs(FETCHARG)?

2012-09-25 Thread Masami Hiramatsu
available. ;) Thank you, -- Masami HIRAMATSU Software Platform Research Dept. Linux Technology Center Hitachi, Ltd., Yokohama Research Laboratory E-mail: masami.hiramatsu...@hitachi.com -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to majord

Re: [PATCH 1/3] virtio_console:Merge struct buffer_token into struct port_buffer

2012-09-26 Thread Masami Hiramatsu
, but I can change this to something like: alloc_size = sizeof(*buf) + sizeof(buf-sg) * max(nrbufs - 1, 1); You wouldn't need to change that. I think current code is enough simple and reasonable. :) Thanks! -- Masami HIRAMATSU Software Platform Research Dept. Linux Technology Center Hitachi

Re: [PATCH] perf probe: print an enum type variable in enum variable-name format when showing accessible variables

2012-09-27 Thread Masami Hiramatsu
-name variable-name. Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Thank you! Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Signed-off-by: Hyeoncheol Lee hyc@gmail.com --- tools/perf/util/dwarf-aux.c |2 ++ 1 file changed, 2 insertions(+) diff --git a/tools

[PATCH -tip ] [BUGFIX] perf probe: Add a workaround for GCC -mfentry

2012-10-03 Thread Masami Hiramatsu
at the function entry point Signed-off-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Arnaldo Carvalho de Melo a...@infradead.org Cc: Peter Zijlstra a.p.zijls...@chello.nl Cc: Paul Mackerras pau...@samba.org Cc: Ingo Molnar mi...@redhat.com Cc: Michal Marek mma...@suse.cz Cc: Andi Kleen

Re: [PATCH -tip ] [BUGFIX] perf probe: Add a workaround for GCC -mfentry

2012-10-03 Thread Masami Hiramatsu
(2012/10/03 21:27), Andi Kleen wrote: On Wed, Oct 03, 2012 at 09:17:07PM +0900, Masami Hiramatsu wrote: Add a workaround for GCC -mfentry option. This enables perf probe to find function parameters(arguments) at given function entry point again. Could you please file a gcc PR about

Re: Re: [PATCH -tip ] [BUGFIX] perf probe: Add a workaround for GCC -mfentry

2012-10-03 Thread Masami Hiramatsu
(2012/10/04 1:00), Mark Wielaard wrote: On Wed, 2012-10-03 at 09:53 -0400, Steven Rostedt wrote: On Wed, 2012-10-03 at 21:17 +0900, Masami Hiramatsu wrote: 19a58: Abbrev Number: 86 (DW_TAG_subprogram) 9a59 DW_AT_external: 1 9a59 DW_AT_name: (indirect string, offset

Re: Re: [PATCH v2 00/16] perf: add memory access sampling support

2012-11-07 Thread Masami Hiramatsu
the FAQ at http://www.tux.org/lkml/ -- Masami HIRAMATSU IT Management Research Dept. Linux Technology Center Hitachi, Ltd., Yokohama Research Laboratory E-mail: masami.hiramatsu...@hitachi.com -- To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message

Re: [PATCH] perf probe: convert_name_to_addr() allocated the wrong size buffer for a function name

2012-10-15 Thread Masami Hiramatsu
(2012/10/16 10:37), Hyeoncheol Lee wrote: convert_name_to_addr() allocated sizeof(char *) * MAX_PROBE_ARGS bytes for a function name Yeah, that one was from my laziness... Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Srikar Dronamraju sri...@linux.vnet.ibm.com Signed-off

Re: [PATCH] uprobes tracer: Add stack/memory/retval access support

2012-10-16 Thread Masami Hiramatsu
(2012/10/16 18:02), Hyeoncheol Lee wrote: Event arguments except @SYM are supported. They are @ADDR, $stack, $stackN, $retval, and offs(arguments). Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Srikar Dronamraju sri...@linux.vnet.ibm.com Signed-off-by: Hyeoncheol Lee hyc

Re: [PATCH] perf probe: convert_name_to_addr() allocated the wrong size buffers for names

2012-10-17 Thread Masami Hiramatsu
(2012/10/17 17:28), Hyeoncheol Lee wrote: The function allocated wrong size buffers for names Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Srikar Dronamraju sri...@linux.vnet.ibm.com Signed-off-by: Hyeoncheol Lee hyc@gmail.com --- tools/perf/util/probe-event.c | 11

Re: [PATCH] perf probe: convert_name_to_addr() allocated the wrong size buffers for names

2012-10-17 Thread Masami Hiramatsu
(2012/10/18 10:20), Namhyung Kim wrote: Hi, On Wed, 17 Oct 2012 20:06:54 +0900, Masami Hiramatsu wrote: (2012/10/17 17:28), Hyeoncheol Lee wrote: The function allocated wrong size buffers for names Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Srikar Dronamraju sri

Re: [PATCH v2] perf probe: convert_name_to_addr() allocated the wrong size buffers for names

2012-10-18 Thread Masami Hiramatsu
(2012/10/18 10:17), Hyeoncheol Lee wrote: The function allocated wrong size buffers for names Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Srikar Dronamraju sri...@linux.vnet.ibm.com Signed-off-by: Hyeoncheol Lee hyc@gmail.com Acked-by: Masami Hiramatsu masami.hiramatsu

[PATCH][kprobes] support kretprobe-blacklist

2007-08-17 Thread Masami Hiramatsu
This patch introduces architecture dependent kretprobe blacklists to prohibit users from inserting return probes on the function in which kprobes can be inserted but kretprobes can not. Signed-off-by: Masami Hiramatsu [EMAIL PROTECTED] --- Problem Description When a kretprobe is inserted

Re: [PATCH][kprobes] support kretprobe-blacklist

2007-08-17 Thread Masami Hiramatsu
, + arch_kretprobe_blacklist[i].name); +} +#endif really isn't the sort of thing we like to see spreading through core kernel code. Have a think about it please, see what we can come up with? OK, I see. I'll do that next time. Best regards, -- Masami Hiramatsu

[PATCH][kprobes] support kretprobe-blacklist take2

2007-08-21 Thread Masami Hiramatsu
Hi Andrew, I updated my patch and removed #ifdefs from it. Thank you, Masami Hiramatsu Hitachi Computer Products (America), Inc. This patch introduces architecture dependent kretprobe blacklists to prohibit users from inserting return probes on the function in which kprobes can be inserted

Re: 2.6.11-rc1-mm1

2005-01-18 Thread Masami Hiramatsu
are interested in this, please try LKST. -- Masami HIRAMATSU Hitachi, Ltd., Systems Development Laboratory E-mail: [EMAIL PROTECTED] - To unsubscribe from this list: send the line unsubscribe linux-kernel in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo

Re: [Lkst-develop] Re: 2.6.11-rc1-mm1

2005-01-18 Thread Masami Hiramatsu
Hi, Andi Kleen wrote: On Tue, Jan 18, 2005 at 08:19:18PM +0900, Masami Hiramatsu wrote: Hello, I?m a developer of yet another kernel tracer, LKST. I and co-developers are very glad to hear that LTT was merged into -mm tree and to talk about the kernel tracer on this ML. Because we think

Re: Re: [RFC][PATCH 2/4 v4] ftrace/x86: Add save_regs for i386 function calls

2012-07-16 Thread Masami Hiramatsu
(2012/07/14 3:47), Steven Rostedt wrote: On Thu, 2012-07-12 at 21:39 +0900, Masami Hiramatsu wrote: /* * X86_32 CPUs don't save ss and esp if the CPU is already in kernel mode * when it traps. The previous stack will be directly underneath the saved * registers, and 'sp/ss' won't even

Re: Re: Re: [RFC][PATCH 2/4 v4] ftrace/x86: Add save_regs for i386 function calls

2012-07-16 Thread Masami Hiramatsu
(2012/07/17 12:05), Steven Rostedt wrote: On Tue, 2012-07-17 at 11:08 +0900, Masami Hiramatsu wrote: I found that regs_get_register() doesn't honor this either. Thus, kprobes in tracing gets this: # echo 'p:ftrace sys_read+4 s=%sp' /debug/tracing/kprobe_events # echo 1 /debug/tracing

Re: [RFC][PATCH] x86_32: Return actual stack when requesting sp from regs

2012-07-18 Thread Masami Hiramatsu
tracing output better on i386. Original %sp gives nothing (or just misleading)... Reviewed-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com NOTE: if someone needs to get kernel stack address from regs, I recommend him to use kernel_stack_pointer() directly. Thank you, Signed-off-by: Steven

Re: Re: [RFC][PATCH 2/4 v4] ftrace/x86: Add save_regs for i386 function calls

2012-07-18 Thread Masami Hiramatsu
(2012/07/19 0:59), Steven Rostedt wrote: On Fri, 2012-07-13 at 14:47 -0400, Steven Rostedt wrote: Masami, can you give your Reviewed-by tag for this version? Or is there something else needing to be fixed? No, that is OK for me. I've just missed that... Reviewed-by: Masami Hiramatsu

[PATCH -tip ] [BUGFIX] kprobes: Fix a double lock bug of kprobe_mutex

2013-04-18 Thread Masami Hiramatsu
it in proc_kprobes_optimization_handler. Of course, since we need to lock kprobe_mutex when touching kprobes resources, that is done in *optimize_all_kprobes(). This bug was from ad72b3bea744b4db01c89af0f86f3e8920d354df Signed-off-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Ingo Molnar mi

Re: [PATCH 2/4] kprobes: split blacklist into common and arch

2013-04-04 Thread Masami Hiramatsu
! -- Masami HIRAMATSU IT Management Research Dept. Linux Technology Center Hitachi, Ltd., Yokohama Research Laboratory E-mail: masami.hiramatsu...@hitachi.com -- 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

Re: [PATCH 4/4] kprobes: replace printk with pr_-functions

2013-04-04 Thread Masami Hiramatsu
(2013/04/03 17:28), oskar.and...@sonymobile.com wrote: Instead of using printk use pr_info/pr_err/pr_warn. This was detected by the checkpatch.pl script. Thank you for cleaning this up ! :) Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Signed-off-by: Oskar Andero oskar.and

Re: [PATCH 1/4] kprobes: delay blacklist symbol lookup until we actually need it

2013-04-04 Thread Masami Hiramatsu
for avoiding concurrent initialization. Perhaps, the easiest way is to protect init_kprobe_blacklist() by kprobe_mutex and check kprobe_blacklist_initialized again in the top of that. Thank you, -- Masami HIRAMATSU IT Management Research Dept. Linux Technology Center Hitachi, Ltd., Yokohama Research

[PATCH -tip ] kprobes: Move __kprobes definition into compiler.h

2013-04-04 Thread Masami Hiramatsu
Currently, __kprobes is defined in linux/kprobes.h which is too big to be included in small or basic headers only for using this attribute. This moves __kprobes definition into linux/compiler.h in which other compiler attributes are defined. Signed-off-by: Masami Hiramatsu masami.hiramatsu

[PATCH -tip ] kprobes/x86: Just return error for sanity check failure instead of using BUG_ON

2013-04-04 Thread Masami Hiramatsu
Note, this patch is for help to analyze what happened. Signed-off-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Frank Ch. Eigler f...@redhat.com Cc: Thomas Gleixner t...@linutronix.de Cc: Ingo Molnar mi...@redhat.com Cc: H. Peter Anvin h...@zytor.com Cc: Steven Rostedt rost

Re: [PATCH -tip ] kprobes: Move __kprobes definition into compiler.h

2013-04-04 Thread Masami Hiramatsu
Hi Ingo, (2013/04/04 19:40), Masami Hiramatsu wrote: Currently, __kprobes is defined in linux/kprobes.h which is too big to be included in small or basic headers only for using this attribute. This moves __kprobes definition into linux/compiler.h in which other compiler attributes

Re: Re: [PATCH v2 1/4] kprobes: delay blacklist symbol lookup until we actually need it

2013-04-04 Thread Masami Hiramatsu
is first used. Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: David S. Miller da...@davemloft.net Reviewed-by: Radovan Lekanovic radovan.lekano...@sonymobile.com Signed-off-by: Toby Collett toby.coll...@sonymobile.com Signed-off-by: Oskar Andero oskar.and...@sonymobile.com

Re: [PATCH v2 2/4] kprobes: split blacklist into common and arch

2013-04-04 Thread Masami Hiramatsu
) kretprobe_blacklist[i].name); } } - kprobe_blacklist_initialized = 1; And after initialized, assign blacklist to kprobe_blacklist. Without that, other thread may refer the uninitialized (but allocated) black list. Thank you, -- Masami HIRAMATSU IT Management Research Dept

Re: [PATCH v2 3/4] kprobes: move x86-specific blacklist symbols to arch directory

2013-04-04 Thread Masami Hiramatsu
/kprobes/core.c. OK, it looks good for me. :) Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: David S. Miller da...@davemloft.net Cc: linux-a...@vger.kernel.org Reviewed-by: Radovan Lekanovic radovan.lekano...@sonymobile.com

Re: Re: [PATCH 3/4] uprobes/tracing: Kill the pointless local_save_flags/preempt_count calls

2013-04-04 Thread Masami Hiramatsu
Dronamraju sri...@linux.vnet.ibm.com Adding Masami in the Cc. Thanks :), since the running context of uprobe handler is different from kprobe one, this change is only needed for uprobe. Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Thank you, --- kernel/trace/trace_uprobe.c

Re: [PATCH] perf probe: Enhance error message on non-kprobeable functions

2013-04-05 Thread Masami Hiramatsu
it. Or, export such no-probe symbols via /sys/kernel/debug/kprobes/noprobe_syms Thank you, -- Masami HIRAMATSU IT Management Research Dept. Linux Technology Center Hitachi, Ltd., Yokohama Research Laboratory E-mail: masami.hiramatsu...@hitachi.com -- To unsubscribe from this list: send the line

Re: [PATCH 3/4] uprobes/tracing: Kill the pointless local_save_flags/preempt_count calls

2013-04-08 Thread Masami Hiramatsu
(2013/04/06 0:01), Oleg Nesterov wrote: On 04/05, Masami Hiramatsu wrote: Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Thanks! Masami, perhaps you can also answer the question I asked in 0/4 marc.info/?l=linux-kernelm=136458107403835 ? Off-topic question... Why

Re: [PATCH v3 1/4] kprobes: delay blacklist symbol lookup until we actually need it

2013-04-08 Thread Masami Hiramatsu
(2013/04/05 22:26), Oskar Andero wrote: From: Toby Collett toby.coll...@sonymobile.com The symbol lookup can take a long time and kprobes is initialised very early in boot, so delay symbol lookup until the blacklist is first used. Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com

Re: [PATCH v3 2/4] kprobes: split blacklist into common and arch

2013-04-08 Thread Masami Hiramatsu
/ directory. Looks good for me:) Acked-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Thank you! Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Cc: David S. Miller da...@davemloft.net Cc: linux-a...@vger.kernel.org Signed-off-by: Oskar Andero oskar.and...@sonymobile.com

Re: [PATCH 1/1] uprobes/tracing: Don't pass addr=ip to perf_trace_buf_submit()

2013-04-11 Thread Masami Hiramatsu
-by: Masami Hiramatsu masami.hiramatsu...@hitachi.com Thank you! --- kernel/trace/trace_uprobe.c |8 +++- 1 files changed, 3 insertions(+), 5 deletions(-) diff --git a/kernel/trace/trace_uprobe.c b/kernel/trace/trace_uprobe.c index 2d08bea..37ccb72 100644 --- a/kernel/trace

Re: [PATCH 0/1] uprobes/tracing: Don't pass addr=ip to perf_trace_buf_submit()

2013-04-11 Thread Masami Hiramatsu
(2013/04/10 23:58), Oleg Nesterov wrote: On 04/08, Masami Hiramatsu wrote: (2013/04/06 0:01), Oleg Nesterov wrote: Masami, perhaps you can also answer the question I asked in 0/4 marc.info/?l=linux-kernelm=136458107403835 ? Off-topic question... Why uprobe_perf_func() passes addr = ip

Re: [PATCH] kprobe: initialize kprobe_blacklist when it is used firstly

2013-04-02 Thread Masami Hiramatsu
the patch is going first. Thank you, Cc: Ananth N Mavinakayanahalli ana...@in.ibm.com Cc: Anil S Keshavamurthy anil.s.keshavamur...@intel.com Cc: David S. Miller da...@davemloft.net Cc: Masami Hiramatsu masami.hiramatsu...@hitachi.com Signed-off-by: Joonsoo Kim iamjoonsoo@lge.com --- I

Re: Re: [PATCH] kprobe: initialize kprobe_blacklist when it is used firstly

2013-04-02 Thread Masami Hiramatsu
(2013/04/02 21:16), oskar.and...@sonymobile.com wrote: On 12:49 Tue 02 Apr , Masami Hiramatsu wrote: Hi, (2013/04/01 15:55), Joonsoo Kim wrote: Currently, initializing kprobe_blacklist is done during boot process. It takes 230 ms on our android platform and this is significant amount

  1   2   3   4   5   6   7   8   9   10   >