Changeset 8907a01c in rtems


Ignore:
Timestamp:
Sep 13, 2009, 8:54:01 PM (10 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, master
Children:
bacf79e
Parents:
0fa8b4d
Message:

2009-09-13 Joel Sherrill <joel.sherrill@…>

  • score/include/rtems/score/coresem.h, score/src/coresemseize.c: Disable body of _CORE_semaphore_Seize() if it is not used because all APIs using it are disabled.
Location:
cpukit
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • cpukit/ChangeLog

    r0fa8b4d r8907a01c  
     12009-09-13      Joel Sherrill <joel.sherrill@oarcorp.com>
     2
     3        * score/include/rtems/score/coresem.h, score/src/coresemseize.c:
     4        Disable body of _CORE_semaphore_Seize() if it is not used because all
     5        APIs using it are disabled.
     6
    172009-09-13      Joel Sherrill <joel.sherrill@oarcorp.com>
    28
  • cpukit/score/include/rtems/score/coresem.h

    r0fa8b4d r8907a01c  
    3838#include <rtems/score/priority.h>
    3939#include <rtems/score/watchdog.h>
     40
     41#if defined(RTEMS_POSIX_API) || defined(RTEMS_ITRON_API)
     42  #define RTEMS_SCORE_CORESEM_ENABLE_SEIZE_BODY
     43#endif
    4044
    4145/**
     
    136140);
    137141
    138 /**
    139  *  This routine attempts to receive a unit from @a the_semaphore.
    140  *  If a unit is available or if the wait flag is false, then the routine
    141  *  returns.  Otherwise, the calling task is blocked until a unit becomes
    142  *  available.
    143  *
    144  *  @param[in] the_semaphore is the semaphore to seize
    145  *  @param[in] id is the Id of the API level Semaphore object associated
    146  *         with this instance of a SuperCore Semaphore
    147  *  @param[in] wait indicates if the caller is willing to block
    148  *  @param[in] timeout is the number of ticks the calling thread is willing
    149  *         to wait if @a wait is true.
    150  */
    151 void _CORE_semaphore_Seize(
    152   CORE_semaphore_Control  *the_semaphore,
    153   Objects_Id               id,
    154   bool                     wait,
    155   Watchdog_Interval        timeout
    156 );
     142#if defined(RTEMS_SCORE_CORESEM_ENABLE_SEIZE_BODY)
     143  /**
     144   *  This routine attempts to receive a unit from @a the_semaphore.
     145   *  If a unit is available or if the wait flag is false, then the routine
     146   *  returns.  Otherwise, the calling task is blocked until a unit becomes
     147   *  available.
     148   *
     149   *  @param[in] the_semaphore is the semaphore to seize
     150   *  @param[in] id is the Id of the API level Semaphore object associated
     151   *         with this instance of a SuperCore Semaphore
     152   *  @param[in] wait indicates if the caller is willing to block
     153   *  @param[in] timeout is the number of ticks the calling thread is willing
     154   *         to wait if @a wait is true.
     155   */
     156  void _CORE_semaphore_Seize(
     157    CORE_semaphore_Control  *the_semaphore,
     158    Objects_Id               id,
     159    bool                     wait,
     160    Watchdog_Interval        timeout
     161  );
     162#endif
    157163
    158164/**
  • cpukit/score/src/coresemseize.c

    r0fa8b4d r8907a01c  
    2929#include <rtems/score/threadq.h>
    3030
    31 /*PAGE
    32  *
    33  *  _CORE_semaphore_Seize
    34  *
     31#if defined(RTEMS_SCORE_CORESEM_ENABLE_SEIZE_BODY)
     32/*
    3533 *  This routine attempts to allocate a core semaphore to the calling thread.
    3634 *
     
    8886  _Thread_queue_Enqueue( &the_semaphore->Wait_queue, timeout );
    8987}
     88#endif
Note: See TracChangeset for help on using the changeset viewer.