From patchwork Fri Sep 23 13:44:19 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Maxim Uvarov X-Patchwork-Id: 76871 Delivered-To: patch@linaro.org Received: by 10.140.106.72 with SMTP id d66csp577837qgf; Fri, 23 Sep 2016 06:45:02 -0700 (PDT) X-Received: by 10.237.44.195 with SMTP id g61mr7787723qtd.144.1474638302256; Fri, 23 Sep 2016 06:45:02 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id u38si5199175qtc.60.2016.09.23.06.44.59; Fri, 23 Sep 2016 06:45:02 -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; Authentication-Results: mx.google.com; spf=pass (google.com: domain of lng-odp-bounces@lists.linaro.org designates 54.225.227.206 as permitted sender) smtp.mailfrom=lng-odp-bounces@lists.linaro.org; dmarc=pass (p=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 613E0617CB; Fri, 23 Sep 2016 13:44:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on ip-10-142-244-252 X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL autolearn=disabled version=3.4.0 Received: from [127.0.0.1] (localhost [127.0.0.1]) by lists.linaro.org (Postfix) with ESMTP id 04FCB6178E; Fri, 23 Sep 2016 13:44:58 +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 4492A617D1; Fri, 23 Sep 2016 13:44:56 +0000 (UTC) Received: from mail-lf0-f51.google.com (mail-lf0-f51.google.com [209.85.215.51]) by lists.linaro.org (Postfix) with ESMTPS id BF9E8617C0 for ; Fri, 23 Sep 2016 13:44:36 +0000 (UTC) Received: by mail-lf0-f51.google.com with SMTP id b71so66706887lfg.0 for ; Fri, 23 Sep 2016 06:44:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=lXbCZIWNaP/0MOcz8qDPvreFGPo206MXbh771bnGrAI=; b=Vi8I7RNgyj+FvyeS2v9tgIauPWMgSeA4GXWta47DNeza8ZVmwQGPVxnIVw260GH5+n lgipvWUXCyKMBBr49W0eH10w+rxj8jTk9QnHDTYHzon7kbqSjNsRp9JTtWXeZv1QKcuw fkI/cJ0wVn0lpKMr4HCUA4ZNWHMu3obiqAF1nnIL3fJwqLc9thRatyp3BrFx5U3s3vQI 8lZUZdg7puwh+ObPqgk700ISaaC9MVWEenBLX9Jdy9Q8qq7iTiEi8eqY2muOJsJF4VDK EySkUEAr0Fz3ZIJL2iDrt9yYFW5VGE98PcIpftL3muZyGWkUpr+N5BG2w3FS/CcESF3N UTAA== X-Gm-Message-State: AE9vXwOMFiMZsL3NzOTDmfwS1ozZoW4x0k3sD2H3rYZFW6rzfsQFskUxs5yUULkxQssPjlqwjnA= X-Received: by 10.25.161.85 with SMTP id k82mr3222864lfe.90.1474638275596; Fri, 23 Sep 2016 06:44:35 -0700 (PDT) Received: from localhost.localdomain ([83.220.239.14]) by smtp.gmail.com with ESMTPSA id a6sm1218156lfb.24.2016.09.23.06.44.32 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 23 Sep 2016 06:44:35 -0700 (PDT) From: Maxim Uvarov To: lng-odp@lists.linaro.org Date: Fri, 23 Sep 2016 16:44:19 +0300 Message-Id: <1474638259-3431-1-git-send-email-maxim.uvarov@linaro.org> X-Mailer: git-send-email 2.7.4 X-Topics: patch Subject: [lng-odp] [PATCH] test: skip pktio_perf tests on 1 and 2 cpus machines X-BeenThere: lng-odp@lists.linaro.org X-Mailman-Version: 2.1.16 Precedence: list List-Id: "The OpenDataPlane \(ODP\) List" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Make check should skip the test instead of failing it. Signed-off-by: Maxim Uvarov --- test/common_plat/performance/odp_pktio_perf.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) -- 2.7.4 diff --git a/test/common_plat/performance/odp_pktio_perf.c b/test/common_plat/performance/odp_pktio_perf.c index f041b13..846dfaa 100644 --- a/test/common_plat/performance/odp_pktio_perf.c +++ b/test/common_plat/performance/odp_pktio_perf.c @@ -34,6 +34,8 @@ #include #include +#define TEST_SKIP 77 + #define PKT_BUF_NUM 8192 #define MAX_NUM_IFACES 2 #define TEST_HDR_MAGIC 0x92749451 @@ -558,7 +560,7 @@ static int setup_txrx_masks(odp_cpumask_t *thd_mask_tx, gbl_args->args.cpu_count); if (num_workers < 2) { LOG_ERR("Need at least two cores\n"); - return -1; + return TEST_SKIP; } if (gbl_args->args.num_tx_workers) { @@ -669,8 +671,9 @@ static int run_test(void) .warmup = 1, }; - if (setup_txrx_masks(&txmask, &rxmask) != 0) - return -1; + ret = setup_txrx_masks(&txmask, &rxmask); + if (ret) + return ret; printf("Starting test with params:\n"); printf("\tTransmit workers: \t%d\n", odp_cpumask_count(&txmask)); @@ -691,8 +694,11 @@ static int run_test(void) run_test_single(&txmask, &rxmask, &status); status.warmup = 0; - while (ret > 0) + while (1) { ret = run_test_single(&txmask, &rxmask, &status); + if (ret) + break; + } return ret; }