search for: __kprobes

Displaying 20 results from an estimated 24 matches for "__kprobes".

2013 Nov 15
23
[PATCH -tip RFC v2 00/22] kprobes: introduce NOKPROBE_SYMBOL() and general cleaning of kprobe blacklist
...on and is hard to catch up the kernel update. To solve this issue, I've tried to implement new NOKPROBE_SYMBOL() macro for making kprobe blacklist at build time. Since the NOKPROBE_SYMBOL() macros can be placed right after the function is defined, it is easy to maintain. This series replaces __kprobes with NOKPROBE_SYMBOL() macro or apply __always_inline annotation for some cases, because NOKPROBE_SYMBOL() will inhibit inlining by referring the symbol address. :( In this series, I replaced all __kprobes under kernel/ and arch/x86. For future work, I'd like to replace all the __kprobes annot...
2013 Nov 15
23
[PATCH -tip RFC v2 00/22] kprobes: introduce NOKPROBE_SYMBOL() and general cleaning of kprobe blacklist
...on and is hard to catch up the kernel update. To solve this issue, I've tried to implement new NOKPROBE_SYMBOL() macro for making kprobe blacklist at build time. Since the NOKPROBE_SYMBOL() macros can be placed right after the function is defined, it is easy to maintain. This series replaces __kprobes with NOKPROBE_SYMBOL() macro or apply __always_inline annotation for some cases, because NOKPROBE_SYMBOL() will inhibit inlining by referring the symbol address. :( In this series, I replaced all __kprobes under kernel/ and arch/x86. For future work, I'd like to replace all the __kprobes annot...
2013 Nov 20
28
[PATCH -tip v3 00/23] kprobes: introduce NOKPROBE_SYMBOL() and general cleaning of kprobe blacklist
...to catch up the kernel update. To solve this issue, I've introduced NOKPROBE_SYMBOL() macro for making kprobe blacklist at build time. Since the NOKPROBE_SYMBOL() macros can be placed right after the function is defined (as like as EXPORT_SYMBOL), it is easy to maintain. This series replaces __kprobes with NOKPROBE_SYMBOL() macro or apply __always_inline annotation for some cases, because NOKPROBE_SYMBOL() will inhibit inlining by referring the symbol address. :( At this point, I replaced all __kprobes under kernel/ and arch/x86. For future work, I'd like to replace all the __kprobes annota...
2013 Nov 20
28
[PATCH -tip v3 00/23] kprobes: introduce NOKPROBE_SYMBOL() and general cleaning of kprobe blacklist
...to catch up the kernel update. To solve this issue, I've introduced NOKPROBE_SYMBOL() macro for making kprobe blacklist at build time. Since the NOKPROBE_SYMBOL() macros can be placed right after the function is defined (as like as EXPORT_SYMBOL), it is easy to maintain. This series replaces __kprobes with NOKPROBE_SYMBOL() macro or apply __always_inline annotation for some cases, because NOKPROBE_SYMBOL() will inhibit inlining by referring the symbol address. :( At this point, I replaced all __kprobes under kernel/ and arch/x86. For future work, I'd like to replace all the __kprobes annota...
2013 Nov 20
0
[PATCH -tip v3 13/23] x86/trap: Use NOKPROBE_SYMBOL macro in trap.c
Use NOKPROBE_SYMBOL macro to protect functions from kprobes instead of __kprobes annotation in trap.c. This also applies __always_inline annotation for some cases, because NOKPROBE_SYMBOL() will inhibit inlining by referring the symbol address. Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> Cc: Thomas Gleixner <tglx at linutronix.de> Cc: Ingo...
2013 Nov 20
0
[PATCH -tip v3 18/23] x86/dumpstack: Use NOKPROBE_SYMBOL macro in dumpstack.c
Use NOKPROBE_SYMBOL macro for protecting functions from kprobes instead of __kprobes annotation in dumpstack.c. Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> Cc: Thomas Gleixner <tglx at linutronix.de> Cc: Ingo Molnar <mingo at redhat.com> Cc: "H. Peter Anvin" <hpa at zytor.com> Cc: Andrew Morton <akpm at linux-foundation...
2013 Nov 11
2
[PATCH -tip RFC 0/2] kprobes: introduce NOKPROBE_SYMBOL() and prohibit probing on .entry.text
...> Mind changing over arch/x86/kprobes/* to use this new facility? There's no > sense in kprobes internals using two types Sure, that's why I introduced this :) > After that we can convert all the rest, probably as part of this series. OK, I'll do. :) BTW, converting all the __kprobes involves many archs, which kprobes ported. In that case, which mailing-list would better me to post the series, linux-arch? > > There's a good reason now to do it: it's not just about cleanliness, it > will also impact generated code less. Thank you! -- Masami HIRAMATSU IT M...
2013 Nov 11
2
[PATCH -tip RFC 0/2] kprobes: introduce NOKPROBE_SYMBOL() and prohibit probing on .entry.text
...> Mind changing over arch/x86/kprobes/* to use this new facility? There's no > sense in kprobes internals using two types Sure, that's why I introduced this :) > After that we can convert all the rest, probably as part of this series. OK, I'll do. :) BTW, converting all the __kprobes involves many archs, which kprobes ported. In that case, which mailing-list would better me to post the series, linux-arch? > > There's a good reason now to do it: it's not just about cleanliness, it > will also impact generated code less. Thank you! -- Masami HIRAMATSU IT M...
2013 Nov 21
1
[PATCH -tip v3 18/23] x86/dumpstack: Use NOKPROBE_SYMBOL macro in dumpstack.c
* Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> wrote: > Use NOKPROBE_SYMBOL macro for protecting functions > from kprobes instead of __kprobes annotation in > dumpstack.c. > > Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> > Cc: Thomas Gleixner <tglx at linutronix.de> > Cc: Ingo Molnar <mingo at redhat.com> > Cc: "H. Peter Anvin" <hpa at zytor.com> > Cc: Andrew...
2013 Nov 21
1
[PATCH -tip v3 18/23] x86/dumpstack: Use NOKPROBE_SYMBOL macro in dumpstack.c
* Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> wrote: > Use NOKPROBE_SYMBOL macro for protecting functions > from kprobes instead of __kprobes annotation in > dumpstack.c. > > Signed-off-by: Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> > Cc: Thomas Gleixner <tglx at linutronix.de> > Cc: Ingo Molnar <mingo at redhat.com> > Cc: "H. Peter Anvin" <hpa at zytor.com> > Cc: Andrew...
2013 Nov 08
4
[PATCH -tip RFC 0/2] kprobes: introduce NOKPROBE_SYMBOL() and prohibit probing on .entry.text
Currently the blacklist is maintained by hand in kprobes.c which is separated from the function definition and is hard to catch up the kernel update. To solve this issue, I've tried to implement new NOKPROBE_SYMBOL() macro for making kprobe blacklist at build time. Since the NOKPROBE_SYMBOL() macros can be placed right after the function is defined, it is easy to maintain. At this moment, I
2013 Nov 08
4
[PATCH -tip RFC 0/2] kprobes: introduce NOKPROBE_SYMBOL() and prohibit probing on .entry.text
Currently the blacklist is maintained by hand in kprobes.c which is separated from the function definition and is hard to catch up the kernel update. To solve this issue, I've tried to implement new NOKPROBE_SYMBOL() macro for making kprobe blacklist at build time. Since the NOKPROBE_SYMBOL() macros can be placed right after the function is defined, it is easy to maintain. At this moment, I
2013 Nov 11
0
[PATCH -tip RFC 0/2] kprobes: introduce NOKPROBE_SYMBOL() and prohibit probing on .entry.text
On Tue, 12 Nov 2013 02:18:53 +0900 Masami Hiramatsu <masami.hiramatsu.pt at hitachi.com> wrote: > > > After that we can convert all the rest, probably as part of this series. > > OK, I'll do. :) > BTW, converting all the __kprobes involves many archs, which > kprobes ported. In that case, which mailing-list would better me > to post the series, linux-arch? I would add linux-arch. Note, you may need to support both ways for the current time being, as new __kprobes are being added (I've seen several in patches flyi...
2013 Nov 22
2
[PATCH -tip v3 13/23] x86/trap: Use NOKPROBE_SYMBOL macro in trap.c
On Wed, Nov 20, 2013 at 04:22:21AM +0000, Masami Hiramatsu wrote: > Use NOKPROBE_SYMBOL macro to protect functions from kprobes > instead of __kprobes annotation in trap.c. > This also applies __always_inline annotation for some cases, > because NOKPROBE_SYMBOL() will inhibit inlining by referring > the symbol address. NOKPROBE_SYMBOL seems to add a reference from some variable to the function? With LTO we can optimize away unused func...
2013 Nov 22
2
[PATCH -tip v3 13/23] x86/trap: Use NOKPROBE_SYMBOL macro in trap.c
On Wed, Nov 20, 2013 at 04:22:21AM +0000, Masami Hiramatsu wrote: > Use NOKPROBE_SYMBOL macro to protect functions from kprobes > instead of __kprobes annotation in trap.c. > This also applies __always_inline annotation for some cases, > because NOKPROBE_SYMBOL() will inhibit inlining by referring > the symbol address. NOKPROBE_SYMBOL seems to add a reference from some variable to the function? With LTO we can optimize away unused func...
2013 Nov 20
0
[PATCH -tip v3 02/23] kprobes: Introduce NOKPROBE_SYMBOL() macro for blacklist
...x 1756ecc..e04d8de 100644 --- a/kernel/kprobes.c +++ b/kernel/kprobes.c @@ -86,18 +86,8 @@ static raw_spinlock_t *kretprobe_table_lock_ptr(unsigned long hash) return &(kretprobe_table_locks[hash].lock); } -/* - * Normally, functions that we'd want to prohibit kprobes in, are marked - * __kprobes. But, there are cases where such functions already belong to - * a different section (__sched for preempt_schedule) - * - * For such cases, we now have a blacklist - */ -static struct kprobe_blackpoint kprobe_blacklist[] = { - {"preempt_schedule",}, - {"native_get_debugreg",}, -...
2013 Nov 15
0
[PATCH -tip RFC v2 01/22] kprobes: Prohibit probing on .entry.text code
...be_blacklist[] = { {"preempt_schedule",}, {"native_get_debugreg",}, - {"irq_entries_start",}, - {"common_interrupt",}, - {"mcount",}, /* mcount can be called from everywhere */ {NULL} /* Terminator */ }; @@ -1328,8 +1325,11 @@ static int __kprobes in_kprobes_functions(unsigned long addr) { struct kprobe_blackpoint *kb; - if (addr >= (unsigned long)__kprobes_text_start && - addr < (unsigned long)__kprobes_text_end) + /* The __kprobes marked functions and entry code must not be probed */ + if ((addr >= (unsigned long)...
2013 Nov 23
0
[PATCH -tip v3 13/23] x86/trap: Use NOKPROBE_SYMBOL macro in trap.c
(2013/11/23 6:21), Andi Kleen wrote: > On Wed, Nov 20, 2013 at 04:22:21AM +0000, Masami Hiramatsu wrote: >> Use NOKPROBE_SYMBOL macro to protect functions from kprobes >> instead of __kprobes annotation in trap.c. >> This also applies __always_inline annotation for some cases, >> because NOKPROBE_SYMBOL() will inhibit inlining by referring >> the symbol address. > > NOKPROBE_SYMBOL seems to add a reference from some variable to the function? > > With LTO...
2007 Apr 18
2
[PATCH 19/21] i386 Kprobes semaphore fix
...nel/kprobes.c =================================================================== --- linux-2.6.14-zach-work.orig/arch/i386/kernel/kprobes.c 2005-11-04 19:25:27.000000000 -0800 +++ linux-2.6.14-zach-work/arch/i386/kernel/kprobes.c 2005-11-04 19:26:37.000000000 -0800 @@ -156,23 +156,25 @@ static int __kprobes kprobe_handler(stru struct kprobe *p; int ret = 0; kprobe_opcode_t *addr = NULL; - unsigned long *lp; + unsigned long limit; - /* We're in an interrupt, but this is clear and BUG()-safe. */ - preempt_disable(); - /* Check if the application is using LDT entry for its code segment and -...
2007 Apr 18
2
[PATCH 19/21] i386 Kprobes semaphore fix
...nel/kprobes.c =================================================================== --- linux-2.6.14-zach-work.orig/arch/i386/kernel/kprobes.c 2005-11-04 19:25:27.000000000 -0800 +++ linux-2.6.14-zach-work/arch/i386/kernel/kprobes.c 2005-11-04 19:26:37.000000000 -0800 @@ -156,23 +156,25 @@ static int __kprobes kprobe_handler(stru struct kprobe *p; int ret = 0; kprobe_opcode_t *addr = NULL; - unsigned long *lp; + unsigned long limit; - /* We're in an interrupt, but this is clear and BUG()-safe. */ - preempt_disable(); - /* Check if the application is using LDT entry for its code segment and -...