[PATCH] Fix kprobes on ia64 - Kernel

This is a discussion on [PATCH] Fix kprobes on ia64 - Kernel ; If CONFIG_KPROBES is set, we get the error during build: kernel/kprobes.c:1057: error: __ksymtab_jprobe_return causes a section type conflict This is because ia64 defines a static inline jprobe_return which kprobes attempts to EXPORT_SYMBOL. Signed-off-by: Matthew Wilcox diff --git a/kernel/kprobes.c b/kernel/kprobes.c index ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: [PATCH] Fix kprobes on ia64

  1. [PATCH] Fix kprobes on ia64


    If CONFIG_KPROBES is set, we get the error during build:

    kernel/kprobes.c:1057: error: __ksymtab_jprobe_return causes a section
    type conflict

    This is because ia64 defines a static inline jprobe_return which kprobes
    attempts to EXPORT_SYMBOL.

    Signed-off-by: Matthew Wilcox

    diff --git a/kernel/kprobes.c b/kernel/kprobes.c
    index e3a5d81..ecc25b3 100644
    --- a/kernel/kprobes.c
    +++ b/kernel/kprobes.c
    @@ -1053,11 +1053,11 @@ EXPORT_SYMBOL_GPL(register_kprobe);
    EXPORT_SYMBOL_GPL(unregister_kprobe);
    EXPORT_SYMBOL_GPL(register_jprobe);
    EXPORT_SYMBOL_GPL(unregister_jprobe);
    +
    #ifdef CONFIG_KPROBES
    +#ifndef __ia64__ /* It's static inline */
    EXPORT_SYMBOL_GPL(jprobe_return);
    #endif
    -
    -#ifdef CONFIG_KPROBES
    EXPORT_SYMBOL_GPL(register_kretprobe);
    EXPORT_SYMBOL_GPL(unregister_kretprobe);
    #endif

    --
    Intel are signing my paycheques ... these opinions are still mine
    "Bill, look, we understand that you're interested in selling us this
    operating system, but compare it to ours. We can't possibly take such
    a retrograde step."
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  2. Re: [PATCH] Fix kprobes on ia64

    On Sun, Jan 13, 2008 at 07:24:24PM -0700, Matthew Wilcox wrote:
    >
    > If CONFIG_KPROBES is set, we get the error during build:
    >
    > kernel/kprobes.c:1057: error: __ksymtab_jprobe_return causes a section
    > type conflict
    >
    > This is because ia64 defines a static inline jprobe_return which kprobes
    > attempts to EXPORT_SYMBOL.


    The better fix is to let jprobe_return be a normal function that can be exported.
    Then we avoid this arch specific ifdef for the cost of nothing.

    Sam
    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

  3. Re: [PATCH] Fix kprobes on ia64

    On Sun, Jan 13, 2008 at 07:24:24PM -0700, Matthew Wilcox wrote:
    > If CONFIG_KPROBES is set, we get the error during build:
    >
    > kernel/kprobes.c:1057: error: __ksymtab_jprobe_return causes a section
    > type conflict
    >
    > This is because ia64 defines a static inline jprobe_return which kprobes
    > attempts to EXPORT_SYMBOL.


    Given that jprobe_return is defined in the arch-specific kprobes.c file
    it would be better to export it there instead of in kernel/kprobe.c, or
    in case of ia64 not export it at all.

    --
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.kernel.org
    More majordomo info at http://vger.kernel.org/majordomo-info.html
    Please read the FAQ at http://www.tux.org/lkml/

+ Reply to Thread