From patchwork Mon Jun 29 15:39:33 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Milard X-Patchwork-Id: 50436 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f198.google.com (mail-wi0-f198.google.com [209.85.212.198]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id D45D3228D9 for ; Mon, 29 Jun 2015 15:42:29 +0000 (UTC) Received: by wibdu3 with SMTP id du3sf9703292wib.2 for ; Mon, 29 Jun 2015 08:42:29 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:delivered-to:from:to:date :message-id:in-reply-to:references:cc:subject:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :mime-version:content-type:content-transfer-encoding:errors-to :sender:x-original-sender:x-original-authentication-results :mailing-list; bh=5PRV9T2hoskyLQolleW50GHO8xwSAXk1jlo53WcEkhU=; b=V428EPODjChEzdSUYndMwDNzro2aAM3tnLx8kH0BwFHaqTFDta8n051xQtQoIlMw8J hxldsmxJBQXSmB3+x3qpOx99OzKDQV7GyaqUrlwirnGK1dCpydVvl+/TkTaPRXzEs7jP fcOxoVzEGvsKygwIYa5NZpPrHCD4r5mRWbzd1B+fieaT4pZ1Vv5OHErrnaRrulRKLtXD wieCKaFyLeF3RhHnDpVW2jqEbeDE5bH4H2fo2D9OLyIm19OdkoOsDG0BWcPmYT+ITF3n wfyhrG1cjk3sddD5yzH7zM3lQaxYu047GMEykGGcBFsdmXe48EpFJSSqpYia5UVtO8Uk RFQA== X-Gm-Message-State: ALoCoQnkdST6BrGiSukWC9QMRDdDnmnyXnwyuB3CwFWraV+w3fAjnknFEqa9pnROIlVWipSEszGx X-Received: by 10.112.122.12 with SMTP id lo12mr11197177lbb.5.1435592549050; Mon, 29 Jun 2015 08:42:29 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.205.6 with SMTP id lc6ls794274lac.80.gmail; Mon, 29 Jun 2015 08:42:28 -0700 (PDT) X-Received: by 10.112.132.9 with SMTP id oq9mr14806325lbb.26.1435592548636; Mon, 29 Jun 2015 08:42:28 -0700 (PDT) Received: from mail-la0-f44.google.com (mail-la0-f44.google.com. [209.85.215.44]) by mx.google.com with ESMTPS id db5si13818748lac.73.2015.06.29.08.42.28 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 29 Jun 2015 08:42:28 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) client-ip=209.85.215.44; Received: by laar3 with SMTP id r3so68562186laa.0 for ; Mon, 29 Jun 2015 08:42:28 -0700 (PDT) X-Received: by 10.152.7.7 with SMTP id f7mr14900729laa.106.1435592548264; Mon, 29 Jun 2015 08:42:28 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.112.108.230 with SMTP id hn6csp1792817lbb; Mon, 29 Jun 2015 08:42:27 -0700 (PDT) X-Received: by 10.55.25.84 with SMTP id k81mr32953940qkh.85.1435592546864; Mon, 29 Jun 2015 08:42:26 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id a93si34765325qka.94.2015.06.29.08.42.26; Mon, 29 Jun 2015 08:42:26 -0700 (PDT) Received-SPF: pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) client-ip=54.225.227.206; Received: by lists.linaro.org (Postfix, from userid 109) id 09DAF61E07; Mon, 29 Jun 2015 15:42:26 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252.ec2.internal X-Spam-Level: X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, URIBL_BLOCKED autolearn=disabled version=3.4.0 Received: from ip-10-142-244-252.ec2.internal (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 4FECD61E04; Mon, 29 Jun 2015 15:40:31 +0000 (UTC) X-Original-To: lng-odp@lists.linaro.org Delivered-To: lng-odp@lists.linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id C439C61DFD; Mon, 29 Jun 2015 15:40:18 +0000 (UTC) Received: from mail-la0-f45.google.com (mail-la0-f45.google.com [209.85.215.45]) by lists.linaro.org (Postfix) with ESMTPS id 6C8EE61C7A for ; Mon, 29 Jun 2015 15:39:50 +0000 (UTC) Received: by lagc2 with SMTP id c2so14819633lag.3 for ; Mon, 29 Jun 2015 08:39:49 -0700 (PDT) X-Received: by 10.152.27.74 with SMTP id r10mr15018675lag.31.1435592389151; Mon, 29 Jun 2015 08:39:49 -0700 (PDT) Received: from erachmi-VirtualBox.ki.sw.ericsson.se (c-83-233-90-46.cust.bredband2.com. [83.233.90.46]) by mx.google.com with ESMTPSA id q9sm10847143lag.20.2015.06.29.08.39.47 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 29 Jun 2015 08:39:48 -0700 (PDT) From: Christophe Milard To: anders.roxell@linaro.org, mike.holmes@linaro.org, stuart.haslam@linaro.org, maxim.uvarov@linaro.org Date: Mon, 29 Jun 2015 17:39:33 +0200 Message-Id: <1435592374-3517-5-git-send-email-christophe.milard@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1435592374-3517-1-git-send-email-christophe.milard@linaro.org> References: <1435592374-3517-1-git-send-email-christophe.milard@linaro.org> X-Topics: patch Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [PATCHv2 4/5] validation: creating own dir and lib for queue X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: , List-Help: , List-Subscribe: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: christophe.milard@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 Module queue now gets its own directory and create its own lib (currentely only containing its executable) Signed-off-by: Christophe Milard Reviewed-by: Stuart Haslam --- configure.ac | 1 + test/validation/.gitignore | 1 - test/validation/Makefile.am | 8 +++----- test/validation/queue/.gitignore | 2 ++ test/validation/queue/Makefile.am | 8 ++++++++ test/validation/{odp_queue.c => queue/queue.c} | 9 ++------- test/validation/queue/queue.h | 7 +++++++ test/validation/queue/queue_main.c | 12 ++++++++++++ 8 files changed, 35 insertions(+), 13 deletions(-) create mode 100644 test/validation/queue/.gitignore create mode 100644 test/validation/queue/Makefile.am rename test/validation/{odp_queue.c => queue/queue.c} (95%) create mode 100644 test/validation/queue/queue.h create mode 100644 test/validation/queue/queue_main.c diff --git a/configure.ac b/configure.ac index f58b472..2aa804d 100644 --- a/configure.ac +++ b/configure.ac @@ -308,6 +308,7 @@ AC_CONFIG_FILES([Makefile test/validation/crypto/Makefile test/validation/init/Makefile test/validation/pktio/Makefile + test/validation/queue/Makefile test/validation/random/Makefile test/validation/system/Makefile test/miscellaneous/Makefile diff --git a/test/validation/.gitignore b/test/validation/.gitignore index 067914f..a8faaa2 100644 --- a/test/validation/.gitignore +++ b/test/validation/.gitignore @@ -5,7 +5,6 @@ odp_buffer odp_cpumask odp_packet odp_pool -odp_queue odp_scheduler odp_shared_memory odp_synchronizers diff --git a/test/validation/Makefile.am b/test/validation/Makefile.am index 1a774e1..8a24449 100644 --- a/test/validation/Makefile.am +++ b/test/validation/Makefile.am @@ -8,7 +8,6 @@ EXECUTABLES = odp_buffer \ odp_cpumask \ odp_packet \ odp_pool \ - odp_queue \ odp_scheduler \ odp_shared_memory \ odp_synchronizers \ @@ -17,7 +16,8 @@ EXECUTABLES = odp_buffer \ odp_ver_abt_log_dbg if test_vald -TESTS = $(EXECUTABLES) +TESTS = $(EXECUTABLES) \ + queue/queue_main endif bin_PROGRAMS = $(EXECUTABLES) $(COMPILE_ONLY) @@ -27,9 +27,6 @@ ODP_CU_COMMON=common/odp_cunit_common.c odp_buffer_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/buffer dist_odp_buffer_SOURCES = odp_buffer.c odp_crypto_CFLAGS = $(AM_CFLAGS) -I$(srcdir)/crypto -odp_queue_LDADD = $(top_builddir)/test/validation/common/libcunit_common.a \ - $(LIB)/libodp.la -dist_odp_queue_SOURCES = odp_queue.c dist_odp_scheduler_SOURCES = odp_scheduler.c dist_odp_shared_memory_SOURCES = odp_shared_memory.c dist_odp_synchronizers_SOURCES = odp_synchronizers.c @@ -46,6 +43,7 @@ dist_odp_ver_abt_log_dbg_SOURCES = ver_abt_log_dbg/odp_system.c \ ODP_MODULES = classification \ crypto \ init \ + queue \ pktio \ random \ system diff --git a/test/validation/queue/.gitignore b/test/validation/queue/.gitignore new file mode 100644 index 0000000..c9e4029 --- /dev/null +++ b/test/validation/queue/.gitignore @@ -0,0 +1,2 @@ +libqueue.a +queue_main diff --git a/test/validation/queue/Makefile.am b/test/validation/queue/Makefile.am new file mode 100644 index 0000000..93acd3c --- /dev/null +++ b/test/validation/queue/Makefile.am @@ -0,0 +1,8 @@ +include ../Makefile.inc + +noinst_LIBRARIES = libqueue.a +libqueue_a_SOURCES = queue.c + +bin_PROGRAMS = queue_main +dist_queue_main_SOURCES = queue_main.c +queue_main_LDADD = libqueue.a $(LIBCUNIT_COMMON) $(LIBODP) diff --git a/test/validation/odp_queue.c b/test/validation/queue/queue.c similarity index 95% rename from test/validation/odp_queue.c rename to test/validation/queue/queue.c index cf6f328..f686b71 100644 --- a/test/validation/odp_queue.c +++ b/test/validation/queue/queue.c @@ -6,6 +6,7 @@ #include #include +#include "queue.h" #define MAX_BUFFER_QUEUE (8) #define MSG_POOL_SIZE (4 * 1024 * 1024) @@ -117,13 +118,7 @@ static CU_SuiteInfo queue_suites[] = { CU_SUITE_INFO_NULL, }; -static int queue_main(void) +int queue_main(void) { return odp_cunit_run(queue_suites); } - -/* the following main function will be separated when lib is created */ -int main(void) -{ - return queue_main(); -} diff --git a/test/validation/queue/queue.h b/test/validation/queue/queue.h new file mode 100644 index 0000000..3e9a9f1 --- /dev/null +++ b/test/validation/queue/queue.h @@ -0,0 +1,7 @@ +/* Copyright (c) 2015, Linaro Limited + * All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +int queue_main(void); diff --git a/test/validation/queue/queue_main.c b/test/validation/queue/queue_main.c new file mode 100644 index 0000000..326f131 --- /dev/null +++ b/test/validation/queue/queue_main.c @@ -0,0 +1,12 @@ +/* Copyright (c) 2015, Linaro Limited + * All rights reserved. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +#include "queue.h" + +int main(void) +{ + return queue_main(); +}