mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
[PATCH] i386: Account spinlocks to the caller during profiling for !FP kernels
This ports the algorithm from x86-64 (with improvements) to i386. Previously this only worked for frame pointer enabled kernels. But spinlocks have a very simple stack frame that can be manually analyzed. Do this. Signed-off-by: Andi Kleen <[email protected]>
This commit is contained in:
parent
c16b63e09d
commit
0cb91a2293
3 changed files with 24 additions and 8 deletions
|
|
@ -80,11 +80,7 @@ static inline int user_mode_vm(struct pt_regs *regs)
|
|||
return ((regs->xcs & 3) | (regs->eflags & VM_MASK)) != 0;
|
||||
}
|
||||
#define instruction_pointer(regs) ((regs)->eip)
|
||||
#if defined(CONFIG_SMP) && defined(CONFIG_FRAME_POINTER)
|
||||
extern unsigned long profile_pc(struct pt_regs *regs);
|
||||
#else
|
||||
#define profile_pc(regs) instruction_pointer(regs)
|
||||
#endif
|
||||
#endif /* __KERNEL__ */
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Reference in a new issue