Changeset f4fee477 in rtems


Ignore:
Timestamp:
Dec 14, 2015, 3:29:19 PM (4 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
9871f5dc
Parents:
cef5675
git-author:
Sebastian Huber <sebastian.huber@…> (12/14/15 15:29:19)
git-committer:
Sebastian Huber <sebastian.huber@…> (02/03/16 09:00:55)
Message:

Optional POSIX Condition Variable initialization

Update #2408.

Files:
5 edited

Legend:

Unmodified
Added
Removed
  • cpukit/posix/include/rtems/posix/condimpl.h

    rcef5675 rf4fee477  
    3737 *  this class of objects.
    3838 */
    39 POSIX_EXTERN Objects_Information _POSIX_Condition_variables_Information;
     39extern Objects_Information _POSIX_Condition_variables_Information;
    4040
    4141/**
     
    4343 */
    4444extern const pthread_condattr_t _POSIX_Condition_variables_Default_attributes;
    45 
    46 /**
    47  *  @brief POSIX Condition Variable Manager Initialization
    48  *
    49  *  This routine performs the initialization necessary for this manager.
    50  */
    51 void _POSIX_Condition_variables_Manager_initialization(void);
    5245
    5346/**
  • cpukit/posix/src/cond.c

    rcef5675 rf4fee477  
    2525#include <rtems/system.h>
    2626#include <rtems/config.h>
     27#include <rtems/sysinit.h>
    2728#include <rtems/score/watchdog.h>
    2829#include <rtems/posix/condimpl.h>
    2930#include <rtems/posix/muteximpl.h>
     31
     32Objects_Information _POSIX_Condition_variables_Information;
    3033
    3134/*
     
    4043 */
    4144
    42 void _POSIX_Condition_variables_Manager_initialization(void)
     45static void _POSIX_Condition_variables_Manager_initialization(void)
    4346{
    4447  _Objects_Initialize_information(
     
    5962  );
    6063}
     64
     65RTEMS_SYSINIT_ITEM(
     66  _POSIX_Condition_variables_Manager_initialization,
     67  RTEMS_SYSINIT_POSIX_CONDITION_VARIABLE,
     68  RTEMS_SYSINIT_ORDER_MIDDLE
     69);
  • cpukit/sapi/src/posixapi.c

    rcef5675 rf4fee477  
    3434#include <rtems/posix/barrierimpl.h>
    3535#include <rtems/posix/config.h>
    36 #include <rtems/posix/condimpl.h>
    3736#include <rtems/posix/mqueueimpl.h>
    3837#include <rtems/posix/muteximpl.h>
     
    6463
    6564  #ifdef RTEMS_POSIX_API
    66     _POSIX_Condition_variables_Manager_initialization();
    6765    _POSIX_Mutex_Manager_initialization();
    6866    _POSIX_Message_queue_Manager_initialization();
  • cpukit/score/include/rtems/sysinit.h

    rcef5675 rf4fee477  
    4545#define RTEMS_SYSINIT_POSIX_SIGNALS              000360
    4646#define RTEMS_SYSINIT_POSIX_THREADS              000361
     47#define RTEMS_SYSINIT_POSIX_CONDITION_VARIABLE   000362
    4748#define RTEMS_SYSINIT_POSIX_CLEANUP              00036a
    4849#define RTEMS_SYSINIT_IDLE_THREADS               000380
  • testsuites/sptests/spsysinit01/init.c

    rcef5675 rf4fee477  
    2929#include <rtems/extensionimpl.h>
    3030#ifdef RTEMS_POSIX_API
     31#include <rtems/posix/condimpl.h>
    3132#include <rtems/posix/psignalimpl.h>
    3233#include <rtems/posix/pthreadimpl.h>
     
    8788  POSIX_THREADS_PRE,
    8889  POSIX_THREADS_POST,
     90  POSIX_CONDITION_VARIABLE_PRE,
     91  POSIX_CONDITION_VARIABLE_POST,
    8992  POSIX_CLEANUP_PRE,
    9093  POSIX_CLEANUP_POST,
     
    363366}
    364367
     368FIRST(RTEMS_SYSINIT_POSIX_CONDITION_VARIABLE)
     369{
     370  assert(_POSIX_Condition_variables_Information.maximum == 0);
     371  next_step(POSIX_CONDITION_VARIABLE_PRE);
     372}
     373
     374LAST(RTEMS_SYSINIT_POSIX_CONDITION_VARIABLE)
     375{
     376  assert(_POSIX_Condition_variables_Information.maximum != 0);
     377  next_step(POSIX_CONDITION_VARIABLE_POST);
     378}
     379
    365380static size_t user_extensions_pre_posix_cleanup;
    366381
     
    492507#ifdef RTEMS_POSIX_API
    493508
     509#define CONFIGURE_MAXIMUM_POSIX_CONDITION_VARIABLES 1
     510
    494511#define CONFIGURE_MAXIMUM_POSIX_THREADS 1
    495512
Note: See TracChangeset for help on using the changeset viewer.