From patchwork Fri Mar 31 11:33:18 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Petri Savolainen X-Patchwork-Id: 96377 Delivered-To: patch@linaro.org Received: by 10.140.89.233 with SMTP id v96csp681686qgd; Fri, 31 Mar 2017 04:33:54 -0700 (PDT) X-Received: by 10.237.48.66 with SMTP id 60mr2503426qte.25.1490960034223; Fri, 31 Mar 2017 04:33:54 -0700 (PDT) Return-Path: Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id o36si4334336qtb.332.2017.03.31.04.33.53; Fri, 31 Mar 2017 04:33:54 -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 sp=NONE dis=NONE) header.from=linaro.org Received: by lists.linaro.org (Postfix, from userid 109) id 84F186357C; Fri, 31 Mar 2017 11:33:53 +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=BAD_ENC_HEADER,BAYES_00, RCVD_IN_DNSWL_NONE, RCVD_IN_MSPIKE_H4, RCVD_IN_MSPIKE_WL, SPF_HELO_PASS, 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 7E34C60D00; Fri, 31 Mar 2017 11:33:49 +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 971DD60D00; Fri, 31 Mar 2017 11:33:46 +0000 (UTC) Received: from EUR01-VE1-obe.outbound.protection.outlook.com (mail-ve1eur01on0118.outbound.protection.outlook.com [104.47.1.118]) by lists.linaro.org (Postfix) with ESMTPS id 26EFB60CBD for ; Fri, 31 Mar 2017 11:33:45 +0000 (UTC) Received: from HE1PR0701CA0088.eurprd07.prod.outlook.com (2603:10a6:3:64::32) by AM4PR07MB3361.eurprd07.prod.outlook.com (2603:10a6:205:a::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1019.8; Fri, 31 Mar 2017 11:33:43 +0000 Received: from VE1EUR03FT052.eop-EUR03.prod.protection.outlook.com (2a01:111:f400:7e09::207) by HE1PR0701CA0088.outlook.office365.com (2603:10a6:3:64::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1019.8 via Frontend Transport; Fri, 31 Mar 2017 11:33:43 +0000 Received-SPF: SoftFail (protection.outlook.com: domain of transitioning linaro.org discourages use of 131.228.2.240 as permitted sender) Received: from mailrelay.int.nokia.com (131.228.2.240) by VE1EUR03FT052.mail.protection.outlook.com (10.152.19.173) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P384) id 15.1.1005.5 via Frontend Transport; Fri, 31 Mar 2017 11:33:43 +0000 Received: from fihe3nok0734.emea.nsn-net.net (localhost [127.0.0.1]) by fihe3nok0734.emea.nsn-net.net (8.14.9/8.14.5) with ESMTP id v2VBXJ4Z018038 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 31 Mar 2017 14:33:19 +0300 Received: from 10.144.19.15 ([10.144.104.219]) by fihe3nok0734.emea.nsn-net.net (8.14.9/8.14.5) with ESMTP id v2VBXJq3018030 (version=TLSv1/SSLv3 cipher=AES128-SHA256 bits=128 verify=NOT) for ; Fri, 31 Mar 2017 14:33:19 +0300 X-HPESVCS-Source-Ip: 10.144.104.219 From: Petri Savolainen To: Date: Fri, 31 Mar 2017 14:33:18 +0300 Message-ID: <1490959999-22930-1-git-send-email-petri.savolainen@linaro.org> X-Mailer: git-send-email 2.8.1 X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:131.228.2.240; IPV:CAL; CTRY:FI; EFV:NLI; SFV:NSPM; SFS:(10019020)(6009001)(39410400002)(39850400002)(39400400002)(39840400002)(39450400003)(39860400002)(2980300002)(189002)(199003)(9170700003)(5660300001)(6916009)(189998001)(2351001)(106466001)(356003)(105596002)(305945005)(33646002)(2906002)(86362001)(81166006)(77096006)(8676002)(50226002)(8936002)(110136004)(47776003)(22756006)(5003940100001)(53936002)(38730400002)(48376002)(36756003)(50986999)(217873001); DIR:OUT; SFP:1102; SCL:1; SRVR:AM4PR07MB3361; H:mailrelay.int.nokia.com; FPR:; SPF:SoftFail; MLV:sfv; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; VE1EUR03FT052; 1:28toavBnbQ7dDYqIy3RHhYz+TdicHOMUNwfp3+SoIQbH5V02i8NK3WUcHZu7mX5IKc6pkvougCaWNF8mX9bTFf7LvTatOe0UhJqEmVkxQTmgaM089PTEKb+/5UEaosgoJAzED0ytSLhew9zOCPoWaJWszt5Mab/0PkAICJRRN6h6WiydZHNWEl/udOnD8mOQf7iKs4xhIw1lJ2FE4Sb8lDboUhZU/hzAE3jEjxxnqXy2fdvfIFVv2WcMQ1RG77ZkD6uEdp/rO9hMp7E976WYGWUrYGNh5fTHlvhdnTLgkNxgortX2seZqjZMZ1ZV9kSbMDXHbiDZ2PY5l9bjtX1QOVEOQ06xATKPMYTGa8O9NZJUk4ovKUS8uDLgN8p7o8UmuImtNYW4HX1vBGaxb5+JYBWlmAZrZDbGgobjWB7EoDBglz1WLh7+2ATIMTv5id+LWjdN1Zy/TvPEDtxhPjRja57rHdQ2W2rXz8HbLXyTeOlMf6R46QjIRa9TNgj+eYe9AjhbC4tLfY8kadU8uyUARg== MIME-Version: 1.0 X-MS-Office365-Filtering-Correlation-Id: c27b636e-5376-4479-70ad-08d47829c952 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(2017030254075)(2017030256075)(201703131423075)(201703031133081); SRVR:AM4PR07MB3361; X-Microsoft-Exchange-Diagnostics: 1; AM4PR07MB3361; 3:ihmgjFN9ce1QgtzF0F+xuq3iteg3EDptezgz5PbVF2MqmUeSQ+Gf1qHVpxzFLg8giXCpm1YKg3Iir3fbiQVejiXg58uwipZQ303tYRWG8xelmyN2W3BY8fAT3kTGEZnUEBkrSLtwGI9+2KZp0YwGnjB+6kEX/poNpbkCiqHaGlJRCFa1+n7LbE8WNa/0GNRSX245FXeJH3wGfKC8xaMlTkegRLTQepqW2fdVblmU5In6m1GeTu7yVMTAXEtgE+/UvM+WTVLH4HkXZisS5LPI+DxWLc6868eoYGs2tFkhxdkMnvNa1EnZ3/oPhv+beE3VLZ30e3j4umIYWCUJBe84+QbDgMOuMyjcqhaxm5UedQSC8TjuVk23L6TEwaiSlslIoQFw7ZXISynWCjGMeGbiGMfHVQfDnDcLtdLuszY9CpORFSu1GxzAkDRI2fCxMd4gKebov8XeBBwmMIMHf08QfOr8d14eSMerIRCUZEvg381XRFnPgIdeA9dws0AXY/MI X-Microsoft-Exchange-Diagnostics: 1; AM4PR07MB3361; 25:aDeWT6UGctsDEJXWVtdhZK9Y/L1uRztW0Wlw9AezG8axKEnNQQ7+0GrD7lUVWkq1UAg47EstPVDYLVSfnaNpEoaGbPiU9ErYmjY2OvfvzDBvUcF9RQA83UjINjXr9GjfnLXS/dadRVTtw5WjuRj3mm/db45LXRFF27fbXyyaExft5cCYY2N1EtBJD5OfSNkDeDehFhabd0c4GkH/beRSw8FT3sC9icd6dBeZ4f3UBkBs6413uB37+uNm9H5R7V+BbGlH/PslqtQEZ7V1kRFBrmj0UwLYNNEs7XGy3jQKzrEdo0ROD/v/d8Kg/X1piS/KFghVUsg18fmv0pyoKGz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A9RwkiHO+eoqkTNfo= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(13021025)(13013025)(8121501046)(13023025)(5005006)(3002001)(10201501046)(93006095)(93003095)(6055026)(6041248)(20161123564025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(20161123560025)(20161123555025)(6072148); SRVR:AM4PR07MB3361; BCL:0; PCL:0; RULEID:; SRVR:AM4PR07MB3361; X-Microsoft-Exchange-Diagnostics: 1; AM4PR07MB3361; 4:tZE5wWvl9+FAw8F+0TKl5Q9yN6tkZrKqfvNzQHMzQaC+ZNCPopt0HpTfY1DieixftlxX8oUJjLB+W18+/feCRcPXkhwJ53dc14S//Uu5wSoYckATlfYa1MVv0gYEBBBAgIBmzXIujoUgE8ZfV7qEj+wa/AexiPv2Xech1jwclPhx+/fvQChoXUlhYZOls7IV4rI/j715/YnpIyao6Q4TmH232+nR4HCMKFYjujIG63ISRL5ONpVW4fLyzPe7OA+Q26RXd9DBOugPKlc2lBJOhN7LMEDjtR15x1pgCZxi1JSBMNnye9bPqKQXi/tUG6sWW/KY0WfgF1fls5EZt6B/APYAGpn5piJ5KkoW6Cn5u4ymWFLwMGo2Rs0Mts+hs53oxWLTn2oMKPvmUF1QQY/qrG39Gto+QVGHKnroLUfOfxFEL730RNmPEiFsTef1bdUPKUN8RewEauqcLtwJYrK4p5jXWYWdE2//zh9ULvoqE4miv2yB4Z/XKyzBYU8YJw98gHaCtAWffgHuAuSs1G6GVWOBd9S1VEpL+QjyFCEhk6OLYe26EpCh6dGmRdhqthFM6GlfzOVrFMlJSk2FY5tNK5KCMM2VYz8F6Duakw/v1LKeuS5V0fmuRm7eXH/ONNGiVS63keInopHMejEP43Svmxq+PcKQdjycOKuWvBp+Z8q7QMShurI9YRstwpDXxKQH8atQ451nmRGnaBUAdjLknjRQ+18kRjnR5QQUQhOXqjQjUcNp2/d2F3HA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6W/jzzijnac3ifdpda34HMnI8XRKTbi63vb56rS6ThJ9RK4C9TxKRKutKUknBU1ju3ezJNOjKGmFbuPVDNEBx9X8tx3E7Q1FDRyH29pUtekJu+vYY1pSOHUg== X-OriginatorOrg: nokia.onmicrosoft.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Mar 2017 11:33:43.0822 (UTC) X-MS-Exchange-CrossTenant-Id: 5d471751-9675-428d-917b-70f44f9630b0 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5d471751-9675-428d-917b-70f44f9630b0; Ip=[131.228.2.240]; Helo=[mailrelay.int.nokia.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: AM4PR07MB3361 Subject: [lng-odp] [API-NEXT PATCH 1/2] api: queue: added queue size param 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" Added capability information about maximum number of queues and queue sizes. Both are defined per queue type, since plain and scheduled queues may have different implementations (e.g. one uses HW while the other is SW). Added queue size parameter, which specifies how large storage size application requires in minimum. Signed-off-by: Petri Savolainen --- include/odp/api/spec/queue.h | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) -- 2.8.1 diff --git a/include/odp/api/spec/queue.h b/include/odp/api/spec/queue.h index 7972fea..fea72ca 100644 --- a/include/odp/api/spec/queue.h +++ b/include/odp/api/spec/queue.h @@ -100,7 +100,7 @@ typedef enum odp_queue_op_mode_t { * Queue capabilities */ typedef struct odp_queue_capability_t { - /** Maximum number of event queues */ + /** Maximum number of event queues of any type */ uint32_t max_queues; /** Maximum number of ordered locks per queue */ @@ -112,6 +112,26 @@ typedef struct odp_queue_capability_t { /** Number of scheduling priorities */ unsigned sched_prios; + struct { + /** Maximum number of a plain queues. */ + uint32_t max_num; + + /** Maximum number of events a plain queue can store + * simultaneously. The value of zero means unlimited. */ + uint32_t max_size; + + } plain; + + struct { + /** Maximum number of a scheduled queues. */ + uint32_t max_num; + + /** Maximum number of events a scheduled queue can store + * simultaneously. The value of zero means unlimited. */ + uint32_t max_size; + + } sched; + } odp_queue_capability_t; /** @@ -165,6 +185,15 @@ typedef struct odp_queue_param_t { * The implementation may use this value as a hint for the number of * context data bytes to prefetch. Default value is zero (no hint). */ uint32_t context_len; + + /** Queue size + * + * The queue must be able to store in minimum this many events + * simultaneously. The value must not exceed 'max_size' queue + * capability. The value of zero means implementation specific + * default size. */ + uint32_t size; + } odp_queue_param_t; /**