Skip to contentSkip to conversation

arch/unicore32/include/asm/ptrace.h: add generic definition for profile_pc()

PATCH In review Chen Gang 2 participants 3 messages Mar 24, 2014 – Mar 25, 2014 ptrace support

lore
Share & tools
lore

Chen Gang

author
#0 lore raw

PATCH 1/1 arch/unicore32/include/asm/ptrace.h: add generic definition for profile_pc()

Add generic definition just like another architectures have done, or can not pass compiling with allmodconfig, the related error:

CC kernel/profile.o
kernel/profile.c: In function ‘profile_tick’:
kernel/profile.c:419: error: implicit declaration of function ‘profile_pc’ make[1]: *** [kernel/profile.o] Error 1
make: *** [kernel] Error 2

---
 arch/unicore32/include/asm/ptrace.h |    1 +
 1 file changed, 1 insertion(+)
arch/unicore32/include/asm/ptrace.h +1 -0
index 9df53d9..02bf5a4 100644
@@ -55,6 +55,7 @@ static inline int valid_user_regs(struct pt_regs *regs)
 
 #define instruction_pointer(regs)	((regs)->UCreg_pc)
 #define user_stack_pointer(regs)	((regs)->UCreg_sp)
+#define profile_pc(regs)		instruction_pointer(regs)
 
 #endif /* __ASSEMBLY__ */
 #endif
Signature · 1 line
1.7.9.5
Acked-by Xuetao Guan on v1 1/1
#1 lore raw

Thanks

Quoted 29 lines · ----- Chen Gang

Add generic definition just like another architectures have done, or can not pass compiling with allmodconfig, the related error:

CC kernel/profile.o
kernel/profile.c: In function ‘profile_tick’:
kernel/profile.c:419: error: implicit declaration of function ‘profile_pc’ make[1]: *** [kernel/profile.o] Error 1
make: *** [kernel] Error 2

---
 arch/unicore32/include/asm/ptrace.h |    1 +
 1 file changed, 1 insertion(+)
arch/unicore32/include/asm/ptrace.h +1 -0
index 9df53d9..02bf5a4 100644
@@ -55,6 +55,7 @@ static inline int valid_user_regs(struct pt_regs *regs)
 
 #define instruction_pointer(regs)	((regs)->UCreg_pc)
 #define user_stack_pointer(regs)	((regs)->UCreg_sp)
+#define profile_pc(regs)		instruction_pointer(regs)
 
 #endif /* __ASSEMBLY__ */
 #endif
Signature · 1 line
1.7.9.5
author
#2 lore raw
Quoted 4 lines · 管雪涛

Thanks

Thank you too.

Quoted 31 lines
Quoted 29 lines · ----- Chen Gang

Add generic definition just like another architectures have done, or can not pass compiling with allmodconfig, the related error:

CC kernel/profile.o
kernel/profile.c: In function ‘profile_tick’:
kernel/profile.c:419: error: implicit declaration of function ‘profile_pc’ make[1]: *** [kernel/profile.o] Error 1
make: *** [kernel] Error 2

---
 arch/unicore32/include/asm/ptrace.h |    1 +
 1 file changed, 1 insertion(+)
arch/unicore32/include/asm/ptrace.h +1 -0
index 9df53d9..02bf5a4 100644
@@ -55,6 +55,7 @@ static inline int valid_user_regs(struct pt_regs *regs)
 
 #define instruction_pointer(regs)	((regs)->UCreg_pc)
 #define user_stack_pointer(regs)	((regs)->UCreg_sp)
+#define profile_pc(regs)		instruction_pointer(regs)
 
 #endif /* __ASSEMBLY__ */
 #endif
Signature · 1 line
1.7.9.5
Signature · 3 lines
Chen Gang

Open, share, and attitude like air, water, and life which God blessed