diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-06-14 14:00:38 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2013-07-17 13:09:49 +0200 |
commit | 39e51758c86754cef5ba4521c0c36578521f73d0 (patch) | |
tree | a87255c5c0592b876106da50b939dedd471b7d5a /cpukit/score/src/threaddispatchdisablelevel.c | |
parent | smp: Delete RTEMS_BSP_SMP_CONTEXT_SWITCH_NECESSARY (diff) | |
download | rtems-39e51758c86754cef5ba4521c0c36578521f73d0.tar.bz2 |
smp: Add and use _CPU_SMP_Get_current_processor()
Add and use _SMP_Get_current_processor() and
rtems_smp_get_current_processor().
Delete bsp_smp_interrupt_cpu().
Change type of current processor index from int to uint32_t to match
_SMP_Processor_count type.
Diffstat (limited to 'cpukit/score/src/threaddispatchdisablelevel.c')
-rw-r--r-- | cpukit/score/src/threaddispatchdisablelevel.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/cpukit/score/src/threaddispatchdisablelevel.c b/cpukit/score/src/threaddispatchdisablelevel.c index 1f84bfe65c..d5f3ff601b 100644 --- a/cpukit/score/src/threaddispatchdisablelevel.c +++ b/cpukit/score/src/threaddispatchdisablelevel.c @@ -26,7 +26,7 @@ #include <rtems/score/sysstate.h> #include <rtems/score/threaddispatch.h> -#define NO_OWNER_CPU (-1) +#define NO_OWNER_CPU 0xffffffffU void _Thread_Dispatch_initialization( void ) { @@ -48,8 +48,8 @@ uint32_t _Thread_Dispatch_increment_disable_level( void ) { Thread_Dispatch_disable_level_lock_control *level_lock = &_Thread_Dispatch_disable_level_lock; - int self_cpu; ISR_Level isr_level; + uint32_t self_cpu; uint32_t disable_level; _ISR_Disable_on_this_core( isr_level ); @@ -58,7 +58,7 @@ uint32_t _Thread_Dispatch_increment_disable_level( void ) * We must obtain the processor ID after interrupts are disabled since a * non-optimizing compiler may store the value on the stack and read it back. */ - self_cpu = bsp_smp_processor_id(); + self_cpu = _SMP_Get_current_processor(); if ( level_lock->owner_cpu != self_cpu ) { _SMP_lock_Acquire( &level_lock->lock ); |