Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ecfd4eff authored by Pushkar Joshi's avatar Pushkar Joshi Committed by Matt Wagantall
Browse files

tracing: ftrace events for user faults and undefined instructions



New ftrace events (user_fault and undef_instr) for data, prefetch
or undefined instruction aborts. The new ftrace events are under
events/exception.

Change-Id: Iea328b71a1f623861cac9b45d858c3bbe09e1b82
Signed-off-by: default avatarPushkar Joshi <pushkarj@codeaurora.org>
[spjoshi@codeaurora.org: fix merge conflict]
Signed-off-by: default avatarSarangdhar Joshi <spjoshi@codeaurora.org>
parent 2e9a85f7
Loading
Loading
Loading
Loading
+3 −0
Original line number Diff line number Diff line
@@ -40,6 +40,7 @@
#include <asm/system_misc.h>
#include <asm/opcodes.h>

#include <trace/events/exception.h>

static const char *handler[]= {
	"prefetch abort",
@@ -446,6 +447,8 @@ asmlinkage void __exception do_undefinstr(struct pt_regs *regs)
		return;

die_sig:
	trace_undef_instr(regs, (void *)pc);

#ifdef CONFIG_DEBUG_USER
	if (user_debug & UDBG_UNDEFINED) {
		printk(KERN_INFO "%s (%d): undefined instruction: pc=%p\n",
+4 −0
Original line number Diff line number Diff line
@@ -28,6 +28,8 @@

#include "fault.h"

#include <trace/events/exception.h>

#ifdef CONFIG_MMU

#ifdef CONFIG_KPROBES
@@ -164,6 +166,8 @@ __do_user_fault(struct task_struct *tsk, unsigned long addr,
{
	struct siginfo si;

	trace_user_fault(tsk, addr, fsr);

#ifdef CONFIG_DEBUG_USER
	if (((user_debug & UDBG_SEGV) && (sig == SIGSEGV)) ||
	    ((user_debug & UDBG_BUS)  && (sig == SIGBUS))) {