On 2014-07-03 11:39, Daniel Cederman wrote:
@@ -39,7 +40,9 @@ void bsp_start_on_secondary_processor() { uint32_t cpu_index_self = _CPU_SMP_Get_current_processor();- leon3_set_cache_control_register(0x80000F); + if( ! leon3_data_cache_snooping_enabled() ) + BSP_fatal_exit( LEON3_FATAL_INVALID_CACHE_CONFIG ); + /* Unmask IPI interrupts at Interrupt controller for this CPU */ LEON3_IrqCtrl_Regs->mask[cpu_index_self] |= 1U << LEON3_MP_IRQ; @@ -48,7 +51,8 @@ void bsp_start_on_secondary_processor() uint32_t _CPU_SMP_Initialize( void ) { - leon3_set_cache_control_register(0x80000F); + if( ! leon3_data_cache_snooping_enabled() ) + bsp_fatal( LEON3_FATAL_INVALID_CACHE_CONFIG ); if ( rtems_configuration_get_maximum_processors() > 1 ) { LEON_Unmask_interrupt(LEON3_MP_IRQ);
Fatal error codes should uniquely identify the code location, so you should use two error codes here.
-- Sebastian Huber, embedded brains GmbH Address : Dornierstr. 4, D-82178 Puchheim, Germany Phone : +49 89 189 47 41-16 Fax : +49 89 189 47 41-09 E-Mail : [email protected] PGP : Public key available on request. Diese Nachricht ist keine geschäftliche Mitteilung im Sinne des EHUG. _______________________________________________ devel mailing list [email protected] http://lists.rtems.org/mailman/listinfo/devel
