summaryrefslogtreecommitdiff
path: root/nuttx/examples/ostest/ostest.h
diff options
context:
space:
mode:
authorpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2008-09-18 23:42:12 +0000
committerpatacongo <patacongo@42af7a65-404d-4744-a932-0658087f49c3>2008-09-18 23:42:12 +0000
commit6f83493635cb3507332725d981ac00053414b4ab (patch)
treead8d0630ff15a2f3818b0d981b7c49cab4a14787 /nuttx/examples/ostest/ostest.h
parentda90ea4a7f3443a13b79cf0c9197f1f3736fc188 (diff)
downloadnuttx-6f83493635cb3507332725d981ac00053414b4ab.tar.gz
nuttx-6f83493635cb3507332725d981ac00053414b4ab.tar.bz2
nuttx-6f83493635cb3507332725d981ac00053414b4ab.zip
Make number of threads in barrier test configurable
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@935 42af7a65-404d-4744-a932-0658087f49c3
Diffstat (limited to 'nuttx/examples/ostest/ostest.h')
-rw-r--r--nuttx/examples/ostest/ostest.h31
1 files changed, 27 insertions, 4 deletions
diff --git a/nuttx/examples/ostest/ostest.h b/nuttx/examples/ostest/ostest.h
index 08396b3ff..c94412cc1 100644
--- a/nuttx/examples/ostest/ostest.h
+++ b/nuttx/examples/ostest/ostest.h
@@ -37,17 +37,40 @@
#define __OSTEST_H
/****************************************************************************
- * Compilation Switches
- ****************************************************************************/
-
-/****************************************************************************
* Included Files
****************************************************************************/
+#include <nuttx/config.h>
+
/****************************************************************************
* Definitions
****************************************************************************/
+/* The task_create task size can be specified in the defconfig file */
+
+#ifdef CONFIG_EXAMPLES_OSTEST_STACKSIZE
+# define STACKSIZE CONFIG_EXAMPLES_OSTEST_STACKSIZE
+#else
+# define STACKSIZE 8192
+#endif
+
+/* The number of times to execute the test can be specified in the defconfig
+ * file.
+ */
+
+#ifndef CONFIG_EXAMPLES_OSTEST_LOOPS
+# define CONFIG_EXAMPLES_OSTEST_LOOPS 1
+#endif
+
+/* This is the number of threads that are created in the barrier test.
+ * A smaller number should be selected on systems without sufficient memory
+ * to start so many threads.
+ */
+
+#ifndef CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS
+# define CONFIG_EXAMPLES_OSTEST_NBARRIER_THREADS 8
+#endif
+
/****************************************************************************
* Public Types
****************************************************************************/