On 22/10/15 09:00, Chris Johns wrote:
In the mean time could linker sets be used in drivers or BSPs to declare
a table of "resources" they need and these are added to the confdefs.h
defined values during initialisation?

Yes, this would probably work. You should however compare the complexity of

1) linker sets
    + dynamic workspace size changes
+ static pre-processor based workspace size estimate (just look at the pre-processed output of confdefs.h)
    + workspace (heap)
    + objects
    + side-effects, e.g. subsystem which doesn't account for its resources
    + initialization order
    + run-time initialization errors

vs.

2) provide some storage (16 bytes for a mutex on a 32-bit target)
+ initialize the object (= initialize storage to zero, no possible errors, may reside in .bss)

--
Sebastian Huber, embedded brains GmbH

Address : Dornierstr. 4, D-82178 Puchheim, Germany
Phone   : +49 89 189 47 41-16
Fax     : +49 89 189 47 41-09
E-Mail  : sebastian.hu...@embedded-brains.de
PGP     : Public key available on request.

Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG.

_______________________________________________
devel mailing list
devel@rtems.org
http://lists.rtems.org/mailman/listinfo/devel

Reply via email to