This is an automated email from Gerrit.

Spencer Oliver ([email protected]) just uploaded a new patch set to Gerrit, 
which you can find at http://openocd.zylin.com/377

-- gerrit

commit 9340d929d35c64f0e5681f06215718d538fb806e
Author: Spencer Oliver <[email protected]>
Date:   Fri Jan 13 10:45:36 2012 +0000

    target: move regmaps to armv7m.c
    
    This move will enable use to share with regmaps with the stlink target.
    
    Change-Id: If8f41c7c53323d5074cb22ec3440530c1e402004
    Signed-off-by: Spencer Oliver <[email protected]>

diff --git a/src/target/armv7m.c b/src/target/armv7m.c
index d8aed89..6c1732e 100644
--- a/src/target/armv7m.c
+++ b/src/target/armv7m.c
@@ -58,6 +58,24 @@ static char *armv7m_exception_strings[] =
        "DebugMonitor", "RESERVED", "PendSV", "SysTick"
 };
 
+/* PSP is used in some thread modes */
+const int armv7m_psp_reg_map[17] = {
+       ARMV7M_R0, ARMV7M_R1, ARMV7M_R2, ARMV7M_R3,
+       ARMV7M_R4, ARMV7M_R5, ARMV7M_R6, ARMV7M_R7,
+       ARMV7M_R8, ARMV7M_R9, ARMV7M_R10, ARMV7M_R11,
+       ARMV7M_R12, ARMV7M_PSP, ARMV7M_R14, ARMV7M_PC,
+       ARMV7M_xPSR,
+};
+
+/* MSP is used in handler and some thread modes */
+const int armv7m_msp_reg_map[17] = {
+       ARMV7M_R0, ARMV7M_R1, ARMV7M_R2, ARMV7M_R3,
+       ARMV7M_R4, ARMV7M_R5, ARMV7M_R6, ARMV7M_R7,
+       ARMV7M_R8, ARMV7M_R9, ARMV7M_R10, ARMV7M_R11,
+       ARMV7M_R12, ARMV7M_MSP, ARMV7M_R14, ARMV7M_PC,
+       ARMV7M_xPSR,
+};
+
 #ifdef ARMV7_GDB_HACKS
 uint8_t armv7m_gdb_dummy_cpsr_value[] = {0, 0, 0, 0};
 
diff --git a/src/target/armv7m.h b/src/target/armv7m.h
index ca92146..aef6b76 100644
--- a/src/target/armv7m.h
+++ b/src/target/armv7m.h
@@ -49,6 +49,8 @@ enum armv7m_mode
 };
 
 extern char *armv7m_mode_strings[];
+extern const int armv7m_psp_reg_map[];
+extern const int armv7m_msp_reg_map[];
 
 enum armv7m_regtype
 {
diff --git a/src/target/cortex_m.c b/src/target/cortex_m.c
index c7cb9d4..6aa3bd6 100644
--- a/src/target/cortex_m.c
+++ b/src/target/cortex_m.c
@@ -406,24 +406,6 @@ static int cortex_m3_examine_exception_reason(struct 
target *target)
        return retval;
 }
 
-/* PSP is used in some thread modes */
-static const int armv7m_psp_reg_map[17] = {
-       ARMV7M_R0, ARMV7M_R1, ARMV7M_R2, ARMV7M_R3,
-       ARMV7M_R4, ARMV7M_R5, ARMV7M_R6, ARMV7M_R7,
-       ARMV7M_R8, ARMV7M_R9, ARMV7M_R10, ARMV7M_R11,
-       ARMV7M_R12, ARMV7M_PSP, ARMV7M_R14, ARMV7M_PC,
-       ARMV7M_xPSR,
-};
-
-/* MSP is used in handler and some thread modes */
-static const int armv7m_msp_reg_map[17] = {
-       ARMV7M_R0, ARMV7M_R1, ARMV7M_R2, ARMV7M_R3,
-       ARMV7M_R4, ARMV7M_R5, ARMV7M_R6, ARMV7M_R7,
-       ARMV7M_R8, ARMV7M_R9, ARMV7M_R10, ARMV7M_R11,
-       ARMV7M_R12, ARMV7M_MSP, ARMV7M_R14, ARMV7M_PC,
-       ARMV7M_xPSR,
-};
-
 static int cortex_m3_debug_entry(struct target *target)
 {
        int i;

-- 

------------------------------------------------------------------------------
RSA(R) Conference 2012
Mar 27 - Feb 2
Save $400 by Jan. 27
Register now!
http://p.sf.net/sfu/rsa-sfdev2dev2
_______________________________________________
OpenOCD-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openocd-devel

Reply via email to