X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=include%2Fasm-powerpc%2Fkprobes.h;h=8b08b447d6f31e2e300e39b3813dd090b7c2233f;hb=9e367d859297b9377d65574f538cf52730e9eda8;hp=b0e40ff32ee02208378657196d294584b14f3c9f;hpb=a9deecba19b8f384d97f82c75379da48bccb2588;p=linux-2.6 diff --git a/include/asm-powerpc/kprobes.h b/include/asm-powerpc/kprobes.h index b0e40ff32e..8b08b447d6 100644 --- a/include/asm-powerpc/kprobes.h +++ b/include/asm-powerpc/kprobes.h @@ -65,20 +65,18 @@ typedef unsigned int kprobe_opcode_t; } else if (name[0] != '.') \ addr = *(kprobe_opcode_t **)addr; \ } else { \ - char dot_name[KSYM_NAME_LEN+1]; \ + char dot_name[KSYM_NAME_LEN]; \ dot_name[0] = '.'; \ dot_name[1] = '\0'; \ - strncat(dot_name, name, KSYM_NAME_LEN); \ + strncat(dot_name, name, KSYM_NAME_LEN - 2); \ addr = (kprobe_opcode_t *)kallsyms_lookup_name(dot_name); \ } \ } -#define JPROBE_ENTRY(pentry) (kprobe_opcode_t *)((func_descr_t *)pentry) #define is_trap(instr) (IS_TW(instr) || IS_TD(instr) || \ IS_TWI(instr) || IS_TDI(instr)) #else /* Use stock kprobe_lookup_name since ppc32 doesn't use function descriptors */ -#define JPROBE_ENTRY(pentry) (kprobe_opcode_t *)(pentry) #define is_trap(instr) (IS_TW(instr) || IS_TWI(instr)) #endif