summaryrefslogtreecommitdiff
path: root/arch/arm/include
diff options
context:
space:
mode:
authorWill Deacon <will.deacon@arm.com>2010-09-03 10:39:59 +0100
committerVarun Colbert <vcolbert@nvidia.com>2011-05-17 11:52:24 -0700
commit8f12346fe6c4fbfe3a883a22b62b12ad14ffc30d (patch)
tree116bdd5dbb70d23e2fdd61bbe91d83957325cd42 /arch/arm/include
parent4e53747f2a937963c3f54f0519451c91cc478d33 (diff)
ARM: 6355/1: hw-breakpoint: add mechanism for hooking into prefetch aborts
On ARM processors with hardware breakpoint and watchpoint support, triggering these events results in a debug exception. These manifest as prefetch and data aborts respectively. arch/arm/mm/fault.c already provides hook_fault_code for hooking into data aborts dependent on the DFSR. This patch adds a new function, hook_ifault_code for hooking into prefetch aborts in the same manner. This is picked from following git repository: git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-2.6.38.y.git Cc: Frederic Weisbecker <fweisbec@gmail.com> Cc: S. Karthikeyan <informkarthik@gmail.com> Signed-off-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk> (cherry picked from commit 3a4b5dca53aecb16db9e007d782b2d1e757e941a) Change-Id: Ic278bad0e3bb95f504e46b216a8d14fd61fbc4a5 Reviewed-on: http://git-master/r/31574 Reviewed-by: Bo Yan <byan@nvidia.com> Tested-by: Bo Yan <byan@nvidia.com> Reviewed-by: Daniel Willemsen <dwillemsen@nvidia.com> Reviewed-by: Scott Williams <scwilliams@nvidia.com>
Diffstat (limited to 'arch/arm/include')
-rw-r--r--arch/arm/include/asm/system.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/arm/include/asm/system.h b/arch/arm/include/asm/system.h
index 549c9786e0f9..bc2beafb41df 100644
--- a/arch/arm/include/asm/system.h
+++ b/arch/arm/include/asm/system.h
@@ -85,6 +85,10 @@ void hook_fault_code(int nr, int (*fn)(unsigned long, unsigned int,
struct pt_regs *),
int sig, int code, const char *name);
+void hook_ifault_code(int nr, int (*fn)(unsigned long, unsigned int,
+ struct pt_regs *),
+ int sig, int code, const char *name);
+
#define xchg(ptr,x) \
((__typeof__(*(ptr)))__xchg((unsigned long)(x),(ptr),sizeof(*(ptr))))