@@ -7,6 +7,7 @@ AC_CONFIG_FILES([test/common_plat/Makefile
test/common_plat/miscellaneous/Makefile
test/common_plat/performance/Makefile
test/common_plat/validation/Makefile
+ test/common_plat/validation/api/Makefile
test/common_plat/validation/api/atomic/Makefile
test/common_plat/validation/api/barrier/Makefile
test/common_plat/validation/api/buffer/Makefile
@@ -17,7 +18,6 @@ AC_CONFIG_FILES([test/common_plat/Makefile
test/common_plat/validation/api/hash/Makefile
test/common_plat/validation/api/init/Makefile
test/common_plat/validation/api/lock/Makefile
- test/common_plat/validation/api/Makefile
test/common_plat/validation/api/packet/Makefile
test/common_plat/validation/api/pktio/Makefile
test/common_plat/validation/api/pool/Makefile
@@ -30,4 +30,6 @@ AC_CONFIG_FILES([test/common_plat/Makefile
test/common_plat/validation/api/thread/Makefile
test/common_plat/validation/api/time/Makefile
test/common_plat/validation/api/timer/Makefile
- test/common_plat/validation/api/traffic_mngr/Makefile])
+ test/common_plat/validation/api/traffic_mngr/Makefile
+ test/common_plat/validation/drv/Makefile
+ test/common_plat/validation/drv/atomic/Makefile])
@@ -1,3 +1,4 @@
if cunit_support
- SUBDIRS = api
+ SUBDIRS = api \
+ drv
endif
new file mode 100644
@@ -0,0 +1,16 @@
+include $(top_srcdir)/test/Makefile.inc
+
+COMMON_DIR = $(top_builddir)/test/common_plat/common
+
+#the following option ensure that option '-I.' is not passed to gcc,
+#therefore distinguishing between '#include "X"' and '#include <X>'.
+#It allows common filenames (such as 'errno.h') to be used locally.
+AUTOMAKE_OPTIONS = nostdinc
+
+AM_CFLAGS += -I$(top_srcdir)/test/common_plat/common
+AM_LDFLAGS += -static
+
+LIBCUNIT_COMMON = $(COMMON_DIR)/libcunit_common.la
+LIBCPUMASK_COMMON = $(COMMON_DIR)/libcpumask_common.la
+LIBTHRMASK_COMMON = $(COMMON_DIR)/libthrmask_common.la
+LIBODP = $(LIB)/libodphelper-linux.la $(LIB)/libodp-linux.la
@@ -1,16 +1 @@
-include $(top_srcdir)/test/Makefile.inc
-
-COMMON_DIR = $(top_builddir)/test/common_plat/common
-
-#the following option ensure that option '-I.' is not passed to gcc,
-#therefore distinguishing between '#include "X"' and '#include <X>'.
-#It allows common filenames (such as 'errno.h') to be used locally.
-AUTOMAKE_OPTIONS = nostdinc
-
-AM_CFLAGS += -I$(top_srcdir)/test/common_plat/common
-AM_LDFLAGS += -static
-
-LIBCUNIT_COMMON = $(COMMON_DIR)/libcunit_common.la
-LIBCPUMASK_COMMON = $(COMMON_DIR)/libcpumask_common.la
-LIBTHRMASK_COMMON = $(COMMON_DIR)/libthrmask_common.la
-LIBODP = $(LIB)/libodphelper-linux.la $(LIB)/libodp-linux.la
+include $(top_srcdir)/test/common_plat/validation/Makefile.inc
new file mode 100644
@@ -0,0 +1,2 @@
+*.log
+*.trs
new file mode 100644
@@ -0,0 +1,6 @@
+ODPDRV_MODULES = atomic
+
+SUBDIRS = $(ODPDRV_MODULES)
+
+#The tests will need to retain the deprecated test implementation
+AM_CFLAGS += -Wno-deprecated-declarations
new file mode 100644
@@ -0,0 +1 @@
+include $(top_srcdir)/test/common_plat/validation/Makefile.inc
new file mode 100644
@@ -0,0 +1,35 @@
+Copyright (c) 2015, Linaro Limited
+All rights reserved.
+
+SPDX-License-Identifier: BSD-3-Clause
+
+
+To add tests in here, please observe the rules listed below. This list
+is a brief overview, for a more detailed explanation of the test
+framework refer to the ODP Implementers' Guide, which can built as
+follows:
+
+ ./configure --enable-user-guides
+ make
+
+Output will be in doc/output/. If this fails, check the documentation
+section of the DEPENDENCIES file.
+
+Rules for all tests under this tree:
+
+1. Tests must be placed in the directory of the module they belong to.
+
+2. Tests must be platform agnostic, i.e.
+
+ - should be written in plain C only.
+ - may only use C standard library functions, CUnit functions and of
+ course ODP functions
+ - should be expected to pass on all ODP implementations
+
+ Tests that do not follow these rules should be placed in the platform
+ specific test area (currently platform/<platform>/test/).
+
+3. If a new ODP DRV module is created, please update the Makefile.am.
+
+4. Symbols exported from test libraries must respect the naming
+ convention detailed in the ODP Implementers' Guide.
new file mode 100644
@@ -0,0 +1,4 @@
+include ../Makefile.inc
+
+test_PROGRAMS = atomic_main$(EXEEXT)
+dist_atomic_main_SOURCES = atomic_main.c
new file mode 100644
@@ -0,0 +1,10 @@
+/* Copyright (c) 2016, Linaro Limited
+ * All rights reserved.
+ *
+ * SPDX-License-Identifier: BSD-3-Clause
+ */
+
+int main(void)
+{
+ return 0;
+}
@@ -2,6 +2,7 @@ include $(top_srcdir)/test/Makefile.inc
TESTS_ENVIRONMENT += TEST_DIR=${top_builddir}/test/common_plat/validation
ALL_API_VALIDATION_DIR = ${top_builddir}/test/common_plat/validation/api
+ALL_DRV_VALIDATION_DIR = ${top_builddir}/test/common_plat/validation/drv
SUBDIRS =
@@ -9,6 +10,7 @@ if test_vald
TESTS = validation/api/pktio/pktio_run.sh \
validation/api/pktio/pktio_run_tap.sh \
validation/api/shmem/shmem_linux \
+ $(ALL_DRV_VALIDATION_DIR)/atomic/atomic_main$(EXEEXT) \
$(ALL_API_VALIDATION_DIR)/atomic/atomic_main$(EXEEXT) \
$(ALL_API_VALIDATION_DIR)/barrier/barrier_main$(EXEEXT) \
$(ALL_API_VALIDATION_DIR)/buffer/buffer_main$(EXEEXT) \
The new structure for validation tests aiming the drv interface of ODP is added (around a first DRV atomic test empty skeleton) Signed-off-by: Christophe Milard <christophe.milard@linaro.org> --- test/common_plat/m4/configure.m4 | 6 ++-- test/common_plat/validation/Makefile.am | 3 +- test/common_plat/validation/Makefile.inc | 16 ++++++++++ test/common_plat/validation/api/Makefile.inc | 17 +---------- test/common_plat/validation/drv/.gitignore | 2 ++ test/common_plat/validation/drv/Makefile.am | 6 ++++ test/common_plat/validation/drv/Makefile.inc | 1 + test/common_plat/validation/drv/README | 35 ++++++++++++++++++++++ test/common_plat/validation/drv/atomic/Makefile.am | 4 +++ .../validation/drv/atomic/atomic_main.c | 10 +++++++ test/linux-generic/Makefile.am | 2 ++ 11 files changed, 83 insertions(+), 19 deletions(-) create mode 100644 test/common_plat/validation/Makefile.inc create mode 100644 test/common_plat/validation/drv/.gitignore create mode 100644 test/common_plat/validation/drv/Makefile.am create mode 100644 test/common_plat/validation/drv/Makefile.inc create mode 100644 test/common_plat/validation/drv/README create mode 100644 test/common_plat/validation/drv/atomic/Makefile.am create mode 100644 test/common_plat/validation/drv/atomic/atomic_main.c -- 2.7.4