Commit Graph

32 Commits

Author SHA1 Message Date
Sebastian Huber
ca4602e914 Use linker set for libio initialization
Update #2408.
2016-02-03 10:00:57 +01:00
Sebastian Huber
4719019486 drvmgr: Remove dupl bsp_driver_level_hook() decl 2016-01-26 11:41:28 +01:00
Sebastian Huber
d0c3983814 Use linker set for system initialization
Make rtems_initialize_data_structures(),
rtems_initialize_before_drivers() and rtems_initialize_device_drivers()
static.  Rename rtems_initialize_start_multitasking() to
rtems_initialize_executive() and call the registered system
initialization handlers in this function.  Add system initialization API
available via #include <rtems/sysinit.h>.  Update the documentation
accordingly.

This is no functional change, only the method to call the existing
initialization routines changes.  Instead of direct function calls a
table of function pointers contained in the new RTEMS system
initialization linker set is used.  This table looks like this (the
actual addresses depend on the target).

nm *.exe | grep _Linker | sort
0201a2d0 D _Linker_set__Sysinit_begin
0201a2d0 D _Linker_set__Sysinit_bsp_work_area_initialize
0201a2d4 D _Linker_set__Sysinit_bsp_start
0201a2d8 D _Linker_set__Sysinit_rtems_initialize_data_structures
0201a2dc D _Linker_set__Sysinit_bsp_libc_init
0201a2e0 D _Linker_set__Sysinit_rtems_initialize_before_drivers
0201a2e4 D _Linker_set__Sysinit_bsp_predriver_hook
0201a2e8 D _Linker_set__Sysinit_rtems_initialize_device_drivers
0201a2ec D _Linker_set__Sysinit_bsp_postdriver_hook
0201a2f0 D _Linker_set__Sysinit_end

Add test sptests/spsysinit01.

Update #2408.
2015-12-11 08:17:16 +01:00
Sebastian Huber
2858939a2c bsps: Delete superfluous bsp_pretasking_hook()
Use the bsp_predriver_hook() instead.

Update #2408.
2015-12-10 08:32:37 +01:00
Sebastian Huber
37030e38c6 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.
2015-12-10 08:32:36 +01:00
Sebastian Huber
8054b1c718 Remove <rtems/debug.h>
Close #2477.
2015-12-07 13:11:07 +01:00
Sebastian Huber
143696acbd basedefs.h: Add and use RTEMS_NO_RETURN 2015-10-26 09:13:19 +01:00
Daniel Hellstrom
e7fade3ac4 DRVMGR: added driver manager to cpukit/libdrvmgr 2015-04-17 01:10:16 +02:00
Sebastian Huber
fa0a9a1893 bsps: Declare bsp_start_on_secondary_processors() 2014-05-12 09:32:20 +02:00
Chris Johns
c49985691f Change all references of rtems.com to rtems.org. 2014-03-21 08:10:47 +11:00
Daniel Ramirez
296c74e643 doxygen: refactored doxygen in libbsp to illustrate new rule set 2013-12-09 15:27:02 -05:00
Sebastian Huber
d56f76ac93 bsps: Fix header includes 2013-08-27 10:48:16 +02:00
Sebastian Huber
ade27c69eb bsps: Move bsp_generic_fatal_code to new file
Add bsp_generic_fatal().
2013-06-21 10:26:10 +02:00
Sebastian Huber
48bff53b3d score: rtems_initialize_start_multitasking()
Do not return from rtems_initialize_start_multitasking() and call
rtems_fatal() instead with a fatal source of RTEMS_FATAL_SOURCE_EXIT and
a fatal code with the exit status.

Remove all bsp_cleanup() functions.  The boot_card() is now a no return
function.
2012-12-07 09:38:41 +01:00
Sebastian Huber
facf83625b bsps: Add BSP_GENERIC_FATAL_SPURIOUS_INTERRUPT
Use rtems_fatal() instead of bsp_cleanup().
2012-12-07 09:38:41 +01:00
Sebastian Huber
b1e8a580bc bsps/powerpc: Exception initialization error is fatal 2012-11-15 15:33:13 +01:00
Sebastian Huber
dd8df59413 bsps: Interrupt initialization error is fatal 2012-11-15 15:33:13 +01:00
Sebastian Huber
c118a6e5ff bsps: Add bsp_work_area_initialize_with_table() 2012-10-25 14:54:06 +02:00
Sebastian Huber
47a3cd8f73 score: Work area initialization API change
The work areas (RTEMS work space and C program heap) will be initialized
now in a separate step and are no longer part of
rtems_initialize_data_structures().  Initialization is performed with
tables of Heap_Area entries.  This allows usage of scattered memory
areas present on various small scale micro-controllers.

