score: Fix objects local table initialization

The objects local table must be statically zero-initialized so that
_Objects_Get() and _Objects_Get_no_protection() return NULL if no object is
associated with the identifier.

Update #4678.
This commit is contained in:
Sebastian Huber
2022-07-27 08:59:45 +02:00
parent 4f94d47bc5
commit 2501c64bb6
2 changed files with 2 additions and 4 deletions
+1 -2
View File
@@ -447,8 +447,7 @@ Objects_Information name##_Information = { \
* multiprocessing (RTEMS_MULTIPROCESSING) is enabled.
*/
#define OBJECTS_INFORMATION_DEFINE( name, api, cls, type, max, nl, ex ) \
static RTEMS_SECTION( ".noinit.rtems.content.local_table" ) \
Objects_Control * \
static Objects_Control * \
name##_Local_table[ _Objects_Maximum_per_allocation( max ) ]; \
static RTEMS_SECTION( ".noinit.rtems.content.objects" ) \
type \
+1 -2
View File
@@ -1149,8 +1149,7 @@ Thread_Information name##_Information = { \
Objects_Control *_Thread_Allocate_unlimited( Objects_Information *information );
#define THREAD_INFORMATION_DEFINE( name, api, cls, max ) \
static RTEMS_SECTION( ".noinit.rtems.content.local_table" ) \
Objects_Control * \
static Objects_Control * \
name##_Local_table[ _Objects_Maximum_per_allocation( max ) ]; \
static RTEMS_SECTION( ".noinit.rtems.content.objects" ) \
Thread_Configured_control \