From patchwork Wed Aug 5 21:01:13 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ivan Khoronzhuk X-Patchwork-Id: 51977 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f200.google.com (mail-lb0-f200.google.com [209.85.217.200]) by patches.linaro.org (Postfix) with ESMTPS id 7EB6C22A15 for ; Wed, 5 Aug 2015 21:05:34 +0000 (UTC) Received: by lbbnr7 with SMTP id nr7sf16927165lbb.2 for ; Wed, 05 Aug 2015 14:05:33 -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: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=r9dY93LIDLTOwZtbw5rp+0G9HFWeflrHTvrrcp9yng8=; b=UVR5ReV44Eqo84Okpylz4TZCfZkJlpOMqPj76dz+8FFSiFvK9Y5jtbJ3K6RL8rEByv LuWpYtBwnpodVeyyDvmaprWqtOxi1jHSnitYOMOH2MXDrV2vBLRrta3AZll8YYw4XuZN aj6oNpuJiAmxx2iRrD6LBg/mmgVdTqPw7+b/liEsYqiQVpqljDQf2R5FGZGJ9v6BXnup Y4rTdIS2mOtlWt2FnC8/BwhiXj+es0jkXiDpmsIrTAGRnPI0fPDchhUQAFeuXD7eeQ6/ 9ZvNV/yOZ8rHZZ6BrAsXob03PzTF15EmHQUpRTxivCf+eYOm2qrls335IqX6zC4zvzO4 qf/Q== X-Gm-Message-State: ALoCoQnotoLvPfnSq/UZRkh9OpMOUxceHVu/DUTWZmFtO+phlbbbY0kFq6aehJfemZtpdr8Ro2IT X-Received: by 10.152.25.233 with SMTP id f9mr3275780lag.5.1438808733451; Wed, 05 Aug 2015 14:05:33 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.44.228 with SMTP id h4ls244111lam.23.gmail; Wed, 05 Aug 2015 14:05:33 -0700 (PDT) X-Received: by 10.112.40.51 with SMTP id u19mr11311606lbk.44.1438808733300; Wed, 05 Aug 2015 14:05:33 -0700 (PDT) Received: from mail-la0-f54.google.com (mail-la0-f54.google.com. [209.85.215.54]) by mx.google.com with ESMTPS id kg7si2967976lbc.176.2015.08.05.14.05.32 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 05 Aug 2015 14:05:32 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.54 as permitted sender) client-ip=209.85.215.54; Received: by labow3 with SMTP id ow3so36990178lab.1 for ; Wed, 05 Aug 2015 14:05:32 -0700 (PDT) X-Received: by 10.152.18.162 with SMTP id x2mr11335355lad.73.1438808732859; Wed, 05 Aug 2015 14:05:32 -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 l6csp576241lba; Wed, 5 Aug 2015 14:05:31 -0700 (PDT) X-Received: by 10.140.30.33 with SMTP id c30mr20527391qgc.37.1438808731464; Wed, 05 Aug 2015 14:05:31 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id k109si7706872qgf.32.2015.08.05.14.05.30; Wed, 05 Aug 2015 14:05:31 -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 AB6A062071; Wed, 5 Aug 2015 21:05:30 +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 E60A562075; Wed, 5 Aug 2015 21:02:12 +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 36E1A6206C; Wed, 5 Aug 2015 21:02:05 +0000 (UTC) Received: from mail-wi0-f180.google.com (mail-wi0-f180.google.com [209.85.212.180]) by lists.linaro.org (Postfix) with ESMTPS id 8209D62064 for ; Wed, 5 Aug 2015 21:01:26 +0000 (UTC) Received: by wibhh20 with SMTP id hh20so41354053wib.0 for ; Wed, 05 Aug 2015 14:01:25 -0700 (PDT) X-Received: by 10.180.97.134 with SMTP id ea6mr2393293wib.63.1438808485577; Wed, 05 Aug 2015 14:01:25 -0700 (PDT) Received: from khorivan.synapse.com (46-148-93-178.pool.ukrtel.net. [178.93.148.46]) by smtp.gmail.com with ESMTPSA id rz9sm5931423wjb.8.2015.08.05.14.01.24 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 05 Aug 2015 14:01:25 -0700 (PDT) From: Ivan Khoronzhuk To: lng-odp@lists.linaro.org Date: Thu, 6 Aug 2015 00:01:13 +0300 Message-Id: <1438808473-26968-5-git-send-email-ivan.khoronzhuk@linaro.org> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1438808473-26968-1-git-send-email-ivan.khoronzhuk@linaro.org> References: <1438808473-26968-1-git-send-email-ivan.khoronzhuk@linaro.org> X-Topics: patch Subject: [lng-odp] [API-NEXT PATCH 4/4] linux-generic: odp_schedule: avoid "cycle" word usage 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: ivan.khoronzhuk@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.54 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 The word "cycle" is left from old API time names. The "cycle" is ambiguous word, especially when it can be used with software cycles. So better to use "time" word or just "t" symbol, as no matter in which units time is measured, in sec, hours, cycles or counts. Signed-off-by: Ivan Khoronzhuk --- platform/linux-generic/odp_schedule.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/platform/linux-generic/odp_schedule.c b/platform/linux-generic/odp_schedule.c index fb60fc1..f7c19a3 100644 --- a/platform/linux-generic/odp_schedule.c +++ b/platform/linux-generic/odp_schedule.c @@ -510,10 +510,10 @@ static int schedule_loop(odp_queue_t *out_queue, uint64_t wait, odp_event_t out_ev[], unsigned int max_num, unsigned int max_deq) { - uint64_t start_cycle, cycle, diff; + uint64_t start_time, time, diff; int ret; - start_cycle = 0; + start_time = 0; while (1) { ret = schedule(out_queue, out_ev, max_num, max_deq); @@ -527,13 +527,13 @@ static int schedule_loop(odp_queue_t *out_queue, uint64_t wait, if (wait == ODP_SCHED_NO_WAIT) break; - if (start_cycle == 0) { - start_cycle = odp_time_counts(); + if (start_time == 0) { + start_time = odp_time_counts(); continue; } - cycle = odp_time_counts(); - diff = odp_time_diff_counts(start_cycle, cycle); + time = odp_time_counts(); + diff = odp_time_diff_counts(start_time, time); if (wait < diff) break;