Changeset 5b1ff71a in rtems


Ignore:
Timestamp:
May 13, 2014, 1:57:43 PM (5 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
beab7329
Parents:
774ee002
git-author:
Sebastian Huber <sebastian.huber@…> (05/13/14 13:57:43)
git-committer:
Sebastian Huber <sebastian.huber@…> (05/14/14 12:46:19)
Message:

score: Scheduler documentation

Location:
cpukit/score/include/rtems/score
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • cpukit/score/include/rtems/score/scheduler.h

    r774ee002 r5b1ff71a  
    4444
    4545/**
    46  * function jump table that holds pointers to the functions that
    47  * implement specific schedulers.
     46 * @brief The scheduler operations.
    4847 */
    4948typedef struct {
    50   /** Implements the scheduling decision logic (policy). */
     49  /** @see _Scheduler_Handler_initialization() */
    5150  void ( *initialize )( const Scheduler_Control * );
    5251
    53   /** Implements the scheduling decision logic (policy). */
     52  /** @see _Scheduler_Schedule() */
    5453  void ( *schedule )( const Scheduler_Control *, Thread_Control *);
    5554
    56   /**
    57    * @brief Voluntarily yields the processor per the scheduling policy.
    58    *
    59    * @see _Scheduler_Yield().
    60    */
     55  /** @see _Scheduler_Yield() */
    6156  void ( *yield )( const Scheduler_Control *, Thread_Control *);
    6257
    63   /** Removes the given thread from scheduling decisions. */
     58  /** @see _Scheduler_Block() */
    6459  void ( *block )( const Scheduler_Control *, Thread_Control * );
    6560
    66   /** Adds the given thread to scheduling decisions. */
     61  /** @see _Scheduler_Unblock() */
    6762  void ( *unblock )( const Scheduler_Control *, Thread_Control * );
    6863
    69   /** allocates the scheduler field of the given thread */
     64  /** @see _Scheduler_Allocate() */
    7065  bool ( *allocate )( const Scheduler_Control *, Thread_Control * );
    7166
    72   /** frees the scheduler field of the given thread */
     67  /** @see _Scheduler_Free() */
    7368  void ( *free )( const Scheduler_Control *, Thread_Control * );
    7469
    75   /** updates the scheduler field of the given thread -- primarily used
    76    * when changing the thread's priority. */
     70  /** @see _Scheduler_Update() */
    7771  void ( *update )( const Scheduler_Control *, Thread_Control * );
    7872
    79   /** enqueue a thread as the last of its priority group */
     73  /** @see _Scheduler_Enqueue() */
    8074  void ( *enqueue )( const Scheduler_Control *, Thread_Control * );
    8175
    82   /** enqueue a thread as the first of its priority group */
     76  /** @see _Scheduler_Enqueue_first() */
    8377  void ( *enqueue_first )( const Scheduler_Control *, Thread_Control * );
    8478
    85   /** extract a thread from the ready set */
     79  /** @see _Scheduler_Extract() */
    8680  void ( *extract )( const Scheduler_Control *, Thread_Control * );
    8781
    88   /**
    89    * Compares two priorities (returns >0 for higher priority, 0 for equal
    90    * and <0 for lower priority).
    91    */
     82  /** @see _Scheduler_Priority_compare() */
    9283  int ( *priority_compare )(
    9384    Priority_Control,
     
    9586  );
    9687
    97   /** This routine is called upon release of a new job. */
     88  /** @see _Scheduler_Release_job() */
    9889  void ( *release_job ) (
    9990    const Scheduler_Control *,
     
    10293  );
    10394
    104   /** perform scheduler update actions required at each clock tick */
     95  /** @see _Scheduler_Tick() */
    10596  void ( *tick )( const Scheduler_Control *, Thread_Control * );
    10697
    107   /**
    108    * @brief Starts the idle thread for a particular processor.
    109    *
    110    * @see _Scheduler_Start_idle().
    111    */
     98  /** @see _Scheduler_Start_idle() */
    11299  void ( *start_idle )(
    113100    const Scheduler_Control *,
     
    117104
    118105#if defined(__RTEMS_HAVE_SYS_CPUSET_H__) && defined(RTEMS_SMP)
    119   /**
    120    * @brief Obtain the processor affinity for a thread.
    121    *
    122    * @see _Scheduler_Get_affinity().
    123    */
     106  /** @see _Scheduler_Get_affinity() */
    124107  bool ( *get_affinity )(
    125108    const Scheduler_Control *,
     
    129112  );
    130113 
    131   /**
    132    * @brief Set the processor affinity for a thread.
    133    *
    134    * @see _Scheduler_Set_affinity().
    135    */
     114  /** @see _Scheduler_Set_affinity() */
    136115  bool ( *set_affinity )(
    137116    const Scheduler_Control *,
     
    366345#endif
    367346
    368 /*
     347/**
     348 * @brief Indicates if thread priority queues are broken with the configured
     349 * scheduler or not.
     350 *
    369351 * See also PR2174: Memory corruption with EDF scheduler and thread priority
    370352 * queues.
  • cpukit/score/include/rtems/score/schedulerimpl.h

    r774ee002 r5b1ff71a  
    184184
    185185/**
    186  * @brief Scheduler enqueue.
    187  *
    188  * This routine enqueue @a the_thread->scheduler
     186 * @brief Enqueues a thread as the last of its priority group.
     187 *
     188 * @param[in] scheduler The scheduler instance.
     189 * @param[in] the_thread The thread to enqueue.
    189190 */
    190191RTEMS_INLINE_ROUTINE void _Scheduler_Enqueue(
     
    197198
    198199/**
    199  * @brief Scheduler enqueue first.
    200  *
    201  * This routine enqueue_first @a the_thread->scheduler
     200 * @brief Enqueues a thread as the first of its priority group.
     201 *
     202 * @param[in] scheduler The scheduler instance.
     203 * @param[in] the_thread The thread to enqueue.
    202204 */
    203205RTEMS_INLINE_ROUTINE void _Scheduler_Enqueue_first(
     
    223225
    224226/**
    225  * @brief Scheduler priority compare.
    226  *
    227  * This routine compares two priorities.
     227 * @brief Compares two priority values.
     228 *
     229 * @param[in] scheduler The scheduler instance.
     230 * @param[in] p1 The first priority value.
     231 * @param[in] p2 The second priority value.
     232 *
     233 * @retval negative The value @a p1 encodes a lower priority than @a p2 in the
     234 * intuitive sense of priority.
     235 * @retval 0 The priorities @a p1 and @a p2 are equal.
     236 * @retval positive The value @a p1 encodes a higher priority than @a p2 in the
     237 * intuitive sense of priority.
     238 *
     239 * @see _Scheduler_Is_priority_lower_than() and
     240 * _Scheduler_Is_priority_higher_than().
    228241 */
    229242RTEMS_INLINE_ROUTINE int _Scheduler_Priority_compare(
     
    493506
    494507/**
    495  * @brief Returns true if @p1 encodes a lower priority than @a p2 in the
     508 * @brief Returns true if @a p1 encodes a lower priority than @a p2 in the
    496509 * intuitive sense of priority.
    497510 */
     
    506519
    507520/**
    508  * @brief Returns true if @p1 encodes a higher priority than @a p2 in the
     521 * @brief Returns true if @a p1 encodes a higher priority than @a p2 in the
    509522 * intuitive sense of priority.
    510523 */
  • cpukit/score/include/rtems/score/schedulerpriority.h

    r774ee002 r5b1ff71a  
    2929
    3030/**
    31  * @defgroup ScoreSchedulerDPS Deterministic Priority-based Scheduler
     31 * @defgroup ScoreSchedulerDPS Deterministic Priority Scheduler
    3232 *
    3333 * @ingroup ScoreScheduler
  • cpukit/score/include/rtems/score/schedulerpriorityaffinitysmp.h

    r774ee002 r5b1ff71a  
    3232 * @defgroup ScoreSchedulerPriorityAffinitySMP Deterministic Priority Affinity SMP Scheduler
    3333 *
    34  * @ingroup ScoreScheduler
     34 * @ingroup ScoreSchedulerPrioritySMP
    3535 *
    3636 * This is an extension of the Deterministic Priority SMP Scheduler. which
  • cpukit/score/include/rtems/score/schedulerpriorityimpl.h

    r774ee002 r5b1ff71a  
    3232
    3333/**
    34  * @addtogroup ScoreScheduler
     34 * @addtogroup ScoreSchedulerDPS
    3535 */
    3636/**@{**/
  • cpukit/score/include/rtems/score/schedulerprioritysmp.h

    r774ee002 r5b1ff71a  
    3535 * @defgroup ScoreSchedulerPrioritySMP Deterministic Priority SMP Scheduler
    3636 *
    37  * @ingroup ScoreScheduler
     37 * @ingroup ScoreSchedulerSMP
    3838 *
    3939 * This is an implementation of the global fixed priority scheduler (G-FP).  It
  • cpukit/score/include/rtems/score/schedulersimpleimpl.h

    r774ee002 r5b1ff71a  
    2929
    3030/**
    31  * @addtogroup ScoreScheduler
     31 * @addtogroup ScoreSchedulerSimple
    3232 */
    3333/**@{**/
  • cpukit/score/include/rtems/score/schedulersimplesmp.h

    r774ee002 r5b1ff71a  
    44 * @brief Simple SMP Scheduler API
    55 *
    6  * @ingroup ScoreSchedulerSMP
     6 * @ingroup ScoreSchedulerSMPSimple
    77 */
    88
     
    2929
    3030/**
    31  * @defgroup ScoreSchedulerSMP Simple SMP Scheduler
     31 * @defgroup ScoreSchedulerSMPSimple Simple Priority SMP Scheduler
    3232 *
    33  * @ingroup ScoreScheduler
     33 * @ingroup ScoreSchedulerSMP
    3434 *
    35  * The Simple SMP Scheduler allocates a processor for the processor count
    36  * highest priority ready threads.  The thread priority and position in the
    37  * ready chain are the only information to determine the scheduling decision.
    38  * Threads with an allocated processor are in the scheduled chain.  After
    39  * initialization the scheduled chain has exactly processor count nodes.  Each
    40  * processor has exactly one allocated thread after initialization.  All
     35 * The Simple Priority SMP Scheduler allocates a processor for the processor
     36 * count highest priority ready threads.  The thread priority and position in
     37 * the ready chain are the only information to determine the scheduling
     38 * decision.  Threads with an allocated processor are in the scheduled chain.
     39 * After initialization the scheduled chain has exactly processor count nodes.
     40 * Each processor has exactly one allocated thread after initialization.  All
    4141 * enqueue and extract operations may exchange threads with the scheduled
    4242 * chain.  One thread will be added and another will be removed.  The scheduled
Note: See TracChangeset for help on using the changeset viewer.