arm64/debug: More consistent naming for the BRK ESR template macro
authorDave P Martin <Dave.Martin@arm.com>
Fri, 24 Jul 2015 15:37:44 +0000 (16:37 +0100)
committerWill Deacon <will.deacon@arm.com>
Mon, 27 Jul 2015 10:08:42 +0000 (11:08 +0100)
The naming of DBG_ESR_VAL_BRK is inconsistent with the way other
similar macros are named.

This patch makes the naming more consistent, and appends "64"
as a reminder that this ESR pattern only matches from AArch64
state.

Signed-off-by: Dave Martin <Dave.Martin@arm.com>
Acked-by: Mark Rutland <mark.rutland@arm.com>
Acked-by: Catalin Marinas <catalin.marinas@arm.com>
Signed-off-by: Will Deacon <will.deacon@arm.com>
arch/arm64/include/asm/debug-monitors.h
arch/arm64/kernel/kgdb.c

index ff09058587e30857340beb272d96319fe0bc768e..bb97e9d88d23ad99d6a0c66fa7e4de8cf96d877e 100644 (file)
@@ -46,8 +46,9 @@
 /*
  * ESR values expected for dynamic and compile time BRK instruction
  */
-#define DBG_ESR_VAL_BRK(x) \
-       ((ESR_ELx_EC_BRK64 << ESR_ELx_EC_SHIFT) | ESR_ELx_IL | ((x) & 0xffff))
+#define ESR_ELx_VAL_BRK64(imm)                                 \
+       ((ESR_ELx_EC_BRK64 << ESR_ELx_EC_SHIFT) | ESR_ELx_IL |  \
+        ((imm) & 0xffff))
 
 /*
  * #imm16 values used for BRK instruction generation
index a0d10c55f307a5c476c2d644f22a3903aa4b6820..a5a838e72c5eaa51ee2773ee787eafe673d56376 100644 (file)
@@ -235,13 +235,13 @@ static int kgdb_step_brk_fn(struct pt_regs *regs, unsigned int esr)
 
 static struct break_hook kgdb_brkpt_hook = {
        .esr_mask       = 0xffffffff,
-       .esr_val        = DBG_ESR_VAL_BRK(KGDB_DYN_DBG_BRK_IMM),
+       .esr_val        = ESR_ELx_VAL_BRK64(KGDB_DYN_DBG_BRK_IMM),
        .fn             = kgdb_brk_fn
 };
 
 static struct break_hook kgdb_compiled_brkpt_hook = {
        .esr_mask       = 0xffffffff,
-       .esr_val        = DBG_ESR_VAL_BRK(KGDB_COMPILED_DBG_BRK_IMM),
+       .esr_val        = ESR_ELx_VAL_BRK64(KGDB_COMPILED_DBG_BRK_IMM),
        .fn             = kgdb_compiled_brk_fn
 };
 
This page took 0.025882 seconds and 5 git commands to generate.