The sbrk() support API changes also.  The bsp_sbrk_init() must now deal
with a minimum size for the first memory chunk to take the configured
work space size into account.
2012-10-25 14:54:06 +02:00
Joel Sherrill
0e27119f80 Use proper 3 line form of license text 2012-10-11 15:52:51 -05:00
Joel Sherrill
9b4422a251 Remove All CVS Id Strings Possible Using a Script
Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines
  next to each other after Id string line removed.
+ remove entire comment blocks which only exited to
  contain CVS Ids
+ If the processing left a blank line at the top of
  a file, it was removed.
2012-05-11 08:44:13 -05:00
Joel Sherrill
1e1ee0c017 2011-07-13 Joel Sherrill <joel.sherrilL@OARcorp.com>
PR 1824/cpukit
	* bootcard.c, bspclean.c, include/bootcard.h: Return exit/shutdown
	status back to boot_card(). boot_card() propagates this to
	bsp_cleanup() and returns it to the assembly that started the
	application.
2011-07-13 18:35:04 +00:00
Till Straumann
4f599ed99f 2011-05-18 Till Straumann <strauman@slac.stanford.edu>
PR1797/bsps: Applied cleaned-up version of Kate's patch.
	CONFIGURE_MALLOC_BSP_SUPPORTS_SBRK is now a 'bspopts.h'
	setting and as such configurable.
2011-05-18 05:26:53 +00:00
Sebastian Huber
2984b7c19f 2010-04-30 Sebastian Huber <sebastian.huber@embedded-brains.de>
* include/bootcard.h: Documentation.
2010-04-30 11:17:49 +00:00
Joel Sherrill
8634637d1d 2009-09-08 Sebastian Huber <sebastian.huber@embedded-brains.de>
* include/irq-config.h, include/irq-generic.h, include/irq-info.h,
	src/irq-generic.c, src/irq-info.c, src/irq-legacy.c, src/irq-shell.c:
	Format, cleanup and documentation.
	* src/irq-server.c: New file.
	* include/bootcard.h, include/stackalloc.h, src/stackalloc.c,
	bsplibc.c: Update for heap API changes. Documentation.
2009-09-08 13:35:07 +00:00
Joel Sherrill
5ab278ff9e 2009-05-08 Joel Sherrill <joel.sherrill@oarcorp.com>
* bootcard.c, bspgetworkarea.c, include/bootcard.h: Switch from ssize_t
	to uintptr_t for bsp_get_work_area() since the work area is larger
	than a single allocatable object.
2009-05-08 13:24:27 +00:00
Chris Johns
2549b4d9a8 2009-04-28 Chris Johns <chrisj@rtems.org>
* bootcard.c, include/bootcard.h: Remove argc/argv/envp and
        replace with a single BSP boot command line a BSP can optionally
        support.
2009-04-28 06:34:38 +00:00
Joel Sherrill
61814f978e 2008-10-02 Joel Sherrill <joel.sherrill@oarcorp.com>
* bootcard.c, bspgetworkarea.c, bsppretaskinghook.c,
	include/bootcard.h: Change size_t to ssize_t on bsp_get_work_area().
	On 16-bit architectures, size_t can be 16-bits which would limit the
	work area to 64K.
2008-10-02 19:13:05 +00:00
Joel Sherrill
0de9fdfb2e 2008-09-23 Joel Sherrill <joel.sherrill@oarcorp.com>
* bootcard.c, include/bootcard.h: Make letting boot_card() handle work
	area allocation mandatory. Rename
	RTEMS_BSP_BOOTCARD_HANDLES_RAM_ALLOCATION to BSP_BOOTCARD_OPTIONS.
2008-09-23 19:53:41 +00:00
Joel Sherrill
54cf1198e3 2008-09-22 Joel Sherrill <joel.sherrill@oarcorp.com>
* bspclean.c, include/bootcard.h: Use standardized bsp_cleanup() which
	can optionally print a message, poll for user to press key, and call
	bsp_reset(). Using this eliminates the various bsp_cleanup()
	implementations which had their own implementation and variety of
	string constants.
	* bspreset.c, bspreset_fatal.c, bspreset_loop.c: New files.
2008-09-22 21:50:54 +00:00
Joel Sherrill
f3eaba9a0c 2008-08-19 Sebastian Huber <sebastian.huber@embedded-brains.de>
* include/bootcard.h, bootcard.c, bsplibc.c: Changed parameter types of
	bsp_libc_init() to match RTEMS_Malloc_Initialize().
	* bsppost.c, bsppredriverhook.c: Include bootcard.h.
	* src/irq-generic.c: Fixed warnings.
2008-08-19 12:41:03 +00:00
Thomas Doerfler
d4886a0695 Changed bsp_get_workarea() to bsp_get_work_area() and
added support for an optional separate heap area.
2008-07-24 14:52:55 +00:00