Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
NuttX RTOS
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Container Registry
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
f4grx
NuttX RTOS
Commits
f454b38d
Commit
f454b38d
authored
8 years ago
by
Gregory Nutt
Browse files
Options
Downloads
Patches
Plain Diff
ARMv7-A SMP: Allow CONFIG_SMP_NCPUS=1 for testing purposes
parent
32838fcc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
arch/arm/src/armv7-a/arm_cpuidlestack.c
+6
-2
6 additions, 2 deletions
arch/arm/src/armv7-a/arm_cpuidlestack.c
configs/sabre-6quad/README.txt
+4
-0
4 additions, 0 deletions
configs/sabre-6quad/README.txt
with
10 additions
and
2 deletions
arch/arm/src/armv7-a/arm_cpuidlestack.c
+
6
−
2
View file @
f454b38d
...
...
@@ -47,7 +47,7 @@
#include
"smp.h"
#include
"up_internal.h"
#if
def
ined(CONFIG_SMP) &&
CONFIG_SMP
_NCPUS > 1
#ifdef CONFIG_SMP
/****************************************************************************
* Pre-processor Definitions
...
...
@@ -61,6 +61,7 @@
* Private Data
****************************************************************************/
#if CONFIG_SMP_NCPUS > 1
static
FAR
const
uint32_t
*
g_cpu_stackalloc
[
CONFIG_SMP_NCPUS
]
=
{
0
...
...
@@ -72,6 +73,7 @@ static FAR const uint32_t *g_cpu_stackalloc[CONFIG_SMP_NCPUS] =
#endif
/* CONFIG_SMP_NCPUS > 3 */
#endif
/* CONFIG_SMP_NCPUS > 2 */
};
#endif
/****************************************************************************
* Public Functions
...
...
@@ -122,6 +124,7 @@ static FAR const uint32_t *g_cpu_stackalloc[CONFIG_SMP_NCPUS] =
int
up_cpu_idlestack
(
int
cpu
,
FAR
struct
tcb_s
*
tcb
,
size_t
stack_size
)
{
#if CONFIG_SMP_NCPUS > 1
uintptr_t
stack_alloc
;
uintptr_t
top_of_stack
;
...
...
@@ -138,8 +141,9 @@ int up_cpu_idlestack(int cpu, FAR struct tcb_s *tcb, size_t stack_size)
tcb
->
adj_stack_size
=
SMP_STACK_SIZE
;
tcb
->
stack_alloc_ptr
=
(
FAR
uint32_t
*
)
stack_alloc
;
tcb
->
adj_stack_ptr
=
(
FAR
uint32_t
*
)
top_of_stack
;
#endif
return
OK
;
}
#endif
/* CONFIG_SMP
&& CONFIG_SMP_NCPUS > 1
*/
#endif
/* CONFIG_SMP */
This diff is collapsed.
Click to expand it.
configs/sabre-6quad/README.txt
+
4
−
0
View file @
f454b38d
...
...
@@ -63,6 +63,10 @@ logic.
At this point, I would say that the basic NSH port is complete.
2016-05-18: Started looking at the SMP configuration. Initially, I verfied
that the NSH configuration works with CONFIG_SMP_NCPUS=1. Not a very
interesting case, but this does exercise a lot of the basic SMP logic.
Platform Features
=================
...
...
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