summaryrefslogtreecommitdiff
path: root/tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c
diff options
context:
space:
mode:
authorLance Roy <ldr709@gmail.com>2016-12-31 16:33:50 -0800
committerPaul E. McKenney <paulmck@linux.vnet.ibm.com>2017-01-25 12:54:22 -0800
commit418b2977b34378f67c46930c72a776f94e7bf903 (patch)
tree2f3f41dd02a80f237bda867211e4bb852c0c9a08 /tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c
parentd85b62f18d543c663cbdd6061054efeb9e66cee7 (diff)
rcutorture: Add CBMC-based formal verification for SRCU
This commit creates a formal/srcu-cbmc directory containing scripts that pull SRCU in from the source code, filter it to remove things that CBMC cannot handle, and run a series of verifications on it. This has a number of shortcomings: 1. It does not yet hook into the upper-level self-test Makefiles. 2. It tests only a single scenario, store buffering. 3. There is no gcc-based syntax-error prefiltering. Nevertheless, it does fully verify a piece of SRCU under a moderately weak memory model (PSO). Signed-off-by: Lance Roy <ldr709@gmail.com> Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Diffstat (limited to 'tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c')
-rw-r--r--tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c b/tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c
new file mode 100644
index 000000000000..ca892e3b2351
--- /dev/null
+++ b/tools/testing/selftests/rcutorture/formal/srcu-cbmc/src/misc.c
@@ -0,0 +1,11 @@
+#include <config.h>
+
+#include "misc.h"
+#include "bug_on.h"
+
+struct rcu_head;
+
+void wakeme_after_rcu(struct rcu_head *head)
+{
+ BUG();
+}