[PATCH 3/8] score: Rename Per_CPU_Control::started
Joel Sherrill
joel at rtems.org
Thu Mar 3 15:07:32 UTC 2016
Looks good.
On Thu, Mar 3, 2016 at 8:47 AM, Sebastian Huber <
sebastian.huber at embedded-brains.de> wrote:
> Rename Per_CPU_Control::started into Per_CPU_Control::online to match
> standard nomenclature.
> ---
> cpukit/score/include/rtems/score/percpu.h | 6 +++---
> cpukit/score/src/smp.c | 4 ++--
> cpukit/score/src/threadcreateidle.c | 2 +-
> 3 files changed, 6 insertions(+), 6 deletions(-)
>
> diff --git a/cpukit/score/include/rtems/score/percpu.h
> b/cpukit/score/include/rtems/score/percpu.h
> index 4ad530f..2b05b78 100644
> --- a/cpukit/score/include/rtems/score/percpu.h
> +++ b/cpukit/score/include/rtems/score/percpu.h
> @@ -364,7 +364,7 @@ typedef struct Per_CPU_Control {
> * @brief Indicates if the processor has been successfully started via
> * _CPU_SMP_Start_processor().
> */
> - bool started;
> + bool online;
> #endif
>
> Per_CPU_Stats Stats;
> @@ -523,12 +523,12 @@ static inline struct _Thread_Control
> *_Per_CPU_Get_executing(
> return cpu->executing;
> }
>
> -static inline bool _Per_CPU_Is_processor_started(
> +static inline bool _Per_CPU_Is_processor_online(
> const Per_CPU_Control *cpu
> )
> {
> #if defined( RTEMS_SMP )
> - return cpu->started;
> + return cpu->online;
> #else
> (void) cpu;
>
> diff --git a/cpukit/score/src/smp.c b/cpukit/score/src/smp.c
> index a5562eb..b2713f1 100644
> --- a/cpukit/score/src/smp.c
> +++ b/cpukit/score/src/smp.c
> @@ -61,7 +61,7 @@ static void _SMP_Start_processors( uint32_t cpu_count )
> }
> }
>
> - cpu->started = started;
> + cpu->online = started;
>
> if ( started ) {
> Scheduler_Context *context =
> @@ -119,7 +119,7 @@ void _SMP_Request_start_multitasking( void )
> for ( cpu_index = 0 ; cpu_index < cpu_count ; ++cpu_index ) {
> Per_CPU_Control *cpu = _Per_CPU_Get_by_index( cpu_index );
>
> - if ( _Per_CPU_Is_processor_started( cpu ) ) {
> + if ( _Per_CPU_Is_processor_online( cpu ) ) {
> _Per_CPU_State_change( cpu,
> PER_CPU_STATE_REQUEST_START_MULTITASKING );
> }
> }
> diff --git a/cpukit/score/src/threadcreateidle.c
> b/cpukit/score/src/threadcreateidle.c
> index a07e238..5608040 100644
> --- a/cpukit/score/src/threadcreateidle.c
> +++ b/cpukit/score/src/threadcreateidle.c
> @@ -90,7 +90,7 @@ void _Thread_Create_idle( void )
> for ( cpu_index = 0 ; cpu_index < cpu_count ; ++cpu_index ) {
> Per_CPU_Control *cpu = _Per_CPU_Get_by_index( cpu_index );
>
> - if ( _Per_CPU_Is_processor_started( cpu ) ) {
> + if ( _Per_CPU_Is_processor_online( cpu ) ) {
> _Thread_Create_idle_for_cpu( cpu );
> }
> }
> --
> 1.8.4.5
>
> _______________________________________________
> devel mailing list
> devel at rtems.org
> http://lists.rtems.org/mailman/listinfo/devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rtems.org/pipermail/devel/attachments/20160303/698f1dd0/attachment-0002.html>
More information about the devel
mailing list