summaryrefslogtreecommitdiffstats
path: root/c/src/lib/libbsp/shared
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2015-12-09 08:05:57 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2015-12-10 08:32:36 +0100
commit37030e38c61c0d0a8b0742af75f115bda779c46d (patch)
treed71cd94cf9d534fd606fffd50a0f3256cc822be9 /c/src/lib/libbsp/shared
parentbsps/sparc: Use default bsp_pretasking_hook() (diff)
downloadrtems-37030e38.tar.bz2
bsps: Call bsp_work_area_initialize() early
Call bsp_work_area_initialize() before bsp_start(). This allows bsp_start() to use malloc() etc. which is beneficial for systems with a plug-and-play hardware enumeration. Update #2408.
Diffstat (limited to 'c/src/lib/libbsp/shared')
-rw-r--r--c/src/lib/libbsp/shared/bootcard.c8
-rw-r--r--c/src/lib/libbsp/shared/include/bootcard.h2
2 files changed, 5 insertions, 5 deletions
diff --git a/c/src/lib/libbsp/shared/bootcard.c b/c/src/lib/libbsp/shared/bootcard.c
index eeb5746fca..cbeb7b2686 100644
--- a/c/src/lib/libbsp/shared/bootcard.c
+++ b/c/src/lib/libbsp/shared/bootcard.c
@@ -75,14 +75,14 @@ void boot_card(
bsp_boot_cmdline = cmdline;
/*
- * Invoke Board Support Package initialization routine written in C.
+ * Initialize the RTEMS Workspace and the C Program Heap.
*/
- bsp_start();
+ bsp_work_area_initialize();
/*
- * Initialize the RTEMS Workspace and the C Program Heap.
+ * Invoke Board Support Package initialization routine written in C.
*/
- bsp_work_area_initialize();
+ bsp_start();
/*
* Initialize RTEMS data structures
diff --git a/c/src/lib/libbsp/shared/include/bootcard.h b/c/src/lib/libbsp/shared/include/bootcard.h
index 93d5041cb4..7c0d3f154e 100644
--- a/c/src/lib/libbsp/shared/include/bootcard.h
+++ b/c/src/lib/libbsp/shared/include/bootcard.h
@@ -78,9 +78,9 @@ void bsp_reset(void);
*
* - disable interrupts, interrupts will be enabled during the first context
* switch
- * - bsp_start() - more advanced initialization
* - bsp_work_area_initialize() - initialize the RTEMS Workspace and the C
* Program Heap
+ * - bsp_start() - more advanced initialization
* - rtems_initialize_data_structures()
* - initialize C Library
* - bsp_pretasking_hook()