From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-CO1-obe.outbound.protection.outlook.com (mail-co1nam03on0081.outbound.protection.outlook.com [104.47.40.81]) by dpdk.org (Postfix) with ESMTP id DC1872C3F for ; Fri, 31 Mar 2017 21:36:06 +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; bh=KAXBMPpHneWDV4Kxs7CLLFHH6rn1GbYj9eCq1/svULs=; b=IJl4SjozgGPqzsq6bx8T/v+jlJobc+kTJyZ3cG85Lu4SM5xWnxKdmkh2k5zZ0LZRmaCclV26cuYg76OhS/FOUPJGalVQIBW1VmVwCxgn3yPVXZvOzPwrHL2zMuJcZFZPTdnewQWJ+fQ9Qr52YPp9dNrTH/6F6jG5hVB11xBU1sQ= Authentication-Results: dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=none action=none header.from=caviumnetworks.com; Received: from localhost.localdomain (14.140.2.178) by BY1PR0701MB1723.namprd07.prod.outlook.com (10.162.111.142) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.991.14; Fri, 31 Mar 2017 19:36:02 +0000 From: Jerin Jacob To: dev@dpdk.org Cc: thomas.monjalon@6wind.com, bruce.richardson@intel.com, harry.van.haaren@intel.com, hemant.agrawal@nxp.com, gage.eads@intel.com, nipun.gupta@nxp.com, santosh.shukla@caviumnetworks.com, Jerin Jacob Date: Sat, 1 Apr 2017 01:04:34 +0530 Message-Id: <1490988905-12584-8-git-send-email-jerin.jacob@caviumnetworks.com> X-Mailer: git-send-email 2.5.5 In-Reply-To: <1490988905-12584-1-git-send-email-jerin.jacob@caviumnetworks.com> References: <1488562101-6658-1-git-send-email-jerin.jacob@caviumnetworks.com> <1490988905-12584-1-git-send-email-jerin.jacob@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.140.2.178] X-ClientProxiedBy: MAXPR01CA0058.INDPRD01.PROD.OUTLOOK.COM (10.164.146.158) To BY1PR0701MB1723.namprd07.prod.outlook.com (10.162.111.142) X-MS-Office365-Filtering-Correlation-Id: 4e25ea65-eacb-403f-8efb-08d4786d2c38 X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(22001)(201703131423075)(201703031133081); SRVR:BY1PR0701MB1723; X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1723; 3:k75nypRIzRFDeJeW5tb0vXcPQe2VBYidOuNZzW3bzy1lYjhKp/6TOHNAv9Bh1AsWUnoTdrVzwnQ5C97AWSLr5jXbHm+0mQlKgTg+eFb5jiUWe8SxOKg+svNB2cbUc4Cwcr0CZ5+RvWX032+eLUb2q6zLtIkoO1EEIEZQ+3vpsEflFXK2ga6GOpBUe0NkzRYqI+LDwPnKntdDKEcReEbAOnkgDLQ93zemMTBKkvCBmRxHHBTRIPeDMKYEC7tMJWdVY3zM+Js+zh4GFW3TDrjD/bmuqHcRNIsnobzfVvDDQWtfC7l6dC29Htk2ZQkvmI+6uQAOdPwYJ2U2hbnTbT78Vw==; 25:LHaxVvI0jzDs8FaxMA2Ndb84Og5jx/bktsr0WtZlOXZVOhmynRCeDBhb+v+j83yyXhoBkw2y7SdAXRbLbKwsbo2cxyV6lT+UHJWx8h2DFW+2+/kHJyQkIW+ziQfUlNnGFi5iAQv/hK7BNjeeLEf0hiZCWqoysbvQfHghsIVssKz+KOWiZB9zUur497imG3R0aieOlAIm242dwxaj4/J3nEP5pCcgDlPHH55k5vY8WXSGZYRcsc+I1kD1KZ2SR+fZoLnEC1LotmvcNxEE4JpiNc6AGAx2MfnzdYU+c//lk+tD8bYI+aOmOieu7v2i5z5QcDWv5z+c3wfKfIoI9HpLP7ZGzitgcnS7BFo2ieQA93TDO340JITm9YSWPEBwjLF3YLtRuZcOSVdkwR0Ej1vVpbOh/bGG1LOKPcOuvPxdHwaOlHFZe1OGstQXYcCzux4IUA+1IlysqIVLll/thEW2yA== X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1723; 31:0G1/r+E+pMTUGdLrmglAC92j9kiybFhQQm+kNqxoPW21s940Vq33B9veE30IubRAB4W505A5JS+bjnaYqU2yXxz+AtR/8w/Z1A9CuUIdwh2Yb1Z4UtUC+uJBGivK9DFBYqWpCRwAhvomQIDh/fgbV1lBLpjZzH6PCdKGvz5Au7Dad199cYpMnvWi27qef6Zd2MD2HwH9th28L6RiqbPRP0uHtvfX6SaqCawhefLNDEoAMXUytTyS11TIPNesH1Yk; 20:UWu8FYdbaXQ5vaWXF10B071wpYWqbA8P7y/FgZPO4hReHU/DnfCezCq5Yyf/nNpo4vqwmhr1jVIsFwBlxKlb4n8DLgp8cAZzxovOyts+txTBZg2O5nRssIVQE119c8Ergyy2+RjtXJyDeme6EPV/Na/5k1dRXwP86Np68215NT9UTr8xQsInQypPw40OIAGrEy9p4oZHDaQWaOKyUlJsQBndNiOGh1SGDCkwJtPmpAjBCvpSzeJGLLSdWYCOIFD2OVeasIZl45Z9O1F3dfq8q7DTqSxS78GkjLe3O6eT5vpJ2XXMdi4ETYl8+CBYgmDY2JSBnOlRyoVLhPst7H6EuVZa0CklpWCvkEDiDi2vsqF+EVW2PPBUj2Q7r9pkcAz8FuJ/V43DMC9l2BeYCyGlEV69st1oELL5mb6f2wMISCi/MjWu4KihMQTl4moT45ZUivB4qYju4hKuvMGG3i7IZt/Fop4WPWzWwVVSROuRRZfmT48xdDy1sTMIbhKGHSURZnXD0+SXAz0hTK4vpTFc4AQQMuuZMFFWT98BxEUMUQso9UwDnlu9Cm2V6IiRA7Gv7o3HpPFtfyi+zWoMblg8ueKQGVuGbeYsP8WZwlnf6xQ= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(228905959029699); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040450)(601004)(2401047)(8121501046)(5005006)(10201501046)(93006095)(3002001)(6041248)(20161123555025)(20161123562025)(201703131423075)(201702281528075)(201703061421075)(20161123560025)(20161123564025)(6072148); SRVR:BY1PR0701MB1723; BCL:0; PCL:0; RULEID:; SRVR:BY1PR0701MB1723; X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1723; 4:UE9W+Bs4fLEVFoNOin02xynTj/etG5Uzb3Lp4TVsI/+P1Ow0+lapa95HW9EKyuSI/uO0GFFO/Hc62ZxmeBSLvRyEqfHCnWO3gb7/cEtBDLBOqkS191fkiS9d8PUkAOgIMie/fsWXD+1Bjz3OG8O1hbJ5BLJz9v5dvOzflZSSmKtMCIakSq+o8H09MkhxyFqm8OyTX3HPIG1xfolFPRJQN1i/9dKD+qOE6FvMD9LLYRAJhoqsmgBPqYzP0scSb57siUgP51jrOOym4hMOVf5L8yY4r/fsj45T/TzEM3UuR5N3GzEpPnkxE4OyBkU0CFeqBh5nje6a7N4NNXT/lUpay+HSD2IDYllaT9dgtQ1Q6/uCkfwYam1iZo1binDkoppPKogk0eLchrQRrx0kUiNr+90tkiB+v1bGWQMTEHRoVPaI5golle7C2Z3P2XrOtQUr8/GQFbJ1RbKUhQaY14YpmCbTNsWuIw8aa/oDXXTiOJAjUWbxBKb1k2n0/2NZ8RmA0LB8OV3G+sRRNZ5cc3M9NoTRUZlIC83USaWbsp7CdYiGdtpLZd3mvMFntGifwaJDP6vJsoW1hh84+fPiSSny/VxOWH6GMHYHFaeoiVBWrDvMzpMhb32SP1STNH9MqI8Wt7j7DOpVEZsmrbG8pANkFUCVlN2aVKsz68mN2KCFV3amFHJ7x84sU2papVegctsG+UKQmS4Sz/0DW5vH5Va/zzg6q0CHOC7loQ6+fZMka5tJ2wnwhYoeBI4W3grOaY+O X-Forefront-PRVS: 02638D901B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(4630300001)(6069001)(6009001)(39450400003)(39410400002)(39400400002)(39850400002)(39840400002)(38730400002)(8676002)(107886003)(110136004)(50466002)(189998001)(305945005)(6506006)(36756003)(50226002)(25786009)(48376002)(6666003)(8656002)(6486002)(7736002)(2950100002)(5660300001)(53936002)(81156014)(81166006)(3846002)(42882006)(6916009)(6116002)(6512007)(42186005)(33646002)(2361001)(2351001)(76176999)(50986999)(5003940100001)(47776003)(2906002)(5009440100003)(4326008)(66066001)(110426004); DIR:OUT; SFP:1101; SCL:1; SRVR:BY1PR0701MB1723; H:localhost.localdomain; FPR:; SPF:None; MLV:nov; PTR:InfoNoRecords; LANG:en; X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BY1PR0701MB1723; 23:1t/GVUjxCEv0SGnVOwHNP1DrBLRpSZT61mZbeu4?= =?us-ascii?Q?73TFnTtS0SNV1YGlIntlXQsL0IP3HJk4FOPisXNk9YV+YfFbfosyZQz10kI3?= =?us-ascii?Q?9u2v3z7+Z+Zq5pBwthSVbgs1Gbgs1AdHPVhQjp2kkJBdcc71+JWkTx+Ujt+E?= =?us-ascii?Q?myrw4x8oFmVauM2qsVflq3B9r9DGZH+YjWxtQY3uhNYKR2rv7GdoL/xHsfVu?= =?us-ascii?Q?7j2aU9datFnlmSjMBx4o9KeCpNLAj1ZxBvRN4kdCWPotUXksWqoYLzqw8rI4?= =?us-ascii?Q?ixtoYX/RJNjmWdleghEt2cfik+FrkAocvOCHmRwisskKe5hScVXJZHekdnV9?= =?us-ascii?Q?faHVcG17LfkynL5JlrtAaeG85nciBpauIOym4nqtuSmpr3frUxnNMSWuai4F?= =?us-ascii?Q?Hcbl1p4PiiiGALtTK0KORht6YJ7zfYtA5JnSv+NvCoHQAmXtyNpWdYQooYmF?= =?us-ascii?Q?sWcx4ify1olN1l5Tk55QdD0D+oeyXASPFy8gVwETrN+JnepESBnyYkPX3pW0?= =?us-ascii?Q?N2jynLhI6p4dKEiqZp3yAP4TuyYtlNyP0MCa9L22Ly8SyPBCr+sVGSuG7OLs?= =?us-ascii?Q?94Z9P6FMK5J8zkXpf9NM0pR2a+Mios0hOnTdqztduceNSm85pn/cWZfnrMSj?= =?us-ascii?Q?tNUNjmf9tl376xzhdmTjh+QcO2xL30H3nohCWkkytfNx1Y1cOl254xvpEJFU?= =?us-ascii?Q?s7eoQW0IF/EaRrgY0hsMT1b0ZHP6TIdtZMtbHpzoZ1fD5OX99khrcuKljeuv?= =?us-ascii?Q?LDpSOxyPvXJHWgieB0T+reFX8rD19IcVYEG4S26DFVn/AM3P088QjqgBZ0jo?= =?us-ascii?Q?DIt2LIWwTNqb6j5b7AE6ICnElmaiZ3h+x8Xd1aFxX6CHXPzqSxD0NJIVQKt5?= =?us-ascii?Q?mg0f9h0Xo8GeSk97WK3XPYvVpFAln+KSB+5YydGPoU2xOSn3aX5CBq/9IjC1?= =?us-ascii?Q?riquLT47Zb055reMJ1tOzUGu17ulTyRyiU+OBRYikmYPg7PVTo/gkSBxSZJ9?= =?us-ascii?Q?rORgLIIwabYn343A0FPixljHXHZQLFE/GaqhqCGmJuSp5K0p9qSHt3oO1Oxi?= =?us-ascii?Q?rdfsGqgN1P1nYDY099vHbKuFJHzrVlLg4e/LFTxOf3ViJrEjB2Mwd52dE293?= =?us-ascii?Q?MlnG+6Z3nm6lU7FwbWY46hYZ9/PBw6x1ySaJy7KcU50VahJYzkwd1/topmmg?= =?us-ascii?Q?jk5LoXejvtToU/yk=3D?= X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1723; 6:ME8FBs1g9C+J4IRwd59jOeU7iJjTym+vUEsrrBYKLIehW5L56XWCwht8C96cKPqd9SqMC1FtZ0ntRw9INtdXax1esfxR3QJppgmVFg0FfD3OVrSAMwHE60wEcXdTTpDiOzBe8lkm90hOqYZGwxzZPgevP2tsrTFEHRctLDpViRwB90wuPxCQQQRA8Tnpzn6WAXpAX14HYyqt6k3K4jKdd20tQAYbrIOJpg5FutCeVjZegg//G9Wk3atI9FmmppGTt4d3nrx4hiGh2PYnvCyqVYfaDBlK3QuOhtNRLObUPKUaLMt8GHadiPLWH095sUL6lSCCuYXqr+RLsj+YYgMYzrApm5PwLE7FOGuEzxHD5G77ljpEox1RlLAqfhrDE2f/hqD6dMZ67EVohImsJJwMWg==; 5:wMXeZ6AQt+dbJRnl/PgvDQkKL13wgpbgjuiZw0wTLZDEO4mdAsuFiJeq+zWtTKBIe6nnmvmUZJI2TMPXWsqPA5HhhX1QQlry3nARmc/SZldnrpqefBabs6C3SwsXo8fEGTWaqwUB/dlPpIoVvb0BU0acE5qOVYaB3tq1Cs3sCRw=; 24:ITX3bm9nSjeQq3d8xUNoEF9XyjT7zOlv2pJalYAMffsVgFBun0Jt/JTC5i0Ukeu60P/ojs1RmDUEKb/BC6JlESC0zT74QE/kaq3KhltOJdw= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BY1PR0701MB1723; 7:yn2ufScdtYe1Zspzoo0pwiUES44tldKjRQc6k1IYtzAckXTD+pnAM3chG78qHvcM3m6hVPWI+BZux1WlqJv/jn/Zx7OdBH749B1LsQ2C3F9rpkK4+Qtf8hbPeHIrPlFeWdZTBFs0wZEiYrdxw/J5lTldoI9e9YJYwecTJEc/HJ/iLtQx9bqRDdGe7yzy6yfxAhBXpQxTLHrhyP/PO5erqoQqbg0TFIU37C5GHrpsRe6qzuxgBY9mifEXiWPWIHvTmHlEhwNOL/Kr1qduBD3A9UrXqOccjfyo/84Seim8Eu+B5My8XrcNhCz78r5vcJYFCL8vLPRNjKl22TDACnhEnQ== X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Mar 2017 19:36:02.1284 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR0701MB1723 Subject: [dpdk-dev] [PATCH v2 07/38] event/octeontx: add device capabilities function 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: Fri, 31 Mar 2017 19:36:07 -0000 Add the info_get function to return details on the queues, flow, prioritization capabilities, etc. which this device has. Signed-off-by: Jerin Jacob Signed-off-by: Santosh Shukla Acked-by: Gage Eads --- v2: - add newly introduced RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES in info_get --- drivers/event/octeontx/ssovf_evdev.c | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/drivers/event/octeontx/ssovf_evdev.c b/drivers/event/octeontx/ssovf_evdev.c index b349adc..9608d9c 100644 --- a/drivers/event/octeontx/ssovf_evdev.c +++ b/drivers/event/octeontx/ssovf_evdev.c @@ -65,6 +65,32 @@ ssovf_mbox_dev_info(struct ssovf_mbox_dev_info *info) return octeontx_ssovf_mbox_send(&hdr, NULL, 0, info, len); } +static void +ssovf_info_get(struct rte_eventdev *dev, struct rte_event_dev_info *dev_info) +{ + struct ssovf_evdev *edev = ssovf_pmd_priv(dev); + + dev_info->min_dequeue_timeout_ns = edev->min_deq_timeout_ns; + dev_info->max_dequeue_timeout_ns = edev->max_deq_timeout_ns; + dev_info->max_event_queues = edev->max_event_queues; + dev_info->max_event_queue_flows = (1ULL << 20); + dev_info->max_event_queue_priority_levels = 8; + dev_info->max_event_priority_levels = 1; + dev_info->max_event_ports = edev->max_event_ports; + dev_info->max_event_port_dequeue_depth = 1; + dev_info->max_event_port_enqueue_depth = 1; + dev_info->max_num_events = edev->max_num_events; + dev_info->event_dev_cap = RTE_EVENT_DEV_CAP_QUEUE_QOS | + RTE_EVENT_DEV_CAP_DISTRIBUTED_SCHED | + RTE_EVENT_DEV_CAP_QUEUE_ALL_TYPES; +} + + +/* Initialize and register event driver with DPDK Application */ +static const struct rte_eventdev_ops ssovf_ops = { + .dev_infos_get = ssovf_info_get, +}; + static int ssovf_vdev_probe(const char *name, const char *params) { @@ -89,7 +115,7 @@ ssovf_vdev_probe(const char *name, const char *params) ssovf_log_err("Failed to create eventdev vdev %s", name); return -ENOMEM; } - eventdev->dev_ops = NULL; + eventdev->dev_ops = &ssovf_ops; /* For secondary processes, the primary has done all the work */ if (rte_eal_process_type() != RTE_PROC_PRIMARY) -- 2.5.5