From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-BY2-obe.outbound.protection.outlook.com (mail-by2nam03on0044.outbound.protection.outlook.com [104.47.42.44]) by dpdk.org (Postfix) with ESMTP id 9665A8CF2 for ; Wed, 23 Aug 2017 16:03:25 +0200 (CEST) Received: from DM5PR03CA0056.namprd03.prod.outlook.com (2603:10b6:4:3b::45) by SN2PR03MB2269.namprd03.prod.outlook.com (2603:10b6:804:d::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1385.9; Wed, 23 Aug 2017 14:03:24 +0000 Received: from BY2FFO11FD019.protection.gbl (2a01:111:f400:7c0c::137) by DM5PR03CA0056.outlook.office365.com (2603:10b6:4:3b::45) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1362.18 via Frontend Transport; Wed, 23 Aug 2017 14:03:23 +0000 Authentication-Results: spf=fail (sender IP is 192.88.168.50) smtp.mailfrom=nxp.com; nxp.com; dkim=none (message not signed) header.d=none;nxp.com; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 192.88.168.50 as permitted sender) receiver=protection.outlook.com; client-ip=192.88.168.50; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (192.88.168.50) by BY2FFO11FD019.mail.protection.outlook.com (10.1.14.107) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.1341.15 via Frontend Transport; Wed, 23 Aug 2017 14:03:23 +0000 Received: from Tophie.ap.freescale.net ([10.232.14.39]) by tx30smr01.am.freescale.net (8.14.3/8.14.0) with ESMTP id v7NE2Q3F004389; Wed, 23 Aug 2017 07:03:21 -0700 From: Shreyansh Jain To: CC: , Date: Wed, 23 Aug 2017 19:42:02 +0530 Message-ID: <20170823141213.25476-30-shreyansh.jain@nxp.com> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20170823141213.25476-1-shreyansh.jain@nxp.com> References: <1499179471-19145-1-git-send-email-shreyansh.jain@nxp.com> <20170823141213.25476-1-shreyansh.jain@nxp.com> X-EOPAttributedMessage: 0 X-Matching-Connectors: 131479706038545714; (91ab9b29-cfa4-454e-5278-08d120cd25b8); () X-Forefront-Antispam-Report: CIP:192.88.168.50; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10009020)(6009001)(336005)(39860400002)(39380400002)(2980300002)(1109001)(1110001)(339900001)(189002)(199003)(6666003)(5660300001)(97736004)(105606002)(8656003)(626005)(68736007)(6916009)(4326008)(2950100002)(36756003)(86362001)(85426001)(2906002)(77096006)(356003)(305945005)(106466001)(53936002)(1076002)(8676002)(81166006)(50986999)(50226002)(76176999)(50466002)(8936002)(81156014)(5003940100001)(48376002)(104016004)(54906002)(2351001)(33646002)(110136004)(498600001)(189998001)(47776003); DIR:OUT; SFP:1101; SCL:1; SRVR:SN2PR03MB2269; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; PTR:InfoDomainNonexistent; MX:1; A:1; LANG:en; X-Microsoft-Exchange-Diagnostics: 1; BY2FFO11FD019; 1:JEI5i/fWYU7ImVp8tnB8WZ8r5a6mbHLIvAvWTc9oFQSTQOX9saxoaFONAvMmG+My0B2RSTZDnYDwS51nCzBo+ibuHGii4AdPE9C+94xXp3ecgFQquUuw1O6ajCXnlsjG MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: f2daa502-49d2-4bed-4bd3-08d4ea2fb80e X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(22001)(300000502095)(300135100095)(300000503095)(300135400095)(2017052603185)(201703131430075)(201703131517081)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:SN2PR03MB2269; X-Microsoft-Exchange-Diagnostics: 1; SN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Ia4WfNKNOyFGpJI9YXB6acUwHTdg/NySf2jeZbR3tl5i5xg7dAf8/Y0QW7yMP3S/37JMUFt3vrFlwpvUw+vbFfNQCP7rhxzU450RXSxCradodL432ocnPWLWV2elGft3HjxYktE/nGZDA75Eo7Gv+YE06NlXRIpAwlGqzJDxw2SzDOQcP0n1+wSzXHq7HGm+HtPpHb0rSkQcs9O77/ismz1cx7yFKzn+Ze+XUMMF9Hs3XGcjM= X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6095135)(601004)(2401047)(13018025)(13016025)(5005006)(8121501046)(10201501046)(3002001)(93006095)(93001095)(100000703101)(100105400095)(6055026)(6096035)(201703131430075)(201703131433075)(201703131441075)(201703131448075)(201703161259150)(20161123561025)(20161123563025)(20161123559100)(20161123556025)(20161123565025)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:SN2PR03MB2269; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(400006)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:SN2PR03MB2269; X-Forefront-PRVS: 040866B734 X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN2PR03MB2269; 23:09e6yMH/YNo9H3JEk8x7MC8NkJBEyREQYIUl1AJ/z?= =?us-ascii?Q?yg3odHaZwqOG4zEEa+HMrw5mpD2AWXRKCNnXrkcPZeO4H9lMr7opl7pb6MXG?= =?us-ascii?Q?bZrt0eAyvLRcciU4TlrljJfj332XpbyhmXfnJuFSQECDe2dAxfFrp740dhjS?= =?us-ascii?Q?IcpFlbDUWIPFQgswgVInUUUjDRTOvHDrVRC0N0SNURiWTeE5Qh6cdH6jRLa2?= =?us-ascii?Q?gQZ1/OKFTBSEhBm8XRTgYPhqdlxn88eGNqI7JHkkp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DD0SO7oqj9LOPIJdb7cPRpFVh?= X-Microsoft-Exchange-Diagnostics: 1; SN2PR03MB2269; 6:/ehoujvEQ1nGXyYlnUCpT6ZHWsfYnGvV4zaXtTnEUBEM9d+TQ9viqVG9fSONNSmB2HZMnHaOg0W9YmmGfNA0ILr7lzIYXUuncipGfakxM60xSaUd2BoVrGAzwrBJB1TC+u9IqCUUsyDFabEzYYfKv+utCOjTE/LkeRk9CSd0u5ubx+LNXJ2ExkS8ORLIxupVo0SyU7EQk61bzkKLq3Kli2qcPcgOI6HNFKb3fj600tKhZik0FYZxXUV3nbiHZS6EXNflBs9ArfFlfaLtLsQKUywrYY/m7863OQucthUxUoM8DUzuiwQKqDGPVijQU8AGSZ4sQ1zaROOltZbKmkUdLg==; 5:AFsjcBn0zV2vW7qqe4wEu+0s8JP4fiXR3v4p1TZl9XTxap8wyl0BYAigW7zR1Lb0+fz0CNjd1tYaDv7ph7gbJApb41wfL14JygmY4ZPrxlX80cFfiWgRBGrd74p3bgSJuSl7neROuhH2X5xIhQ7RDw==; 24:zg6OrFvfYuAqWXDi0vxx8rFpi89KpXruEG27oaL5jOC2C/IJ6dJOCj7KUWJUAl4/ha3CRuh7fFtoqSZmoySobIaO1IZEHBSZ6WH2qjlqCEg=; 7:EcLiNArI3JoNBVinLjnBUweWVSkxLolwQ/edL/CAr72ScPv3tx25+AO9tEoTEcHfUWyQUURWDO7PpCBjGq7nJWx3K08h5Rke7FSlnJ/fMsa9z2wxmYn0d7MQDNmbq00Pquew3rWwRMq72/oTdWRfahGUlVty4wo7G4/Ds6Xv96DFd2Vo14bF0TuGszF+HQ529WLHXLkhEjs3JsuJhKWTUde0OMGPEPMSb2hMy9kZONs= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Aug 2017 14:03:23.6517 (UTC) X-MS-Exchange-CrossTenant-Id: 5afe0b00-7697-4969-b663-5eab37d5f47e X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=5afe0b00-7697-4969-b663-5eab37d5f47e; Ip=[192.88.168.50]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN2PR03MB2269 Subject: [dpdk-dev] [PATCH v3 29/40] net/dpaa: add support for device info and speed capability 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: Wed, 23 Aug 2017 14:03:26 -0000 Signed-off-by: Hemant Agrawal Signed-off-by: Shreyansh Jain --- doc/guides/nics/features/dpaa.ini | 1 + drivers/net/dpaa/dpaa_ethdev.c | 20 ++++++++++++++++++++ 2 files changed, 21 insertions(+) diff --git a/doc/guides/nics/features/dpaa.ini b/doc/guides/nics/features/dpaa.ini index 132f94b..19beada 100644 --- a/doc/guides/nics/features/dpaa.ini +++ b/doc/guides/nics/features/dpaa.ini @@ -4,6 +4,7 @@ ; Refer to default.ini for the full list of available PMD features. ; [Features] +Speed capabilities = P Link status = Y Jumbo frame = Y MTU update = Y diff --git a/drivers/net/dpaa/dpaa_ethdev.c b/drivers/net/dpaa/dpaa_ethdev.c index 75fded2..9751145 100644 --- a/drivers/net/dpaa/dpaa_ethdev.c +++ b/drivers/net/dpaa/dpaa_ethdev.c @@ -142,6 +142,25 @@ static void dpaa_eth_dev_close(struct rte_eth_dev *dev) dpaa_eth_dev_stop(dev); } +static void dpaa_eth_dev_info(struct rte_eth_dev *dev, + struct rte_eth_dev_info *dev_info) +{ + struct dpaa_if *dpaa_intf = dev->data->dev_private; + + PMD_INIT_FUNC_TRACE(); + + dev_info->max_rx_queues = dpaa_intf->nb_rx_queues; + dev_info->max_tx_queues = dpaa_intf->nb_tx_queues; + dev_info->min_rx_bufsize = DPAA_MIN_RX_BUF_SIZE; + dev_info->max_rx_pktlen = DPAA_MAX_RX_PKT_LEN; + dev_info->max_mac_addrs = DPAA_MAX_MAC_FILTER; + dev_info->max_hash_mac_addrs = 0; + dev_info->max_vfs = 0; + dev_info->max_vmdq_pools = ETH_16_POOLS; + dev_info->speed_capa = (ETH_LINK_SPEED_1G | + ETH_LINK_SPEED_10G); +} + static int dpaa_eth_link_update(struct rte_eth_dev *dev, int wait_to_complete __rte_unused) { @@ -259,6 +278,7 @@ static struct eth_dev_ops dpaa_devops = { .dev_start = dpaa_eth_dev_start, .dev_stop = dpaa_eth_dev_stop, .dev_close = dpaa_eth_dev_close, + .dev_infos_get = dpaa_eth_dev_info, .rx_queue_setup = dpaa_eth_rx_queue_setup, .tx_queue_setup = dpaa_eth_tx_queue_setup, -- 2.9.3