“4e0e6040c4052aff15a494ac05778f4086d24c33”上不存在“fs/xfs/libxfs/xfs_alloc.c”
提交 30176466 编写于 作者: N Naveen N. Rao 提交者: Michael Ellerman

powerpc/kprobes: Fixes for kprobe_lookup_name() on BE

Fix two issues with kprobes.h on BE which were exposed with the
optprobes work:
  - one, having to do with a missing include for linux/module.h for
    MODULE_NAME_LEN -- this didn't show up previously since the only
    users of kprobe_lookup_name were in kprobes.c, which included
    linux/module.h through other headers, and
  - two, with a missing const qualifier for a local variable which ends
    up referring a string literal. Again, this is unique to how
    kprobe_lookup_name is being invoked in optprobes.c
Signed-off-by: NNaveen N. Rao <naveen.n.rao@linux.vnet.ibm.com>
Signed-off-by: NMichael Ellerman <mpe@ellerman.id.au>
上级 ebfa50df
...@@ -29,6 +29,7 @@ ...@@ -29,6 +29,7 @@
#include <linux/types.h> #include <linux/types.h>
#include <linux/ptrace.h> #include <linux/ptrace.h>
#include <linux/percpu.h> #include <linux/percpu.h>
#include <linux/module.h>
#include <asm/probes.h> #include <asm/probes.h>
#include <asm/code-patching.h> #include <asm/code-patching.h>
...@@ -61,7 +62,7 @@ typedef ppc_opcode_t kprobe_opcode_t; ...@@ -61,7 +62,7 @@ typedef ppc_opcode_t kprobe_opcode_t;
#define kprobe_lookup_name(name, addr) \ #define kprobe_lookup_name(name, addr) \
{ \ { \
char dot_name[MODULE_NAME_LEN + 1 + KSYM_NAME_LEN]; \ char dot_name[MODULE_NAME_LEN + 1 + KSYM_NAME_LEN]; \
char *modsym; \ const char *modsym; \
bool dot_appended = false; \ bool dot_appended = false; \
if ((modsym = strchr(name, ':')) != NULL) { \ if ((modsym = strchr(name, ':')) != NULL) { \
modsym++; \ modsym++; \
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册