mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-30 15:52:12 +01:00
openocd: move to newer openocd (dec6b913)
This update fixes flash writing on F4 chips
This commit is contained in:
parent
3c92e1cbcf
commit
c0c38609ec
4
Makefile
4
Makefile
@ -231,7 +231,7 @@ openocd_install: openocd_clean
|
||||
|
||||
openocd_git_install: | $(DL_DIR) $(TOOLS_DIR)
|
||||
openocd_git_install: OPENOCD_URL := git://openocd.git.sourceforge.net/gitroot/openocd/openocd
|
||||
openocd_git_install: OPENOCD_REV := bce7009e31b23250d4325637c7b7cdbae0efed9a
|
||||
openocd_git_install: OPENOCD_REV := dec6b913809bd3f857af31be178ffde65e42dbab
|
||||
openocd_git_install: openocd_clean
|
||||
# download the source
|
||||
$(V0) @echo " DOWNLOAD $(OPENOCD_URL) @ $(OPENOCD_REV)"
|
||||
@ -263,7 +263,7 @@ openocd_git_install: openocd_clean
|
||||
)
|
||||
|
||||
# delete the extracted source when we're done
|
||||
$(V1) [ ! -d "$(DL_DIR)/openocd-build" ] || $(RM) -r "$(DL_DIR)/openocd-build"
|
||||
$(V1) [ ! -d "$(DL_DIR)/openocd-build" ] || $(RM) -rf "$(DL_DIR)/openocd-build"
|
||||
|
||||
.PHONY: openocd_clean
|
||||
openocd_clean:
|
||||
|
@ -1,58 +1,58 @@
|
||||
From 7a8a1dbf856a2183c91f441cfdd2eee5b3d9151b Mon Sep 17 00:00:00 2001
|
||||
From 8fd5040df32511f57b898bdbff412f61fbe28516 Mon Sep 17 00:00:00 2001
|
||||
From: Stacey Sheldon <stac@solidgoldbomb.org>
|
||||
Date: Thu, 2 Feb 2012 22:42:03 -0500
|
||||
Subject: [PATCH 1/2] armv7m: remove dummy FP regs for new gdb
|
||||
|
||||
---
|
||||
src/rtos/rtos_standard_stackings.c | 6 ++++++
|
||||
src/rtos/rtos_standard_stackings.c | 7 +++++++
|
||||
src/target/armv7m.c | 16 ++++++++++++++++
|
||||
2 files changed, 22 insertions(+), 0 deletions(-)
|
||||
2 files changed, 23 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/src/rtos/rtos_standard_stackings.c b/src/rtos/rtos_standard_stackings.c
|
||||
index 278d3ef..7ef4659 100644
|
||||
index 30d9cd9..6ea6565 100644
|
||||
--- a/src/rtos/rtos_standard_stackings.c
|
||||
+++ b/src/rtos/rtos_standard_stackings.c
|
||||
@@ -41,6 +41,7 @@ static const struct stack_register_offset rtos_standard_Cortex_M3_stack_offsets[
|
||||
{ -2, 32 }, /* sp */
|
||||
{ 0x34, 32 }, /* lr */
|
||||
{ 0x38, 32 }, /* pc */
|
||||
{ -2, 32 }, /* sp */
|
||||
{ 0x34, 32 }, /* lr */
|
||||
{ 0x38, 32 }, /* pc */
|
||||
+#ifdef USE_DUMMY_FP_REGS
|
||||
{ -1, 96 }, /* FPA1 */
|
||||
{ -1, 96 }, /* FPA2 */
|
||||
{ -1, 96 }, /* FPA3 */
|
||||
@@ -50,6 +51,7 @@ static const struct stack_register_offset rtos_standard_Cortex_M3_stack_offsets[
|
||||
{ -1, 96 }, /* FPA7 */
|
||||
{ -1, 96 }, /* FPA8 */
|
||||
{ -1, 32 }, /* FPS */
|
||||
{ -1, 96 }, /* FPA1 */
|
||||
{ -1, 96 }, /* FPA2 */
|
||||
{ -1, 96 }, /* FPA3 */
|
||||
@@ -50,13 +51,19 @@ static const struct stack_register_offset rtos_standard_Cortex_M3_stack_offsets[
|
||||
{ -1, 96 }, /* FPA7 */
|
||||
{ -1, 96 }, /* FPA8 */
|
||||
{ -1, 32 }, /* FPS */
|
||||
+#endif
|
||||
{ 0x3c, 32 }, /* xPSR */
|
||||
{ 0x3c, 32 }, /* xPSR */
|
||||
};
|
||||
|
||||
@@ -58,7 +60,11 @@ const struct rtos_register_stacking rtos_standard_Cortex_M3_stacking =
|
||||
{
|
||||
0x40, /* stack_registers_size */
|
||||
-1, /* stack_growth_direction */
|
||||
+
|
||||
const struct rtos_register_stacking rtos_standard_Cortex_M3_stacking = {
|
||||
0x40, /* stack_registers_size */
|
||||
-1, /* stack_growth_direction */
|
||||
+#ifdef USE_DUMMY_FP_REGS
|
||||
26, /* num_output_registers */
|
||||
26, /* num_output_registers */
|
||||
+#else
|
||||
+ 17,
|
||||
+#endif
|
||||
8, /* stack_alignment */
|
||||
rtos_standard_Cortex_M3_stack_offsets /* register_offsets */
|
||||
8, /* stack_alignment */
|
||||
rtos_standard_Cortex_M3_stack_offsets /* register_offsets */
|
||||
};
|
||||
diff --git a/src/target/armv7m.c b/src/target/armv7m.c
|
||||
index 6c1732e..7bb53c7 100644
|
||||
index 258653e..50b26d4 100644
|
||||
--- a/src/target/armv7m.c
|
||||
+++ b/src/target/armv7m.c
|
||||
@@ -272,6 +272,7 @@ int armv7m_get_gdb_reg_list(struct target *target, struct reg **reg_list[], int
|
||||
@@ -267,6 +267,7 @@ int armv7m_get_gdb_reg_list(struct target *target, struct reg **reg_list[], int
|
||||
struct armv7m_common *armv7m = target_to_armv7m(target);
|
||||
int i;
|
||||
|
||||
+#ifdef USE_DUMMY_FP_REGS
|
||||
*reg_list_size = 26;
|
||||
*reg_list = malloc(sizeof(struct reg*) * (*reg_list_size));
|
||||
*reg_list = malloc(sizeof(struct reg *) * (*reg_list_size));
|
||||
|
||||
@@ -302,6 +303,21 @@ int armv7m_get_gdb_reg_list(struct target *target, struct reg **reg_list[], int
|
||||
@@ -295,6 +296,21 @@ int armv7m_get_gdb_reg_list(struct target *target, struct reg **reg_list[], int
|
||||
(*reg_list)[25] = &armv7m->core_cache->reg_list[ARMV7M_xPSR];
|
||||
#endif
|
||||
|
||||
|
@ -1,34 +1,35 @@
|
||||
From fceb681b4421dd00eb47085990b77c0f0716517d Mon Sep 17 00:00:00 2001
|
||||
From e29b134e142cd759c85de4ea7c26084e87380ce1 Mon Sep 17 00:00:00 2001
|
||||
From: Stacey Sheldon <stac@solidgoldbomb.org>
|
||||
Date: Thu, 2 Feb 2012 22:42:26 -0500
|
||||
Subject: [PATCH 2/2] rtos: add stm32_stlink to FreeRTOS targets
|
||||
|
||||
---
|
||||
src/rtos/FreeRTOS.c | 11 +++++++++++
|
||||
1 files changed, 11 insertions(+), 0 deletions(-)
|
||||
src/rtos/FreeRTOS.c | 12 ++++++++++++
|
||||
1 files changed, 12 insertions(+), 0 deletions(-)
|
||||
|
||||
diff --git a/src/rtos/FreeRTOS.c b/src/rtos/FreeRTOS.c
|
||||
index eeab134..e57806e 100644
|
||||
index c7b4643..e99d471 100644
|
||||
--- a/src/rtos/FreeRTOS.c
|
||||
+++ b/src/rtos/FreeRTOS.c
|
||||
@@ -63,6 +63,17 @@ const struct FreeRTOS_params FreeRTOS_params_list[] =
|
||||
0, // thread_stack_offset;
|
||||
52, // thread_name_offset;
|
||||
&rtos_standard_Cortex_M3_stacking, // stacking_info
|
||||
+ },
|
||||
+ { "stm32_stlink", // target_name
|
||||
+ 4, // thread_count_width;
|
||||
+ 4, // pointer_width;
|
||||
+ 16, // list_next_offset;
|
||||
+ 20, // list_width;
|
||||
+ 8, // list_elem_next_offset;
|
||||
+ 12, // list_elem_content_offset
|
||||
+ 0, // thread_stack_offset;
|
||||
+ 52, // thread_name_offset;
|
||||
+ &rtos_standard_Cortex_M3_stacking, // stacking_info
|
||||
}
|
||||
|
||||
@@ -57,6 +57,18 @@ const struct FreeRTOS_params FreeRTOS_params_list[] = {
|
||||
0, /* thread_stack_offset; */
|
||||
52, /* thread_name_offset; */
|
||||
&rtos_standard_Cortex_M3_stacking, /* stacking_info */
|
||||
+ },
|
||||
+ {
|
||||
+ "stm32_stlink", /* target_name */
|
||||
+ 4, /* thread_count_width; */
|
||||
+ 4, /* pointer_width; */
|
||||
+ 16, /* list_next_offset; */
|
||||
+ 20, /* list_width; */
|
||||
+ 8, /* list_elem_next_offset; */
|
||||
+ 12, /* list_elem_content_offset */
|
||||
+ 0, /* thread_stack_offset; */
|
||||
+ 52, /* thread_name_offset; */
|
||||
+ &rtos_standard_Cortex_M3_stacking, /* stacking_info */
|
||||
}
|
||||
};
|
||||
|
||||
--
|
||||
1.7.1
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user