From patchwork Wed Jul 1 08:19:30 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Milard X-Patchwork-Id: 50510 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wg0-f71.google.com (mail-wg0-f71.google.com [74.125.82.71]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 47E5E214B3 for ; Wed, 1 Jul 2015 08:20:59 +0000 (UTC) Received: by wgjx7 with SMTP id x7sf10900771wgj.3 for ; Wed, 01 Jul 2015 01:20:58 -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=LhCFq9TmiVM4RspIPyXv/U5NtdK3RpYoU3EkKnUHeGQ=; b=WV70oiRXNTypW5NGYhVyt8g7ts5x+YGndsUPeCwBF5j9u+foyWI8HJ8RsB+p95xd7e wK3SC7ym6Gn4382rUny26o1AqHu5ZZR5EW4oc4FTrScjpTSmnD69D6hUHraynV44bsOd r6QQVugMcGItJon+Q+bdg/Vp7S0IU55N0KUbmv/k4fBZ/he828nJoyLwacBYBMjMh8MJ Ejy2ifulokD/Bj5OjaDggG5xlVUsn2DVWHi+JGLIDXp601lxwBcko90XP4xNeD8mt/wF 5PQXQ0oQxpL1kMVVMLOQOmLI94nyMJJT87Q47dOUvqFV/LS9mrPkOeSFrZ3jDoUQYDbk s90A== X-Gm-Message-State: ALoCoQlvepBGTfg5199LSib823oq6udbspHsrhRb8EtfuXlZsO+PhQRrq6jDgKiwE2Mh/aOB+QQG X-Received: by 10.152.179.136 with SMTP id dg8mr16509036lac.4.1435738858701; Wed, 01 Jul 2015 01:20:58 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.9.7 with SMTP id v7ls148799laa.75.gmail; Wed, 01 Jul 2015 01:20:58 -0700 (PDT) X-Received: by 10.152.234.42 with SMTP id ub10mr23533109lac.60.1435738858430; Wed, 01 Jul 2015 01:20:58 -0700 (PDT) Received: from mail-la0-f48.google.com (mail-la0-f48.google.com. [209.85.215.48]) by mx.google.com with ESMTPS id mk5si1052713lbc.47.2015.07.01.01.20.58 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 01 Jul 2015 01:20:58 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.48 as permitted sender) client-ip=209.85.215.48; Received: by lagh6 with SMTP id h6so35575535lag.2 for ; Wed, 01 Jul 2015 01:20:58 -0700 (PDT) X-Received: by 10.152.22.99 with SMTP id c3mr24446085laf.32.1435738858290; Wed, 01 Jul 2015 01:20:58 -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 hn6csp436002lbb; Wed, 1 Jul 2015 01:20:57 -0700 (PDT) X-Received: by 10.140.39.49 with SMTP id u46mr32122064qgu.5.1435738856942; Wed, 01 Jul 2015 01:20:56 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id y39si1354976qgy.79.2015.07.01.01.20.56; Wed, 01 Jul 2015 01:20:56 -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 200C861E5C; Wed, 1 Jul 2015 08:20:56 +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 679AA61F05; Wed, 1 Jul 2015 08:20:01 +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 1018D61EFB; Wed, 1 Jul 2015 08:19:56 +0000 (UTC) Received: from mail-la0-f44.google.com (mail-la0-f44.google.com [209.85.215.44]) by lists.linaro.org (Postfix) with ESMTPS id 772BE61CCB for ; Wed, 1 Jul 2015 08:19:49 +0000 (UTC) Received: by lagh6 with SMTP id h6so35556931lag.2 for ; Wed, 01 Jul 2015 01:19:48 -0700 (PDT) X-Received: by 10.112.168.102 with SMTP id zv6mr24032470lbb.45.1435738788401; Wed, 01 Jul 2015 01:19:48 -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 x4sm286638lag.40.2015.07.01.01.19.46 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 01 Jul 2015 01:19:47 -0700 (PDT) From: Christophe Milard To: anders.roxell@linaro.org, mike.holmes@linaro.org, stuart.haslam@linaro.org, maxim.uvarov@linaro.org Date: Wed, 1 Jul 2015 10:19:30 +0200 Message-Id: <1435738773-31515-3-git-send-email-christophe.milard@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1435738773-31515-1-git-send-email-christophe.milard@linaro.org> References: <1435738773-31515-1-git-send-email-christophe.milard@linaro.org> X-Topics: patch Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [PATCH 2/5] validation: renaming in odp_thread.c 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.48 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 Renaming of things which may be, one day, exported in a lib. This renaming is important, as it creates consistency between test symbols, which is needed if things get eventually exported in the lib. Also, tests are often created from other tests: Fixing the first exemples will help geting future tests better. Things that are candidate to be exported in the lib in the future have been named as follows: -Tests, i.e. functions which are used in CUNIT testsuites are named: _test_* -Test arrays, i.e. arrays of CU_TestInfo, listing the test functions belonging to a suite, are called: _suite[_*] where the possible suffix can be used if many suites are declared. -CUNIT suite init and termination functions are called: _suite[_*]_init() and _suite[_*]_term() respectively. -Suite arrays, i.e. arrays of CU_SuiteInfo used in executables are called: _suites[_*] where the possible suffix identifies the executable using it, if many. -Main function(s), are called: _main[_*] where the possible suffix identifies the executable using it Signed-off-by: Christophe Milard --- test/validation/odp_thread.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/test/validation/odp_thread.c b/test/validation/odp_thread.c index 96d624c..e08a284 100644 --- a/test/validation/odp_thread.c +++ b/test/validation/odp_thread.c @@ -10,33 +10,33 @@ /* Helper macro for CU_TestInfo initialization */ #define _CU_TEST_INFO(test_func) {#test_func, test_func} -static void test_odp_cpu_id(void) +static void thread_test_odp_cpu_id(void) { (void) odp_cpu_id(); CU_PASS(); } -static void test_odp_thread_id(void) +static void thread_test_odp_thread_id(void) { (void) odp_thread_id(); CU_PASS(); } -static void test_odp_thread_count(void) +static void thread_test_odp_thread_count(void) { (void) odp_thread_count(); CU_PASS(); } -static CU_TestInfo test_odp_thread[] = { - _CU_TEST_INFO(test_odp_cpu_id), - _CU_TEST_INFO(test_odp_thread_id), - _CU_TEST_INFO(test_odp_thread_count), +static CU_TestInfo thread_suite[] = { + _CU_TEST_INFO(thread_test_odp_cpu_id), + _CU_TEST_INFO(thread_test_odp_thread_id), + _CU_TEST_INFO(thread_test_odp_thread_count), CU_TEST_INFO_NULL, }; static CU_SuiteInfo thread_suites[] = { - {"thread", NULL, NULL, NULL, NULL, test_odp_thread}, + {"thread", NULL, NULL, NULL, NULL, thread_suite}, CU_SUITE_INFO_NULL, };