From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM01-SN1-obe.outbound.protection.outlook.com (mail-sn1nam01on0052.outbound.protection.outlook.com [104.47.32.52]) by dpdk.org (Postfix) with ESMTP id D49E37EC7 for ; Tue, 10 Jul 2018 12:57:07 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=CAVIUMNETWORKS.onmicrosoft.com; s=selector1-cavium-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=gcxJvafqN1hAf5YHfQhjtxUbWtMZUPO4HGsa2s/HmZU=; b=QHm3IFuNt52lRlrcQBcn3/tgwpZwc2hjZd5+tWyFGyMLG3TZdQOHIdtomy/mteHyb2eu6oTYtiO2k/ZuE7Y4Ab03Y6J6LdueT1oYQM+w6pEzUcXy5MrlepfsV1TYRlNAiJOe/QfSbOgIGPJ7Z7jgiCY2/2h90ycRSyXq2OIsz+o= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Pavan.Bhagavatula@cavium.com; Received: from ltp-pvn (111.93.218.67) by CY4PR07MB3461.namprd07.prod.outlook.com (2603:10b6:910:75::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.930.19; Tue, 10 Jul 2018 10:57:04 +0000 Date: Tue, 10 Jul 2018 16:26:45 +0530 From: Pavan Nikhilesh To: Nikhil Rao , jerin.jacob@caviumnetworks.com, olivier.matz@6wind.com Cc: dev@dpdk.org Message-ID: <20180710105644.GA6792@ltp-pvn> References: <1530859329-160189-1-git-send-email-nikhil.rao@intel.com> <1530859329-160189-2-git-send-email-nikhil.rao@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1530859329-160189-2-git-send-email-nikhil.rao@intel.com> User-Agent: Mutt/1.10.0 (2018-05-17) X-Originating-IP: [111.93.218.67] X-ClientProxiedBy: BM1PR0101CA0037.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:1a::23) To CY4PR07MB3461.namprd07.prod.outlook.com (2603:10b6:910:75::14) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 4247899b-6479-476f-cda2-08d5e653e071 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989117)(5600053)(711020)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(2017052603328)(7153060)(7193020); SRVR:CY4PR07MB3461; X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3461; 3:I70dn92p0MSM9GW+F8Xbof0EC5B/k/idJlHjcZOgBvuNb/e1LTotuO8tWfW8hr8j4LG42yrCXIVn8FGXlKo2SMlVSdnKDUiH2etz1C52tqO+t+AmlFFBk5qJEKKNke0M1vML0Bc0RI2uhX96CcmKkC8cSjZ9UYudKz6TjGQNHh8eze1H/CzTLT7OTkaF9ZrSuECdZr83dYaqiinLSo2k5eSSkDRTfO5N8PzIyqwhBC2mcrecLyskaU9tW7hImQ+Y; 25:8KWVIVz++KtldkbdG54fNu0/8Qz8CK6buXadhGQ+i1whDCxGzMDjzhQHUR87NTTZK1ywoaVD/OMyM6mbOhR9oSAgT/P2LlKmwY3ElBRvstsx2NMagxgBN/6OUjtEIRYK5INGSM04iQpGWgDoGIxu294b8r8jFETIWFYT1qSafrZedLFog2icYLk5QpYOJuhqdFSeZZllR/RvHxPyPtaPXdxXmjkzM4svu7/EZW3DxEshB93O+g3eMJhg6rcJdM7c0uaLu4ZusZc4ox5zts9r44Jf4owMN2U93kdwF0J7Nf6fMJBJdycdiFeGVVLVDA4RWi4ZiHtfnrpDImNMI1yEUg==; 31:HZD7ZA9wHXfRJ8ZbwpE7+3o4NM3GS5pgeWMx5WMx1Ry+VHT1iynRveGbJ+qpx7HZG3A5Y1Q+4RYvUFAp+TE7jFWKlkNSaDROYrVpX0Qdbc2Kt/8s31WC5d0YSzdHxB5a0kXT7OhU5WnAgkBXMxzxj7azwF69/3ygNH5IqOhgMEhZJATQy2LCj3nMh+uXjehoFRwlVHtHoBmB/wkqImVIHDBYmpnfjIDW7jceGhOaTJM= X-MS-TrafficTypeDiagnostic: CY4PR07MB3461: X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3461; 20:cTkSYK/MEGs7DCuJoQLCGfDQdP+c46a5sQv/0npX693dvjQiNOjUHyoEk48I6m2oaIzJtAL7rO7DRLqyHOBDQVllHOgRwNhQ63v7VaijC2L16CNaar9ohmWzhI8jQutaotpoNYmyzIxUrkZQFNNxfiyvzbApdaVPVS+QqBx6CxFV2LK5VuxhZdzB6paKtB62yMaxZvXwEJHPhz+dxf6Ba0I6Z4QfH2+7Qa/0HidCl/OPG6PbBjJCZoaqjlX/HhHhjSHPdnKsJvvNLCURFw+hskYl/ZlU4DiiLxHdl83oqlfi3srEof1MOYhDX+tfMVueSZ24MDRAS3Uk97uF0MLDA4Dt1XUR/Ml8FEx5XsPdqPJTPxAvXN3YV4Bv4ndX5aFxnZ4AW6KP8d+M/pLo5Lai9AAjx7Ri8/qBkBM5TmUeWhmraLSAi4bcZqYcPyoeRDs9Pxyz23S8t6j8WrFv6dF03DBvAEHzn+kvru3+7RCIACnYFQA4LX/nqmbL+FK4giZ9t+49/tqF1oKJMHj4R0cQxJa5EOAVAMIOoLfvcCcqsBr3g1ImBLR0SQBuTHJ1VDmFQ33qzLA7cyXo5WBQuT4sXgMIimqI7llzd+ddZfcJsxc= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(35073007944872)(228905959029699); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(3002001)(10201501046)(93006095)(3231311)(944501410)(52105095)(149027)(150027)(6041310)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(20161123564045)(20161123562045)(6072148)(201708071742011)(7699016); SRVR:CY4PR07MB3461; BCL:0; PCL:0; RULEID:; SRVR:CY4PR07MB3461; X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3461; 4:G9kV5sK32+g3ySIo9e15TdZnsS3hILPe3EvybZYVyiB8I3Vf7zHc/nVH0Zmi/PMrf/BXAR7rsZMKAq4YKdFxMx9gNLEAPS5Iyfru9Z2F2t4Sg3vxQ0FgUjxjvWjw0IsRBgzGqnOJwfhAhqIXvEDURneyaO9IIdBfiKJrB+sIfk1RvZZ520F7nc7RBSJi9WbaNmSoiID04hdD6LfDD0DFytHz3RM+0SxamYaMgKsj/Me8iWHQqwK4SedFs2cC0G7PjNL/JPZm8wDiAvaJ+XzdzSVLRfe6iDs5uTD+8ACk1xY+/+7+mtic9wPwgCHq39q2GpN07b2ra1fgJKKpN8iPCHTtLilHqPexM8A7VTjSJk4= X-Forefront-PRVS: 0729050452 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(39850400004)(366004)(376002)(396003)(346002)(136003)(199004)(189003)(956004)(5660300001)(478600001)(305945005)(476003)(486006)(4326008)(58126008)(106356001)(72206003)(66066001)(81166006)(97736004)(6246003)(11346002)(2906002)(6496006)(52116002)(76176011)(229853002)(16586007)(33896004)(6116002)(3846002)(55016002)(1076002)(23726003)(316002)(446003)(5009440100003)(25786009)(68736007)(26005)(9686003)(33656002)(386003)(50466002)(53936002)(8676002)(42882007)(7736002)(47776003)(105586002)(33716001)(8936002)(186003)(16526019)(81156014)(14444005)(6666003)(18370500001)(107986001)(42262002); DIR:OUT; SFP:1101; SCL:1; SRVR:CY4PR07MB3461; H:ltp-pvn; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; CY4PR07MB3461; 23:NxUJtTzCHHDKrqimh/sjX3MwXKsWBQwJco1+QWfyj?= =?us-ascii?Q?WEUGbjNpd/9OQAXaElONGNcM5QKimUp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kYxczvtF3Dj0VggqCZ7ROQ+HHHkYmXYvnCtnOyLj4PFdUD8i3TICjy/4m1RhL4jxy9Vz+X0Cz2JSzqFO7GgORPpVZHFnDpgqRIPMyXjuxXlNdGQ98juOgsWNQzF6bDlnHiTntXMGYqCdnFUgvt5/v1G0jeP+Dn42bFCj40l3nrXYAJEybFRAjbPWosxnq2X0ILOmogoA77bfVT3Avzbe8d+FIhEvHG55A09oxgdF9F6sxZmmdxlfSznlhQZYMOmd+BVbIlUdKxzBwE+KVO/qW3VXXuOzY3NKGx49dhT4RdwkjDfnKLLQ45s/h8oYwyXAccfDcs9osEDfvDTeaVTXQzbm5r4HskGWg==; 5:XB94H06PfB8+LrFI+UXGGC50FALW6TbI2NFA/0rKV02Z5j5u6/nc4jBkk6ct/zYAL982a5V7TyVqu5P430v50uvRsOlT0G9nKe4u5iCZdQNEYkhN/o2Fm76B4BL8k2ayakGf6Gbxwdv4FRjalRp1NNG4bPJPPUmsNt4gu++NoMQ=; 24:p8lhHSST6lkt3TfzGbHcnTAUOaMafD3lxkaV9rQtux2arMxdxXuk7Yr6aJ9OCJH8U7CPbDHEnidak4xqispRFtVUWfB0vhMWvNfYGpLhJHM= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CY4PR07MB3461; 7:33XtSTLVL0NllfTDryeeqMRS9TwYGSHAPQh81ALAt0WZC9A3S52j6T+p/0ChnutFdU2vPhV8tXDBoOPwbVU4jk53KzMrCu/Ezp+QVtHpH3qerFHnIz9EMneeZ9CNESxW2ke6zFnN8a/WS2z0upokNJgzfAooosa71MIctG+ZZIIp/yUATdmL53ZVJcpeRc/U1KdMKCd44AD5LT1/1HTn27TUhgGChNJSKUCSVJSjohbwvhRnFERKLSVX85QLI8pE X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 10 Jul 2018 10:57:04.7729 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 4247899b-6479-476f-cda2-08d5e653e071 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CY4PR07MB3461 Subject: Re: [dpdk-dev] [PATCH 2/4] eventdev: add caps API and PMD callbacks for eth Tx adapter X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 10 Jul 2018 10:57:08 -0000 Hi Nikhil, On Fri, Jul 06, 2018 at 12:12:07PM +0530, Nikhil Rao wrote: > The caps API allows the application to query if the transmit > stage is implemented in the eventdev PMD or uses the common > rte_service function. The PMD callbacks support the > eventdev PMD implementation of the adapter. > > Signed-off-by: Nikhil Rao > --- > lib/librte_eventdev/rte_eventdev.h | 30 ++++- > lib/librte_eventdev/rte_eventdev_pmd.h | 193 +++++++++++++++++++++++++++++++++ > lib/librte_eventdev/rte_eventdev.c | 19 ++++ > 3 files changed, 241 insertions(+), 1 deletion(-) > <...> > > diff --git a/lib/librte_eventdev/rte_eventdev.c b/lib/librte_eventdev/rte_eventdev.c > index 801810e..a29fae1 100644 > --- a/lib/librte_eventdev/rte_eventdev.c > +++ b/lib/librte_eventdev/rte_eventdev.c > @@ -175,6 +175,25 @@ > (dev, cdev, caps) : -ENOTSUP; > } > > +int __rte_experimental > +rte_event_eth_tx_adapter_caps_get(uint8_t dev_id, uint32_t *caps) > +{ The caps get API needs to be similar to rx adapter caps get i.e. it needs to have the eth_port_id as a parameter so that the underlying event dev driver can expose INTERNAL PORT capability as not all ethdev drivers have the capability to interact with the eventdevs internal port. rte_event_eth_tx_adapter_caps_get(uint8_t dev_id, uint16_t eth_port_id, uint32_t *caps); > + struct rte_eventdev *dev; > + > + RTE_EVENTDEV_VALID_DEVID_OR_ERR_RET(dev_id, -EINVAL); > + > + dev = &rte_eventdevs[dev_id]; > + > + if (caps == NULL) > + return -EINVAL; > + *caps = 0; > + > + return dev->dev_ops->eth_tx_adapter_caps_get ? > + (*dev->dev_ops->eth_tx_adapter_caps_get)(dev, > + caps) > + : 0; > +} > + > static inline int > rte_event_dev_queue_config(struct rte_eventdev *dev, uint8_t nb_queues) > { > -- > 1.8.3.1 > Thanks, Pavan.