Changeset 79e2d9b in rtems


Ignore:
Timestamp:
Mar 6, 2014, 10:11:59 AM (6 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
4.11, master
Children:
7552e77c
Parents:
ecd8c8ad
git-author:
Sebastian Huber <sebastian.huber@…> (03/06/14 10:11:59)
git-committer:
Sebastian Huber <sebastian.huber@…> (03/31/14 06:29:42)
Message:

score: Add per-CPU state function

Add _Per_CPU_State_wait_for_ready_to_start_multitasking(). Add new
fatal SMP error SMP_FATAL_SHUTDOWN_EARLY.

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

Legend:

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

    recd8c8ad r79e2d9b  
    473473);
    474474
     475/**
     476 * @brief Waits for all other processors to enter the ready to start
     477 * multitasking state with a timeout in microseconds.
     478 *
     479 * In case one processor enters the shutdown state, this function does not
     480 * return and terminates the system with the SMP_FATAL_SHUTDOWN_EARLY fatal SMP
     481 * error.
     482 *
     483 * This function should be called only in _CPU_SMP_Initialize() if required by
     484 * the CPU port or BSP.
     485 *
     486 * @code
     487 * uint32_t _CPU_SMP_Initialize(uint32_t configured_cpu_count)
     488 * {
     489 *   uint32_t cnt = MIN(get_hardware_cpu_count(), configured_cpu_count);
     490 *   uint32_t timeout = 123456;
     491 *
     492 *   do_some_stuff();
     493 *
     494 *   return _Per_CPU_State_wait_for_ready_to_start_multitasking(cnt, timeout);
     495 * }
     496 * @endcode
     497 *
     498 * In case the timeout expires the count of processors is reduced to reflect
     499 * the set of processors which is actually available at this point in time.
     500 *
     501 * @param[in] processor_count The processor count is the minimum value of the
     502 * configured count of processors and the processor count offered by the actual
     503 * hardware.
     504 * @param[in] timeout_in_us The timeout in microseconds.
     505 *
     506 * @return The count of processors available for the application in the system.
     507 * This value is less than or equal to the processor count.
     508 */
     509uint32_t _Per_CPU_State_wait_for_ready_to_start_multitasking(
     510  uint32_t processor_count,
     511  uint32_t timeout_in_us
     512);
     513
    475514#endif /* defined( RTEMS_SMP ) */
    476515
  • cpukit/score/include/rtems/score/smpimpl.h

    recd8c8ad r79e2d9b  
    4848 */
    4949typedef enum {
    50   SMP_FATAL_SHUTDOWN
     50  SMP_FATAL_SHUTDOWN,
     51  SMP_FATAL_SHUTDOWN_EARLY
    5152} SMP_Fatal_code;
    5253
Note: See TracChangeset for help on using the changeset viewer.