From patchwork Fri Jul 24 10:51:36 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Balasubramanian Manoharan X-Patchwork-Id: 51412 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 B57B922D94 for ; Fri, 24 Jul 2015 10:51:58 +0000 (UTC) Received: by wixh2 with SMTP id h2sf5563017wix.0 for ; Fri, 24 Jul 2015 03:51:58 -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: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=hY02N+7Fh6qN/L1d1Ostc0HMtn4oCSGuTTOAhUn6v8k=; b=Hncx49iegJgFmqJH3D6n1uZfID6u5hJZfT6ip67PMDFzwiWrapVpFZKHdczIdX9vph JNivRh7OMlvXhlWsxL5og27jzkb/CF2bxHE/LRP8TzQu77pjxiTPby5LcMalXWIyWSyk Wquy6ogxksRma3zolSw+krX1cDCTKiv6C0lqr6rE/0l9xF1cT3mu9bwHixuaJq40LVBh TEso8KY+bn2cc7sU+o8WxxkJHl9GAnqG1prB1w7ejjt+VrDRs3OddSlapHUvFfgh2NMM U1sjBLa2N+kDTGom4eWEkge4NtlocQDVlhnOhghrDErqRjpzsWEpQxN8Xts9LkbPFbDu PyYg== X-Gm-Message-State: ALoCoQlft8QedDwYASWhIOiFoYvPomJtk2jpMAZmQ1onoK71wTrRpUlz0LUnESffXXIQT4UpYyYM X-Received: by 10.180.97.9 with SMTP id dw9mr1426648wib.2.1437735118082; Fri, 24 Jul 2015 03:51:58 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.25.134 with SMTP id c6ls375581lag.54.gmail; Fri, 24 Jul 2015 03:51:57 -0700 (PDT) X-Received: by 10.112.151.178 with SMTP id ur18mr13163251lbb.59.1437735117917; Fri, 24 Jul 2015 03:51:57 -0700 (PDT) Received: from mail-lb0-f181.google.com (mail-lb0-f181.google.com. [209.85.217.181]) by mx.google.com with ESMTPS id qa7si7202186lbc.18.2015.07.24.03.51.57 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 24 Jul 2015 03:51:57 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.181 as permitted sender) client-ip=209.85.217.181; Received: by lbbqi7 with SMTP id qi7so12610412lbb.3 for ; Fri, 24 Jul 2015 03:51:57 -0700 (PDT) X-Received: by 10.112.199.133 with SMTP id jk5mr13324303lbc.32.1437735117816; Fri, 24 Jul 2015 03:51:57 -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 l6csp1094071lba; Fri, 24 Jul 2015 03:51:56 -0700 (PDT) X-Received: by 10.140.217.149 with SMTP id n143mr20420245qhb.9.1437735116509; Fri, 24 Jul 2015 03:51:56 -0700 (PDT) Received: from lists.linaro.org (lists.linaro.org. [54.225.227.206]) by mx.google.com with ESMTP id b102si9547909qga.35.2015.07.24.03.51.55; Fri, 24 Jul 2015 03:51:56 -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 7100161B32; Fri, 24 Jul 2015 10:51:55 +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_H2, 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 81BC261B18; Fri, 24 Jul 2015 10:51:51 +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 D49A061B1C; Fri, 24 Jul 2015 10:51:49 +0000 (UTC) Received: from mail-pa0-f44.google.com (mail-pa0-f44.google.com [209.85.220.44]) by lists.linaro.org (Postfix) with ESMTPS id E227A61B14 for ; Fri, 24 Jul 2015 10:51:48 +0000 (UTC) Received: by padck2 with SMTP id ck2so12829526pad.0 for ; Fri, 24 Jul 2015 03:51:48 -0700 (PDT) X-Received: by 10.70.89.135 with SMTP id bo7mr30063551pdb.65.1437735107589; Fri, 24 Jul 2015 03:51:47 -0700 (PDT) Received: from bala-Vostro-2520.caveonetworks.com ([111.93.218.67]) by smtp.gmail.com with ESMTPSA id q5sm13879840pde.56.2015.07.24.03.51.45 (version=TLSv1.2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 24 Jul 2015 03:51:46 -0700 (PDT) From: Balasubramanian Manoharan To: lng-odp@lists.linaro.org Date: Fri, 24 Jul 2015 16:21:36 +0530 Message-Id: <1437735096-25242-1-git-send-email-bala.manoharan@linaro.org> X-Mailer: git-send-email 1.9.1 Subject: [lng-odp] [RFC/API-NEXT] api: assigning packet pool per class of service 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: bala.manoharan@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.181 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 This API proposal links a packet pool to a CoS and the packets belonging to this CoS will be allocated from this packet pool. This packet pool belonging to the CoS will supersede the packet pool associated with the pktio interface. Signed-off-by: Balasubramanian Manoharan --- include/odp/api/classification.h | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/include/odp/api/classification.h b/include/odp/api/classification.h index f597b26..7a47021 100644 --- a/include/odp/api/classification.h +++ b/include/odp/api/classification.h @@ -358,6 +358,22 @@ int odp_pktio_pmr_match_set_cos(odp_pmr_set_t pmr_set_id, odp_pktio_t src_pktio, odp_cos_t dst_cos); /** +* Assigns a packet buffer pool for a specific Class of service. +* All the packets belonging to the given class of service will +* be allocated from the assigned packet pool. +* +* @param cos_id class-of-service handle +* @param pool_id Packet buffer pool handle +* +* @return 0 on success +* @return <0 on failure +* +* @note The packet pool associated with CoS will supersede +* the packet pool associated with the pktio interface +*/ +int odp_cos_set_pool(odp_cos_t cos_id, odp_pool_t pool_id); + +/** * Get printable value for an odp_cos_t * * @param hdl odp_cos_t handle to be printed