diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2021-07-30 11:09:10 +0200 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2023-07-14 12:21:33 +0200 |
commit | 3773a63b2ac208b9e1d4ae743ceedd8e679cd156 (patch) | |
tree | 1fb003e6bda0ec695d633df4e09a4faaf0e5e600 /bsps/sparc/leon3/start/bspsmp.c | |
parent | bsp/leon3: Move leon3_power_down_loop() (diff) | |
download | rtems-3773a63b2ac208b9e1d4ae743ceedd8e679cd156.tar.bz2 |
bsp/leon3: Simplify fatal error handling
Diffstat (limited to 'bsps/sparc/leon3/start/bspsmp.c')
-rw-r--r-- | bsps/sparc/leon3/start/bspsmp.c | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/bsps/sparc/leon3/start/bspsmp.c b/bsps/sparc/leon3/start/bspsmp.c index 7f8496289a..dc4065450a 100644 --- a/bsps/sparc/leon3/start/bspsmp.c +++ b/bsps/sparc/leon3/start/bspsmp.c @@ -39,14 +39,9 @@ static void bsp_inter_processor_interrupt( void *arg ) void bsp_start_on_secondary_processor(Per_CPU_Control *cpu_self) { - /* - * If data cache snooping is not enabled we terminate using BSP_fatal_exit() - * instead of bsp_fatal(). This is done since the latter function tries to - * acquire a ticket lock, an operation which requires data cache snooping to - * be enabled. - */ - if ( !leon3_data_cache_snooping_enabled() ) - BSP_fatal_exit( LEON3_FATAL_INVALID_CACHE_CONFIG_SECONDARY_PROCESSOR ); + if ( !leon3_data_cache_snooping_enabled() ) { + bsp_fatal( LEON3_FATAL_INVALID_CACHE_CONFIG_SECONDARY_PROCESSOR ); + } _SMP_Start_multitasking_on_secondary_processor(cpu_self); } @@ -75,11 +70,6 @@ static void leon3_install_inter_processor_interrupt( void ) _Assert_Unused_variable_equals( sc, RTEMS_SUCCESSFUL ); } -static uint32_t leon3_get_cpu_count( const irqamp *regs ) -{ - return IRQAMP_MPSTAT_NCPU_GET( grlib_load_32( ®s->mpstat ) ) + 1; -} - uint32_t _CPU_SMP_Initialize( void ) { if ( !leon3_data_cache_snooping_enabled() ) |