From patchwork Fri Aug 7 11:47:13 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 52035 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f72.google.com (mail-la0-f72.google.com [209.85.215.72]) by patches.linaro.org (Postfix) with ESMTPS id 677D220539 for ; Fri, 7 Aug 2015 11:55:41 +0000 (UTC) Received: by labth1 with SMTP id th1sf38858103lab.2 for ; Fri, 07 Aug 2015 04:55:40 -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=1VvZK0oWEk+bcPaJoiVkeuwi4hrM85lJMT/4QlheIjU=; b=Lg3U8Cwv1L8pxAPSFQ5Pxki1kkAqFWozQQ0c85V6Yr++rfD/Tl9SH4AG2/BUOMssiu y3jKTp6sbjJ7N5Dr0Q9Gznz64eRt/LtZsIw8QN96+oe3+HKWc+1Vklky8SY0EprXTYar kyOyF7pEOnUE+XB5uySLF/nxgnfbeiDrVVBPVaCJbI+sDc0NKymE2Otaeg1S+Hq69Vt7 2lYi07MxEJkvU/oQ73NLija610j+QIOKL+nJVjHhoPjTxVoj7b0n4iByKsd8lP6gsSW0 BUSqE+xTlFC5FLSztCHYXP4ZTya1VHjlRMqa5r1H3vyF8NuKE6BgXGVoxSHmB+iTfvhv vezw== X-Gm-Message-State: ALoCoQldsMrYva0vHlPXsSVmy/kIw6paBuYe5gYXykqjTu2hKcU46R2GYFUIgF5DCweUCHVWi5Ik X-Received: by 10.152.28.100 with SMTP id a4mr2032685lah.4.1438948540341; Fri, 07 Aug 2015 04:55:40 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.7.146 with SMTP id j18ls437590laa.44.gmail; Fri, 07 Aug 2015 04:55:40 -0700 (PDT) X-Received: by 10.152.239.135 with SMTP id vs7mr6697876lac.18.1438948540190; Fri, 07 Aug 2015 04:55:40 -0700 (PDT) Received: from mail-lb0-f177.google.com (mail-lb0-f177.google.com. [209.85.217.177]) by mx.google.com with ESMTPS id la8si6319378lac.28.2015.08.07.04.55.39 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 07 Aug 2015 04:55:39 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.177 as permitted sender) client-ip=209.85.217.177; Received: by lbbyj8 with SMTP id yj8so59481446lbb.0 for ; Fri, 07 Aug 2015 04:55:39 -0700 (PDT) X-Received: by 10.152.203.134 with SMTP id kq6mr7125895lac.106.1438948539736; Fri, 07 Aug 2015 04:55:39 -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 l6csp322754lba; Fri, 7 Aug 2015 04:55:38 -0700 (PDT) X-Received: by 10.55.51.15 with SMTP id z15mr12438092qkz.86.1438948538309; Fri, 07 Aug 2015 04:55:38 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id f188si17396828qhe.92.2015.08.07.04.55.37; Fri, 07 Aug 2015 04:55:38 -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 68A0B6206F; Fri, 7 Aug 2015 11:55:37 +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 196A76218C; Fri, 7 Aug 2015 11:48:50 +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 7C986621FA; Fri, 7 Aug 2015 11:48:46 +0000 (UTC) Received: from mail-ob0-f174.google.com (mail-ob0-f174.google.com [209.85.214.174]) by lists.linaro.org (Postfix) with ESMTPS id B12DC62185 for ; Fri, 7 Aug 2015 11:47:30 +0000 (UTC) Received: by obbfr1 with SMTP id fr1so40390658obb.1 for ; Fri, 07 Aug 2015 04:47:30 -0700 (PDT) X-Received: by 10.60.34.104 with SMTP id y8mr6407373oei.77.1438948050199; Fri, 07 Aug 2015 04:47:30 -0700 (PDT) Received: from localhost.localdomain (cpe-24-28-70-239.austin.res.rr.com. [24.28.70.239]) by smtp.gmail.com with ESMTPSA id f128sm338865oig.2.2015.08.07.04.47.29 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 07 Aug 2015 04:47:29 -0700 (PDT) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Fri, 7 Aug 2015 06:47:13 -0500 Message-Id: <1438948036-31868-11-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1438948036-31868-1-git-send-email-bill.fischofer@linaro.org> References: <1438948036-31868-1-git-send-email-bill.fischofer@linaro.org> X-Topics: patch Subject: [lng-odp] [API-NEXT PATCHv9 10/13] api: schedule: add APIs for order copying and sustaining 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: bill.fischofer@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.217.177 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 Signed-off-by: Bill Fischofer --- include/odp/api/schedule.h | 51 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 51 insertions(+) diff --git a/include/odp/api/schedule.h b/include/odp/api/schedule.h index f27bf78..61d3b16 100644 --- a/include/odp/api/schedule.h +++ b/include/odp/api/schedule.h @@ -174,6 +174,57 @@ void odp_schedule_release_atomic(void); int odp_schedule_release_ordered(odp_event_t ev); /** + * Copy order from one event to another + * + * This call copies the order associated with an event originating from an + * ordered queue to another event. The target event must not have an + * associated ordering at input to the call. If the target is ordered, the + * prior ordering must first be released by an odp_schedule_release_ordered() + * call. Successfuly copying an order implicitly sets the order sustain + * attribute for the src_event as if odp_schedule_order_sustain() were called + * for it. + * + * @param src_event Event whose ordering is to be copied + * @param dst_event Event to receive the same ordering as src_event. + * + * @retval 0 Success + * @retval <0 Failure. Order not copied. + */ +int odp_schedule_order_copy(odp_event_t src_event, odp_event_t dst_event); + +/* + * Get order sustain attribute + * + * Retrieve the order sustain attribute associated with an event. An event + * normally consumes its order when enqueued. An event that sustains order + * does not consume its order when enqueued, permitting multiple events to + * be sequenced in the same relative order. + * + * @param ev Event + * + * @retval 0 Event will not sustain order when queued + * @retval 1 Event will sustain order when queued + * @retval <0 Event has no associated ordering + */ +int odp_schedule_order_sustain(odp_event_t ev); + +/* + * Set order sustain attribute + * + * Set the order sustain attribute associated with an event. An event + * normally consumes its order when enqueued. An event that sustains order + * does not consume its order when enqueued, permitting multiple events to + * be sequenced in the same relative order. + * + * @param ev Event + * @param sustain Value to be set (0 or 1) + * + * @retval 0 Success + * @retval <0 Failure. Event not ordered or invalid sustain value specified. + */ +int odp_schedule_order_sustain_set(odp_event_t ev, odp_bool_t sustain); + +/** * Prefetch events for next schedule call * * Hint the scheduler that application is about to finish processing the current