From patchwork Mon Dec 28 17:10:03 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bill Fischofer X-Patchwork-Id: 59029 Delivered-To: patch@linaro.org Received: by 10.112.130.2 with SMTP id oa2csp1821560lbb; Mon, 28 Dec 2015 09:10:48 -0800 (PST) X-Received: by 10.55.23.170 with SMTP id 42mr70637156qkx.64.1451322648395; Mon, 28 Dec 2015 09:10:48 -0800 (PST) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id t37si22069296qgt.88.2015.12.28.09.10.47; Mon, 28 Dec 2015 09:10:48 -0800 (PST) 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; dkim=neutral (body hash did not verify) header.i=@linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id A607D61708; Mon, 28 Dec 2015 17:10:47 +0000 (UTC) Authentication-Results: lists.linaro.org; dkim=fail reason="verification failed; unprotected key" header.d=linaro.org header.i=@linaro.org header.b=bDcxg6EC; dkim-adsp=none (unprotected policy); dkim-atps=neutral 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=-2.5 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_LOW, RCVD_IN_MSPIKE_H3, RCVD_IN_MSPIKE_WL, T_DKIM_INVALID, URIBL_BLOCKED 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 16B1A61709; Mon, 28 Dec 2015 17:10:13 +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 4569761705; Mon, 28 Dec 2015 17:10:11 +0000 (UTC) Received: from mail-ob0-f177.google.com (mail-ob0-f177.google.com [209.85.214.177]) by lists.linaro.org (Postfix) with ESMTPS id 26D1761704 for ; Mon, 28 Dec 2015 17:10:10 +0000 (UTC) Received: by mail-ob0-f177.google.com with SMTP id ba1so144272510obb.3 for ; Mon, 28 Dec 2015 09:10:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=VB7lAOt9XRdH8HSJAPixVXGv+2Tln97PLFMIGL3HWaA=; b=bDcxg6ECl14/hTLsB+jk0nrjVSxE2UF3SXDl8f12y79vJFL/WCNiqjKtuuEtw9pmh3 ok6+HG9OJwSxoPAIhxoJjn8cezzzsduvSuWN6d3YVoQ008ekwalc81TaamoTwNldSZ9c cD30ob1asFjb6LLFOXZ7GKBWbjToCciLUiC4w= 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:in-reply-to :references; bh=VB7lAOt9XRdH8HSJAPixVXGv+2Tln97PLFMIGL3HWaA=; b=bLpxnkRH2n8p49Q1shsq3yFEtsK3iWJTOvl8g3MTY1HSHAwIcYgVXmRBEfFJhPPnG9 M0RBVCywtFcLaJ38VuYtHkMUNReEEDhMpL+jl24rMseMbCFNB3RzuQqNewyBPSAeJcjC niiVQjFXr/jZj+9Yrf+9YecrXPzB4xl6Zm3o+fNe9l/3w6gKIFg+eA/+11Du1QQJJ4I2 D17BgmXQNraghSz2/e+XjSgGyO/IydL9FOoUvKp91jqGd08lbgiBk89sMjLWVQR9DdRi Mmyoc2VgTTaydW06rmlqtEZDBiDBUQ1YKiq55yQMwp/mNwppLIK9LelF5On2RnTr75Tb G5vg== X-Gm-Message-State: ALoCoQk77lshZda6fhiTT0VtQdT91jZF+Z6OtxE9YkHG1zXKTKBVHlB9ZLCBEwQZuBHCSpm7ss1BhVT/asCpO9yVtN4Pk2p0FA== X-Received: by 10.60.95.131 with SMTP id dk3mr34963664oeb.78.1451322609632; Mon, 28 Dec 2015 09:10:09 -0800 (PST) Received: from Ubuntu15.localdomain (cpe-66-68-129-43.austin.res.rr.com. [66.68.129.43]) by smtp.gmail.com with ESMTPSA id k6sm19400651oia.18.2015.12.28.09.10.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 28 Dec 2015 09:10:09 -0800 (PST) From: Bill Fischofer To: lng-odp@lists.linaro.org Date: Mon, 28 Dec 2015 11:10:03 -0600 Message-Id: <1451322603-21299-2-git-send-email-bill.fischofer@linaro.org> X-Mailer: git-send-email 2.5.0 In-Reply-To: <1451322603-21299-1-git-send-email-bill.fischofer@linaro.org> References: <1451322603-21299-1-git-send-email-bill.fischofer@linaro.org> X-Topics: patch Subject: [lng-odp] [API-NEXT PATCHv3 2/2] doc: user-guide: clarify scheduler operation for atomic queues 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: , MIME-Version: 1.0 Errors-To: lng-odp-bounces@lists.linaro.org Sender: "lng-odp" Signed-off-by: Bill Fischofer --- doc/users-guide/users-guide.adoc | 25 ++++++++++++++----------- 1 file changed, 14 insertions(+), 11 deletions(-) diff --git a/doc/users-guide/users-guide.adoc b/doc/users-guide/users-guide.adoc index 7ec7957..80fc53e 100644 --- a/doc/users-guide/users-guide.adoc +++ b/doc/users-guide/users-guide.adoc @@ -623,24 +623,27 @@ might either be empty, of lower priority, or not in a scheduler group matching any of the threads being serviced by the scheduler. === Atomic Queues -Atomic queues simplify event synchronization because only a single event -from a given atomic queue may be processed at a time. Events scheduled from +Atomic queues simplify event synchronization because only a single thread may +process event(s) from a given atomic queue at a time. Events scheduled from atomic queues thus can be processed lock free because the locking is being -done implicitly by the scheduler. +done implicitly by the scheduler. Note that the caller may receive one or +more events from the same atomic queue if *odp_schedule_multi()* is used. In +this case these multiple events all share the same atomic scheduling context. .Atomic Queue Scheduling image::../images/atomic_queue.png[align="center"] -In this example, no matter how many events may be held in an atomic queue, only -one of them can be scheduled at a time. Here two threads process events from -two different atomic queues. Note that there is no synchronization between -different atomic queues, only between events originating from the same atomic -queue. The queue context associated with the atomic queue is held until the -next call to the scheduler or until the application explicitly releases it -via a call to *odp_schedule_release_atomic()*. +In this example, no matter how many events may be held in an atomic queue, +only one calling thread can receive scheduled events from it at a time. Here +two threads process events from two different atomic queues. Note that there +is no synchronization between different atomic queues, only between events +originating from the same atomic queue. The queue context associated with the +atomic queue is held until the next call to the scheduler or until the +application explicitly releases it via a call to +*odp_schedule_release_atomic()*. Note that while atomic queues simplify programming, the serial nature of -atomic queues will impair scaling. +atomic queues may impair scaling. === Ordered Queues Ordered queues provide the best of both worlds by providing the inherent