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
89a8bd84
Commit
89a8bd84
authored
11 years ago
by
Gregory Nutt
Browse files
Options
Downloads
Patches
Plain Diff
Updated NOR boot logic from David Sidrane
parent
52f114a1
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
configs/sama5d3x-ek/src/nor_main.c
+13
-12
13 additions, 12 deletions
configs/sama5d3x-ek/src/nor_main.c
with
13 additions
and
12 deletions
configs/sama5d3x-ek/src/nor_main.c
+
13
−
12
View file @
89a8bd84
/*****************************************************************************
* configs/sama5d3x-ek/src/nor_main.c
*
* Copyright (C) 2013 Gregory Nutt. All rights reserved.
* Copyright (C) 2013
-2014
Gregory Nutt. All rights reserved.
* Author: Gregory Nutt <gnutt@nuttx.org>
*
* Redistribution and use in source and binary forms, with or without
...
...
@@ -61,6 +61,15 @@
#define NOR_ENTRY ((nor_entry_t)SAM_EBICS0_VSECTION)
#define NOR_WAIT 1
#define NOR_NO_WAIT 0
#ifdef CONFIG_SAMA5D3xEK_NOR_START
# define NOR_BOOT_MODE NOR_NO_WAIT
#else
# define NOR_BOOT_MODE NOR_WAIT
#endif
/****************************************************************************
* Private Types
****************************************************************************/
...
...
@@ -92,16 +101,9 @@ int nor_main(int argc, char *argv)
* to begin booting in NOR Flash
*/
static
volatile
uint32_t
wait
=
1
;
static
volatile
uint32_t
wait
=
NOR_BOOT_MODE
;
#ifdef CONFIG_SAMA5D3xEK_NOR_START
printf
(
"Configuring and booting from NOR FLASH on CS0
\n
"
);
wait
=
0
;
#else
printf
(
"Configuring NOR FLASH on CS0 and waiting
\n
"
);
wait
=
1
;
#endif
printf
(
"Configuring NOR FLASH on CS0 and %s
\n
"
,
wait
?
"waiting"
:
"booting"
);
/* Make sure that the SMC peripheral is enabled (But of course it is... we
* are executing from NOR FLASH now).
...
...
@@ -191,12 +193,11 @@ int nor_main(int argc, char *argv)
/* Then jump into NOR flash */
while
(
!
wait
)
while
(
wait
)
{
}
NOR_ENTRY
();
return
0
;
/* We should not get here in either case */
}
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