diff options
author | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2022-01-14 08:35:49 +0100 |
---|---|---|
committer | Sebastian Huber <sebastian.huber@embedded-brains.de> | 2022-01-14 16:39:58 +0100 |
commit | 96247b3e3c8330d8297dcc4fccff25e9d106f4c2 (patch) | |
tree | 2fd2644575cf2608d3f2b7f90b00f4130bddd91a | |
parent | spec: Disable data cache before invalidation (diff) | |
download | rtems-central-96247b3e3c8330d8297dcc4fccff25e9d106f4c2.tar.bz2 |
spec: Fix _Terminate() validation
Enable interrupts before the rtems_extension_delete() directives are
called.
-rw-r--r-- | spec/score/interr/val/terminate.yml | 41 |
1 files changed, 22 insertions, 19 deletions
diff --git a/spec/score/interr/val/terminate.yml b/spec/score/interr/val/terminate.yml index ab0b53ab..6ad12ae4 100644 --- a/spec/score/interr/val/terminate.yml +++ b/spec/score/interr/val/terminate.yml @@ -69,14 +69,30 @@ test-actions: } test_case_active = false; - - sc = rtems_extension_delete( extension_ids[ 2 ] ); - T_step_rsc_success( ${step}, sc ); - - sc = rtems_extension_delete( extension_ids[ 6 ] ); - T_step_rsc_success( ${step}, sc ); checks: - brief: | + Where the system was built with SMP support enabled, check that a + shutdown request was issued. + code: | + #if defined(RTEMS_SMP) + shutdown_ok = ( shutdown_ok && _ISR_Get_level() != 0 && + _Per_CPU_Get_state( _Per_CPU_Get() ) == PER_CPU_STATE_SHUTDOWN ); + _ISR_Set_level( 0 ); + #endif + T_step_true( ${step}, shutdown_ok ); + links: + - role: validation + uid: ../req/terminate-shutdown + - brief: | + Delete the dynamic extension sets. + code: | + sc = rtems_extension_delete( extension_ids[ 2 ] ); + T_step_rsc_success( ${step}, sc ); + + sc = rtems_extension_delete( extension_ids[ 6 ] ); + T_step_rsc_success( ${step}, sc ); + links: [] + - brief: | Check that the fatal extensions were invoked with the expected source. code: | T_step_eq_int( @@ -168,19 +184,6 @@ test-actions: - role: validation uid: ../req/terminate-state - brief: | - Where the system was built with SMP support enabled, check that a - shutdown request was issued. - code: | - #if defined(RTEMS_SMP) - shutdown_ok = ( shutdown_ok && _ISR_Get_level() != 0 && - _Per_CPU_Get_state( _Per_CPU_Get() ) == PER_CPU_STATE_SHUTDOWN ); - _ISR_Set_level( 0 ); - #endif - T_step_true( ${step}, shutdown_ok ); - links: - - role: validation - uid: ../req/terminate-shutdown - - brief: | Check that the system was halted with the expected fatal source. code: | T_step_eq_int( ${step}, halt_source, RTEMS_FATAL_SOURCE_APPLICATION ); |