From 33d7b107849a5bd586bb21dd5cbabca14a2f1ef0 Mon Sep 17 00:00:00 2001
From: Joel Sherrill <joel@rtems.org>
Date: Fri, 12 Aug 2022 16:25:05 -0500
Subject: [PATCH] Add POSIX Timer FACE Behavior Configuration

---
 config.yml                                 |  2 ++
 spec/acfg/if/group-face.yml                | 18 ++++++++++++++++++
 spec/acfg/if/posix-timer-face-behavior.yml | 21 +++++++++++++++++++++
 3 files changed, 41 insertions(+)
 create mode 100644 spec/acfg/if/group-face.yml
 create mode 100644 spec/acfg/if/posix-timer-face-behavior.yml

diff --git a/config.yml b/config.yml
index 529a2a5..da39e60 100644
--- a/config.yml
+++ b/config.yml
@@ -90,6 +90,8 @@ appl-config:
     target: modules/rtems-docs/c-user/config/device-driver.rst
   - uid: /acfg/if/group-eventrecord
     target: modules/rtems-docs/c-user/config/event-record.rst
+  - uid: /acfg/if/group-face
+    target: modules/rtems-docs/c-user/config/face.rst
   - uid: /acfg/if/group-filesystem
     target: modules/rtems-docs/c-user/config/filesystem.rst
   - uid: /acfg/if/group-general
diff --git a/spec/acfg/if/group-face.yml b/spec/acfg/if/group-face.yml
new file mode 100644
index 0000000..2d3a8fc
--- /dev/null
+++ b/spec/acfg/if/group-face.yml
@@ -0,0 +1,18 @@
+SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
+copyrights:
+- Copyright (C) 2022 On-Line Applications Research Corporation (OAR)
+description: |
+  This section describes configuration options related to adapting
+  RTEMS behavior to be aligned with the FACE Technical Standard.
+enabled-by: true
+index-entries: []
+interface-type: appl-config-group
+links:
+- role: interface-placement
+  uid: ../../if/domain
+- role: requirement-refinement
+  uid: ../../req/applconfig
+name: FACE Technical Standard Related Configuration
+text: ''
+type: interface
+
diff --git a/spec/acfg/if/posix-timer-face-behavior.yml b/spec/acfg/if/posix-timer-face-behavior.yml
new file mode 100644
index 0000000..0f0de83
--- /dev/null
+++ b/spec/acfg/if/posix-timer-face-behavior.yml
@@ -0,0 +1,21 @@
+SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
+appl-config-option-type: feature-enable
+copyrights:
+- Copyright (C) 2022 On-Line Applications Research Corporation (OAR)
+description: |
+  If this configuration option is defined, then POSIX timers may
+  not be created to use the CLOCK_REALTIME. Per POSIX, this is allowed
+  behavior but per the FACE Technical Standard, using POSIX timers based
+  on CLOCK_REALTIME (e.g., time of day) is unsafe for real-time safety
+  systems as setting CLOCK_REALTIME will perturb any active timers.
+
+  If this option is not defined, POSIX timers may be created to use the
+  CLOCK_REALTIME in compliance with the POSIX specification.
+enabled-by: true
+index-entries: []
+interface-type: appl-config-option
+links:
+- role: appl-config-group-member
+  uid: group-face
+name: CONFIGURE_POSIX_TIMERS_FACE_BEHAVIOR
+type: interface
-- 
1.8.3.1

