summaryrefslogtreecommitdiff
path: root/cts/task/cts.testlist
diff options
context:
space:
mode:
authorDaisuke Nojiri <dnojiri@chromium.org>2016-11-10 14:21:38 -0800
committerchrome-bot <chrome-bot@chromium.org>2017-06-23 00:51:18 -0700
commit60800678ca1a7454a20ae2c270a4ea0bda34b9c0 (patch)
tree2caad6871cc5bec0decf5eb2e6e2f1dfd92272c4 /cts/task/cts.testlist
parent9e32694d1051ef0eb3b091e1b03563cfd538b1d7 (diff)
downloadchrome-ec-60800678ca1a7454a20ae2c270a4ea0bda34b9c0.tar.gz
eCTS: Add stack overflow test
This patch adds a test for stack overflow detection. CTS task tries to overflow by calling a function recursively. This function sleeps to incur context switch, where stack overflow is checked. Reboot is expected but not checked. BUG=chromium:663873 BRANCH=none TEST=cts.py -m task Change-Id: I6ad98d209acf873d2d23b48bac6fc751fa8c2f74 Signed-off-by: Daisuke Nojiri <dnojiri@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/410283 Reviewed-by: Randall Spangler <rspangler@chromium.org>
Diffstat (limited to 'cts/task/cts.testlist')
-rw-r--r--cts/task/cts.testlist9
1 files changed, 8 insertions, 1 deletions
diff --git a/cts/task/cts.testlist b/cts/task/cts.testlist
index 7c8c5757df..25dbcc313a 100644
--- a/cts/task/cts.testlist
+++ b/cts/task/cts.testlist
@@ -16,4 +16,11 @@ CTS_TEST(test_task_switch)
* has a higher priority, C should run first. This should result in C running
* one more time than A (or B).
*/
-CTS_TEST(test_task_priority) \ No newline at end of file
+CTS_TEST(test_task_priority)
+
+/*
+ * Test stack overflow. CTS task overflows the stack and it should be detected
+ * when task switch happens. Reboot is expected.
+ * TODO: Verify stack overflow detection and reboot.
+ */
+CTS_TEST(test_stack_overflow) \ No newline at end of file