From patchwork Fri Jul 24 11:27:31 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christophe Milard X-Patchwork-Id: 51426 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f199.google.com (mail-lb0-f199.google.com [209.85.217.199]) by patches.linaro.org (Postfix) with ESMTPS id 600A320323 for ; Fri, 24 Jul 2015 11:37:59 +0000 (UTC) Received: by lbvb1 with SMTP id b1sf6535682lbv.3 for ; Fri, 24 Jul 2015 04:37: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=RvyPKAENTo3XdqU8gIBUVjWmJRfz25BsE3dCKEZfxRU=; b=MJQJGHj0BtV9c0AS8U8U7R2JiEmsuTZdV/SGtfbMr9z49/gDDPxrBlXAvtXW7BbSMm f+RLei+FSa25PCbd2ePgMESYMBPJyPS6qlCWXo3EmvH6L31e4JjyKoM7pOuVRUz+h4Dq 3W83kN68SF/pizN3plsBiDoBLBsvtU4/B1Q1g+ZK4wvYnEAU+oc1WEVpaqLQr16Th5cl fk4g8zk6X28ZWnMmrLvyosJi7QG6429/CvG8lPPpV6w3O783PB3X0/V9qCtS39mHxhWH yh1B7yMKpI8YFd4L0epkcglM4GKfEgYRlKU3oUltIgZLdFu2HzdJ2ziL2a/9oA1gkg6f RR1g== X-Gm-Message-State: ALoCoQkaOBnIKjBoFOrkzK37QDuU1cqAmxViaQRWq8bqYYt41dgE1XiTFMaMBWODNDBNJ23Iv8/A X-Received: by 10.112.171.41 with SMTP id ar9mr6060911lbc.24.1437737878309; Fri, 24 Jul 2015 04:37:58 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.204.9 with SMTP id ku9ls342051lac.37.gmail; Fri, 24 Jul 2015 04:37:58 -0700 (PDT) X-Received: by 10.152.21.5 with SMTP id r5mr12874299lae.107.1437737878159; Fri, 24 Jul 2015 04:37:58 -0700 (PDT) Received: from mail-la0-f41.google.com (mail-la0-f41.google.com. [209.85.215.41]) by mx.google.com with ESMTPS id m5si7265365laf.170.2015.07.24.04.37.58 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 Jul 2015 04:37:58 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.41 as permitted sender) client-ip=209.85.215.41; Received: by lagw2 with SMTP id w2so12393453lag.3 for ; Fri, 24 Jul 2015 04:37:58 -0700 (PDT) X-Received: by 10.152.6.69 with SMTP id y5mr13081204lay.72.1437737878055; Fri, 24 Jul 2015 04:37: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.7.198 with SMTP id l6csp1118807lba; Fri, 24 Jul 2015 04:37:57 -0700 (PDT) X-Received: by 10.55.15.75 with SMTP id z72mr19011109qkg.58.1437737876638; Fri, 24 Jul 2015 04:37:56 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id z192si2395712qhd.87.2015.07.24.04.37.54; Fri, 24 Jul 2015 04:37: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 23F5F61B5E; Fri, 24 Jul 2015 11:37:54 +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_H2, 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 20D2F61D69; Fri, 24 Jul 2015 11:30:10 +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 E3FD761D14; Fri, 24 Jul 2015 11:30:00 +0000 (UTC) Received: from mail-lb0-f176.google.com (mail-lb0-f176.google.com [209.85.217.176]) by lists.linaro.org (Postfix) with ESMTPS id 1259B61C6B for ; Fri, 24 Jul 2015 11:28:17 +0000 (UTC) Received: by lbbzr7 with SMTP id zr7so13239750lbb.1 for ; Fri, 24 Jul 2015 04:28:16 -0700 (PDT) X-Received: by 10.112.155.164 with SMTP id vx4mr13098253lbb.38.1437737296034; Fri, 24 Jul 2015 04:28:16 -0700 (PDT) Received: from erachmi-VirtualBox.ki.sw.ericsson.se (c-83-233-90-46.cust.bredband2.com. [83.233.90.46]) by smtp.gmail.com with ESMTPSA id y1sm1582274lal.39.2015.07.24.04.28.14 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 24 Jul 2015 04:28:15 -0700 (PDT) From: Christophe Milard To: anders.roxell@linaro.org, mike.holmes@linaro.org, stuart.haslam@linaro.org Date: Fri, 24 Jul 2015 13:27:31 +0200 Message-Id: <1437737259-16953-13-git-send-email-christophe.milard@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1437737259-16953-1-git-send-email-christophe.milard@linaro.org> References: <1437737259-16953-1-git-send-email-christophe.milard@linaro.org> X-Topics: patch Cc: lng-odp@lists.linaro.org Subject: [lng-odp] [PATCHv2 12/20] validation: cpumask: lib populated 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.41 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 test symbols are now exported in the module lib. Signed-off-by: Christophe Milard --- test/validation/cpumask/cpumask.c | 32 ++++++++++++++++---------------- test/validation/cpumask/cpumask.h | 25 +++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 16 deletions(-) diff --git a/test/validation/cpumask/cpumask.c b/test/validation/cpumask/cpumask.c index 943a8e0..f117242 100644 --- a/test/validation/cpumask/cpumask.c +++ b/test/validation/cpumask/cpumask.c @@ -79,7 +79,7 @@ static unsigned int get_max_number_of_cpus_in_a_mask(void) return odp_cpu_count(); } -static void cpumask_test_odp_cpumask_to_from_str(void) +void cpumask_test_odp_cpumask_to_from_str(void) { odp_cpumask_t mask; int32_t str_sz; @@ -151,7 +151,7 @@ static void cpumask_test_odp_cpumask_to_from_str(void) free(buf_in); } -static void cpumask_test_odp_cpumask_equal(void) +void cpumask_test_odp_cpumask_equal(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -182,7 +182,7 @@ static void cpumask_test_odp_cpumask_equal(void) CU_ASSERT_FALSE(odp_cpumask_equal(&mask1, &mask3)); } -static void cpumask_test_odp_cpumask_zero(void) +void cpumask_test_odp_cpumask_zero(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -193,7 +193,7 @@ static void cpumask_test_odp_cpumask_zero(void) CU_ASSERT(odp_cpumask_equal(&mask1, &mask2)); } -static void cpumask_test_odp_cpumask_set(void) +void cpumask_test_odp_cpumask_set(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -215,7 +215,7 @@ static void cpumask_test_odp_cpumask_set(void) CU_ASSERT(odp_cpumask_equal(&mask1, &mask2)); } -static void cpumask_test_odp_cpumask_clr(void) +void cpumask_test_odp_cpumask_clr(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -242,7 +242,7 @@ static void cpumask_test_odp_cpumask_clr(void) CU_ASSERT(odp_cpumask_equal(&mask1, &mask2)); } -static void cpumask_test_odp_cpumask_isset(void) +void cpumask_test_odp_cpumask_isset(void) { odp_cpumask_t mask1; @@ -262,7 +262,7 @@ static void cpumask_test_odp_cpumask_isset(void) CU_ASSERT_FALSE(odp_cpumask_isset(&mask1, 3)); } -static void cpumask_test_odp_cpumask_count(void) +void cpumask_test_odp_cpumask_count(void) { odp_cpumask_t mask1; @@ -279,7 +279,7 @@ static void cpumask_test_odp_cpumask_count(void) CU_ASSERT(odp_cpumask_count(&mask1) == 2); } -static void cpumask_test_odp_cpumask_and(void) +void cpumask_test_odp_cpumask_and(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -314,7 +314,7 @@ static void cpumask_test_odp_cpumask_and(void) CU_ASSERT(odp_cpumask_equal(&mask3, &mask4)); } -static void cpumask_test_odp_cpumask_or(void) +void cpumask_test_odp_cpumask_or(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -349,7 +349,7 @@ static void cpumask_test_odp_cpumask_or(void) CU_ASSERT(odp_cpumask_equal(&mask3, &mask4)); } -static void cpumask_test_odp_cpumask_xor(void) +void cpumask_test_odp_cpumask_xor(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -384,7 +384,7 @@ static void cpumask_test_odp_cpumask_xor(void) CU_ASSERT(odp_cpumask_equal(&mask3, &mask4)); } -static void cpumask_test_odp_cpumask_copy(void) +void cpumask_test_odp_cpumask_copy(void) { odp_cpumask_t mask1; odp_cpumask_t mask2; @@ -394,7 +394,7 @@ static void cpumask_test_odp_cpumask_copy(void) CU_ASSERT(odp_cpumask_equal(&mask1, &mask2)); } -static void cpumask_test_odp_cpumask_first(void) +void cpumask_test_odp_cpumask_first(void) { odp_cpumask_t mask1; @@ -413,7 +413,7 @@ static void cpumask_test_odp_cpumask_first(void) CU_ASSERT(odp_cpumask_first(&mask1) == 1); } -static void cpumask_test_odp_cpumask_last(void) +void cpumask_test_odp_cpumask_last(void) { odp_cpumask_t mask1; @@ -432,7 +432,7 @@ static void cpumask_test_odp_cpumask_last(void) CU_ASSERT(odp_cpumask_last(&mask1) == 3); } -static void cpumask_test_odp_cpumask_next(void) +void cpumask_test_odp_cpumask_next(void) { unsigned int i; int expected[] = {1, 3, 3, -1}; @@ -456,7 +456,7 @@ static void cpumask_test_odp_cpumask_next(void) CU_ASSERT(odp_cpumask_next(&mask1, i) == expected[i]); } -static CU_TestInfo cpumask_suite[] = { +CU_TestInfo cpumask_suite[] = { {"odp_cpumask_to/from_str()", cpumask_test_odp_cpumask_to_from_str}, {"odp_cpumask_equal()", cpumask_test_odp_cpumask_equal}, {"odp_cpumask_zero()", cpumask_test_odp_cpumask_zero}, @@ -474,7 +474,7 @@ static CU_TestInfo cpumask_suite[] = { CU_TEST_INFO_NULL, }; -static CU_SuiteInfo cpumask_suites[] = { +CU_SuiteInfo cpumask_suites[] = { {"Cpumask", NULL, NULL, NULL, NULL, cpumask_suite}, CU_SUITE_INFO_NULL, }; diff --git a/test/validation/cpumask/cpumask.h b/test/validation/cpumask/cpumask.h index 2c6fb4a..fe2e52c 100644 --- a/test/validation/cpumask/cpumask.h +++ b/test/validation/cpumask/cpumask.h @@ -7,6 +7,31 @@ #ifndef _ODP_TEST_CPUMASK_H_ #define _ODP_TEST_CPUMASK_H_ +#include + +/* test functions: */ +void cpumask_test_odp_cpumask_to_from_str(void); +void cpumask_test_odp_cpumask_equal(void); +void cpumask_test_odp_cpumask_zero(void); +void cpumask_test_odp_cpumask_set(void); +void cpumask_test_odp_cpumask_clr(void); +void cpumask_test_odp_cpumask_isset(void); +void cpumask_test_odp_cpumask_count(void); +void cpumask_test_odp_cpumask_and(void); +void cpumask_test_odp_cpumask_or(void); +void cpumask_test_odp_cpumask_xor(void); +void cpumask_test_odp_cpumask_copy(void); +void cpumask_test_odp_cpumask_first(void); +void cpumask_test_odp_cpumask_last(void); +void cpumask_test_odp_cpumask_next(void); + +/* test arrays: */ +extern CU_TestInfo cpumask_suite[]; + +/* test registery: */ +extern CU_SuiteInfo cpumask_suites[]; + +/* main test program: */ int cpumask_main(void); #endif