source: rtems/cpukit/score/include/rtems/score/smp.h @ 864d3475

4.115
Last change on this file since 864d3475 was c499856, checked in by Chris Johns <chrisj@…>, on 03/20/14 at 21:10:47

Change all references of rtems.com to rtems.org.

  • Property mode set to 100644
File size: 1.1 KB
Line 
1/**
2 * @file
3 *
4 * @ingroup ScoreSMP
5 *
6 * @brief SuperCore SMP Support API
7 */
8
9/*
10 *  COPYRIGHT (c) 1989-2011.
11 *  On-Line Applications Research Corporation (OAR).
12 *
13 *  The license and distribution terms for this file may be
14 *  found in the file LICENSE in this distribution or at
15 *  http://www.rtems.org/license/LICENSE.
16 */
17
18#ifndef _RTEMS_SCORE_SMP_H
19#define _RTEMS_SCORE_SMP_H
20
21#include <rtems/score/cpu.h>
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27/**
28 * @defgroup ScoreSMP SMP Support
29 *
30 * @ingroup Score
31 *
32 * This defines the interface of the SuperCore SMP support.
33 *
34 * @{
35 */
36
37#if defined( RTEMS_SMP )
38  SCORE_EXTERN uint32_t _SMP_Processor_count;
39
40  static inline uint32_t _SMP_Get_processor_count( void )
41  {
42    return _SMP_Processor_count;
43  }
44#else
45  #define _SMP_Get_processor_count() UINT32_C(1)
46#endif
47
48#if defined( RTEMS_SMP )
49  static inline uint32_t _SMP_Get_current_processor( void )
50  {
51    return _CPU_SMP_Get_current_processor();
52  }
53#else
54  #define _SMP_Get_current_processor() UINT32_C(0)
55#endif
56
57/** @} */
58
59#ifdef __cplusplus
60}
61#endif
62
63#endif
64/* end of include file */
Note: See TracBrowser for help on using the repository browser.