From patchwork Wed Jul 29 01:56:52 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 51611 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-wi0-f197.google.com (mail-wi0-f197.google.com [209.85.212.197]) by patches.linaro.org (Postfix) with ESMTPS id 9667B214B7 for ; Wed, 29 Jul 2015 01:57:55 +0000 (UTC) Received: by wicmm11 with SMTP id mm11sf1583160wic.3 for ; Tue, 28 Jul 2015 18:57:54 -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=/rYsruXA8Xx9Nl8u1D3zPLnZRQ5JiTsDZf2COkAzd4k=; b=ItHAW13M6kihjQsgiMdiavnwkk3C/euiigiSRS/clWKDSJijryWXzPur/9f7nz9osh e50//kYslXJ4OysodDLsvWLTEbglKuj1J33IWsZ5EGn1pu4ebEGrVTSKXsKfXyjL1Z/h c7RU3TwEgSIGUzeQmkllsMv/o53wKYsInXXckhXQrjZvwQ2RGnv1SBjlLhuPrfTwiN0F mSlUOB37XYtlwFno9ST4Gvd7+hpPgEd7lUxiTzp59KvVHwmcXmoQah3W2iDLA3/nLhKH 81hzUGPJY8t8aNn3te1IYZyzKC2lcO2hcE8+NBVo9b5hzxfn+2wa/WCr7iQ59GS0iTAq CaSw== X-Gm-Message-State: ALoCoQnbxDhDBsBk/whfri7oLRFiFfhBp4w7gjrcnccqk7x9t36I3ygbIVxTP9jCW4lp2dtMfBrN X-Received: by 10.112.42.236 with SMTP id r12mr15004954lbl.2.1438135074891; Tue, 28 Jul 2015 18:57:54 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.36.65 with SMTP id o1ls884728laj.81.gmail; Tue, 28 Jul 2015 18:57:54 -0700 (PDT) X-Received: by 10.112.166.2 with SMTP id zc2mr36028414lbb.29.1438135074489; Tue, 28 Jul 2015 18:57:54 -0700 (PDT) Received: from mail-lb0-f179.google.com (mail-lb0-f179.google.com. [209.85.217.179]) by mx.google.com with ESMTPS id tn10si20110088lbb.38.2015.07.28.18.57.54 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 28 Jul 2015 18:57:54 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.179 as permitted sender) client-ip=209.85.217.179; Received: by lbbyj8 with SMTP id yj8so86305160lbb.0 for ; Tue, 28 Jul 2015 18:57:54 -0700 (PDT) X-Received: by 10.112.55.207 with SMTP id u15mr35825564lbp.88.1438135073956; Tue, 28 Jul 2015 18:57:53 -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 l6csp2461328lba; Tue, 28 Jul 2015 18:57:52 -0700 (PDT) X-Received: by 10.55.26.151 with SMTP id l23mr53293542qkh.10.1438135072522; Tue, 28 Jul 2015 18:57:52 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id n35si28522643qge.91.2015.07.28.18.57.51; Tue, 28 Jul 2015 18:57:52 -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 D034561F52; Wed, 29 Jul 2015 01:57:51 +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 5E41F61F54; Wed, 29 Jul 2015 01:57:14 +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 C31F761F45; Wed, 29 Jul 2015 01:57:04 +0000 (UTC) Received: from mail-oi0-f41.google.com (mail-oi0-f41.google.com [209.85.218.41]) by lists.linaro.org (Postfix) with ESMTPS id BF6F161F41 for ; Wed, 29 Jul 2015 01:57:03 +0000 (UTC) Received: by oigi136 with SMTP id i136so3507886oig.1 for ; Tue, 28 Jul 2015 18:57:03 -0700 (PDT) X-Received: by 10.202.59.10 with SMTP id i10mr33542072oia.33.1438135023350; Tue, 28 Jul 2015 18:57:03 -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 n2sm13555547oia.29.2015.07.28.18.57.02 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 28 Jul 2015 18:57:02 -0700 (PDT) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Tue, 28 Jul 2015 20:56:52 -0500 Message-Id: <1438135016-22225-2-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1438135016-22225-1-git-send-email-bill.fischofer@linaro.org> References: <1438135016-22225-1-git-send-email-bill.fischofer@linaro.org> X-Topics: patch Subject: [lng-odp] [API-NEXT PATCH 1/5] api: schedule: additional scheduler group functions 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.179 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 | 45 +++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/include/odp/api/schedule.h b/include/odp/api/schedule.h index 36e52cd..d679510 100644 --- a/include/odp/api/schedule.h +++ b/include/odp/api/schedule.h @@ -220,6 +220,51 @@ odp_schedule_group_t odp_schedule_group_create(const char *name, int odp_schedule_group_destroy(odp_schedule_group_t group); /** + * Look up a schedule group by name + * + * Returns the handle of a schedule group from its name + * + * @param name Name of schedule group + * + * @return Handle of schedule group for specified name + * @retval ODP_SCHEDULE_GROUP_INVALID No matching schedule group found + */ +odp_schedule_group_t odp_schedule_group_lookup(const char *name); + +/** + * Join a schedule group + * + * Joins a threadmask to an existing schedule group + * + * @param group Schdule group handle + * @param mask Thread mask + * + * @retval 0 on success + * @retval <0 on failure + */ +int odp_schedule_group_join(odp_schedule_group_t group, + const odp_thrmask_t *mask); + +/** + * Leave a schedule group + * + * Removes a threadmask from an existing schedule group + * + * @param group Schdule group handle + * @param mask Thread mask + * + * @retval 0 on success + * @retval <0 on failure + * + * @note Leaving a schedule group means threads in the specified mask will no + * longer receive events from queues belonging to the specified schedule + * group. This effect is not instantaneous, however, and events that have been + * prestaged may still be presented to the masked threads. + */ +int odp_schedule_group_leave(odp_schedule_group_t group, + const odp_thrmask_t *mask); + +/** * Initialize ordered context lock * * Initialize an ordered queue context lock. The lock can be associated only