Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
openocd
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
External wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
card10
openocd
Commits
6349a47e
Commit
6349a47e
authored
14 years ago
by
Alan Bowman
Committed by
Øyvind Harboe
14 years ago
Browse files
Options
Downloads
Patches
Plain Diff
Correct stacking direction and use of address offset
parent
53c0fb6e
No related branches found
No related tags found
No related merge requests found
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/rtos/rtos.c
+2
-2
2 additions, 2 deletions
src/rtos/rtos.c
src/rtos/rtos_standard_stackings.c
+1
-1
1 addition, 1 deletion
src/rtos/rtos_standard_stackings.c
with
3 additions
and
3 deletions
src/rtos/rtos.c
+
2
−
2
View file @
6349a47e
...
@@ -533,7 +533,7 @@ int rtos_generic_stack_read( struct target * target, const struct rtos_register_
...
@@ -533,7 +533,7 @@ int rtos_generic_stack_read( struct target * target, const struct rtos_register_
{
{
address
-=
stacking
->
stack_registers_size
;
address
-=
stacking
->
stack_registers_size
;
}
}
retval
=
target_read_buffer
(
target
,
stack_ptr
,
stacking
->
stack_registers_size
,
stack_data
);
retval
=
target_read_buffer
(
target
,
address
,
stacking
->
stack_registers_size
,
stack_data
);
if
(
retval
!=
ERROR_OK
)
if
(
retval
!=
ERROR_OK
)
{
{
LOG_OUTPUT
(
"Error reading stack frame from FreeRTOS thread
\r\n
"
);
LOG_OUTPUT
(
"Error reading stack frame from FreeRTOS thread
\r\n
"
);
...
@@ -553,7 +553,7 @@ int rtos_generic_stack_read( struct target * target, const struct rtos_register_
...
@@ -553,7 +553,7 @@ int rtos_generic_stack_read( struct target * target, const struct rtos_register_
}
}
*
hex_reg_list
=
(
char
*
)
malloc
(
list_size
*
2
+
1
);
*
hex_reg_list
=
(
char
*
)
malloc
(
list_size
*
2
+
1
);
tmp_str_ptr
=
*
hex_reg_list
;
tmp_str_ptr
=
*
hex_reg_list
;
new_stack_ptr
=
stack_ptr
+
stacking
->
stack_growth_direction
*
stacking
->
stack_registers_size
;
new_stack_ptr
=
stack_ptr
-
stacking
->
stack_growth_direction
*
stacking
->
stack_registers_size
;
for
(
i
=
0
;
i
<
stacking
->
num_output_registers
;
i
++
)
for
(
i
=
0
;
i
<
stacking
->
num_output_registers
;
i
++
)
{
{
int
j
;
int
j
;
...
...
This diff is collapsed.
Click to expand it.
src/rtos/rtos_standard_stackings.c
+
1
−
1
View file @
6349a47e
...
@@ -57,7 +57,7 @@ static const struct stack_register_offset rtos_standard_Cortex_M3_stack_offsets
...
@@ -57,7 +57,7 @@ static const struct stack_register_offset rtos_standard_Cortex_M3_stack_offsets
const
struct
rtos_register_stacking
rtos_standard_Cortex_M3_stacking
=
const
struct
rtos_register_stacking
rtos_standard_Cortex_M3_stacking
=
{
{
0x40
,
// stack_registers_size
0x40
,
// stack_registers_size
1
,
// stack_growth_direction
-
1
,
// stack_growth_direction
26
,
// num_output_registers
26
,
// num_output_registers
rtos_standard_Cortex_M3_stack_offsets
// register_offsets
rtos_standard_Cortex_M3_stack_offsets
// register_offsets
};
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment