[rtems-central commit] spec: Fix fatal error specification
Sebastian Huber
sebh at rtems.org
Wed Sep 8 11:49:44 UTC 2021
Module: rtems-central
Branch: master
Commit: 3cd32df95c44cc7363fae7eb3aa67ac43ed94f93
Changeset: http://git.rtems.org/rtems-central/commit/?id=3cd32df95c44cc7363fae7eb3aa67ac43ed94f93
Author: Sebastian Huber <sebastian.huber at embedded-brains.de>
Date: Tue Sep 7 15:13:25 2021 +0200
spec: Fix fatal error specification
---
...=> fatal-bad-thread-dispatch-environment-ipi.yml} | 0
.../fatal-bad-thread-dispatch-environment-robust.yml | 20 ++++++++++++++++++++
spec/score/val/fatal.yml | 8 +++++++-
3 files changed, 27 insertions(+), 1 deletion(-)
diff --git a/spec/score/thread/req/fatal-bad-thread-dispatch-environment.yml b/spec/score/thread/req/fatal-bad-thread-dispatch-environment-ipi.yml
similarity index 100%
rename from spec/score/thread/req/fatal-bad-thread-dispatch-environment.yml
rename to spec/score/thread/req/fatal-bad-thread-dispatch-environment-ipi.yml
diff --git a/spec/score/thread/req/fatal-bad-thread-dispatch-environment-robust.yml b/spec/score/thread/req/fatal-bad-thread-dispatch-environment-robust.yml
new file mode 100644
index 0000000..e7313d0
--- /dev/null
+++ b/spec/score/thread/req/fatal-bad-thread-dispatch-environment-robust.yml
@@ -0,0 +1,20 @@
+SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
+copyrights:
+- Copyright (C) 2021 embedded brains GmbH (http://www.embedded-brains.de)
+enabled-by:
+- aarch64
+- arm
+- riscv
+links:
+- role: requirement-refinement
+ uid: /req/fatal-error
+functional-type: function
+rationale: null
+references: []
+requirement-type: functional
+text: |
+ If a thread dispatch is done with maskable interrupts disabled, then the
+ system shall terminate with the ${/score/interr/if/internal-error-core:/name}
+ fatal source and the
+ ${/score/interr/if/bad-thread-dispatch-environment:/name} fatal code.
+type: requirement
diff --git a/spec/score/val/fatal.yml b/spec/score/val/fatal.yml
index 0002ad8..68a2c78 100644
--- a/spec/score/val/fatal.yml
+++ b/spec/score/val/fatal.yml
@@ -40,7 +40,9 @@ test-actions:
id = CreateTask( "BENV", PRIO_HIGH );
StartTask( id, ISRDisabledThreadDispatchTask, NULL );
+ #if CPU_ENABLE_ROBUST_THREAD_DISPATCH == FALSE
if ( rtems_configuration_get_maximum_processors() > 1 ) {
+ #endif
T_eq_uint( GetFatalCounter(), counter + 1 );
T_eq_int( fatal_info.source, INTERNAL_ERROR_CORE );
T_false( fatal_info.always_set_to_false );
@@ -48,16 +50,20 @@ test-actions:
fatal_info.code,
INTERNAL_ERROR_BAD_THREAD_DISPATCH_ENVIRONMENT
);
+ #if CPU_ENABLE_ROBUST_THREAD_DISPATCH == FALSE
} else {
T_eq_uint( GetFatalCounter(), counter );
}
+ #endif
RestoreRunnerPriority();
SetFatalExtension( NULL );
checks: []
links:
- role: validation
- uid: ../thread/req/fatal-bad-thread-dispatch-environment
+ uid: ../thread/req/fatal-bad-thread-dispatch-environment-ipi
+ - role: validation
+ uid: ../thread/req/fatal-bad-thread-dispatch-environment-robust
- role: validation
uid: ../thread/req/thread-dispatch-isr-disabled
- action-brief: |
More information about the vc
mailing list