Changeset 2af90ff in rtems


Ignore:
Timestamp:
Feb 11, 2011, 8:38:16 PM (9 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.11, master
Children:
7ce892d
Parents:
7a5a885e
Message:

2011-02-11 Joel Sherrill <joel.sherrilL@…>

  • rtems/src/semtranslatereturncode.c, score/include/rtems/score/coremutex.h, score/src/coremutexsurrender.c, score/src/objectinitializeinformation.c: Disable code not reachable when POSIX is not enabled.
Location:
cpukit
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    r7a5a885e r2af90ff  
     12011-02-11      Joel Sherrill <joel.sherrilL@OARcorp.com>
     2
     3        * rtems/src/semtranslatereturncode.c,
     4        score/include/rtems/score/coremutex.h,
     5        score/src/coremutexsurrender.c,
     6        score/src/objectinitializeinformation.c: Disable code not reachable
     7        when POSIX is not enabled.
     8
    192011-02-11      Joel Sherrill <joel.sherrilL@OARcorp.com>
    210
  • cpukit/rtems/src/semtranslatereturncode.c

    r7a5a885e r2af90ff  
    6565  RTEMS_SUCCESSFUL,         /* CORE_MUTEX_STATUS_SUCCESSFUL */
    6666  RTEMS_UNSATISFIED,        /* CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT */
     67#if !defined(RTEMS_POSIX_API)
    6768  RTEMS_UNSATISFIED,        /* CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED */
     69#endif
    6870  RTEMS_NOT_OWNER_OF_RESOURCE, /* CORE_MUTEX_STATUS_NOT_OWNER_OF_RESOURCE */
    6971  RTEMS_OBJECT_WAS_DELETED, /* CORE_MUTEX_WAS_DELETED */
    7072  RTEMS_TIMEOUT,            /* CORE_MUTEX_TIMEOUT */
    71 #ifdef __RTEMS_STRICT_ORDER_MUTEX__
     73#if !defined(__RTEMS_STRICT_ORDER_MUTEX__)
    7274    CORE_MUTEX_RELEASE_NOT_ORDER,
    7375#endif
  • cpukit/score/include/rtems/score/coremutex.h

    r7a5a885e r2af90ff  
    8686   */
    8787  CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT,
     88#if !defined(RTEMS_POSIX_API)
    8889  /** This status indicates that an attempt was made to relock a mutex
    8990   *  for which nesting is not configured.
    9091   */
    9192  CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED,
     93#endif
    9294  /** This status indicates that an attempt was made to release a mutex
    9395   *  by a thread other than the thread which locked it.
     
    104106  CORE_MUTEX_TIMEOUT,
    105107
    106 #ifdef __RTEMS_STRICT_ORDER_MUTEX__
     108#if !defined(__RTEMS_STRICT_ORDER_MUTEX__)
    107109  /** This status indicates that a thread not release the mutex which has
    108110   *  the priority inheritance property in a right order.
  • cpukit/score/src/coremutexsurrender.c

    r7a5a885e r2af90ff  
    138138        case CORE_MUTEX_NESTING_ACQUIRES:
    139139          return CORE_MUTEX_STATUS_SUCCESSFUL;
    140         case CORE_MUTEX_NESTING_IS_ERROR:
    141           /* should never occur */
    142           return CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
     140        #if !defined(RTEMS_POSIX_API)
     141          case CORE_MUTEX_NESTING_IS_ERROR:
     142            /* should never occur */
     143            return CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
     144        #endif
    143145        case CORE_MUTEX_NESTING_BLOCKS:
    144146          /* Currently no API exercises this behavior. */
  • cpukit/score/src/objectinitializeinformation.c

    r7a5a885e r2af90ff  
    129129  /*
    130130   *  Calculate the maximum name length
     131   *
     132   *  NOTE: Always 4 bytes long in Class so aligned.  It is POSIX name
     133   *        lengths that may be an odd number of bytes.
    131134   */
    132135  name_length = maximum_name_length;
    133136
    134   if ( name_length & (OBJECTS_NAME_ALIGNMENT-1) )
    135     name_length = (name_length + OBJECTS_NAME_ALIGNMENT) &
    136                   ~(OBJECTS_NAME_ALIGNMENT-1);
    137 
     137  #if !defined(RTEMS_POSIX_API)
     138    if ( name_length & (OBJECTS_NAME_ALIGNMENT-1) )
     139      name_length = (name_length + OBJECTS_NAME_ALIGNMENT) &
     140                    ~(OBJECTS_NAME_ALIGNMENT-1);
     141  #endif
     142 
    138143  information->name_length = name_length;
    139144
Note: See TracChangeset for help on using the changeset viewer.