From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-SN1-obe.outbound.protection.outlook.com (mail-sn1nam02on0050.outbound.protection.outlook.com [104.47.36.50]) by dpdk.org (Postfix) with ESMTP id 31CA57D47 for ; Thu, 31 Aug 2017 16:55:54 +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=qnAhVuqaZrFiWtUt+Ir9Dc5eAHSMgWOWiM+H66lCCic=; b=R2mBdFJekOsun4rvO61/K8sAzqNR1GtX7dyobzZjj7GSvnY+8r1AhyP3cNJ2OIcyHGkTUtmLCDvdfPf5MPymJEKJU4T4Pcj22unuyjT6a6WHMMCNKfXDD/nVbfIFHPh98VUYklRYIF5qEhiyrCNs8Tk+NUY02sfL4uHQ5TwPhic= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Jerin.JacobKollanukkaran@cavium.com; Received: from jerin.domain.name (171.76.126.71) by SN2PR07MB2526.namprd07.prod.outlook.com (2603:10b6:804:6::26) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.13.10; Thu, 31 Aug 2017 14:55:50 +0000 From: Jerin Jacob To: dev@dpdk.org Cc: ferruh.yigit@intel.com, santosh.shukla@caviumnetworks.com, Jerin Jacob Date: Thu, 31 Aug 2017 20:24:24 +0530 Message-Id: <20170831145436.5397-15-jerin.jacob@caviumnetworks.com> X-Mailer: git-send-email 2.14.1 In-Reply-To: <20170831145436.5397-1-jerin.jacob@caviumnetworks.com> References: <20170831145436.5397-1-jerin.jacob@caviumnetworks.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [171.76.126.71] X-ClientProxiedBy: MA1PR01CA0109.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:1::25) To SN2PR07MB2526.namprd07.prod.outlook.com (2603:10b6:804:6::26) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 1fba62b8-8b86-46e7-491a-08d4f080601a X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(300000500095)(300135000095)(300000501095)(300135300095)(300000502095)(300135100095)(22001)(2017030254152)(300000503095)(300135400095)(2017052603199)(201703131423075)(201703031133081)(201702281549075)(300000504095)(300135200095)(300000505095)(300135600095)(300000506095)(300135500095); SRVR:SN2PR07MB2526; X-Microsoft-Exchange-Diagnostics: 1; SN2PR07MB2526; 3:YnInreqZdlMRldsDj//WO82dC9DOAogMEbzg1KuFuzna+mKrY03AIIe6bSMX3VHGyk00rNQT585uP1JTHr1hR/DBwR6147Na9YBF6SOd99iqeAipxRORmKCx9Mq2O/w+fCBPFRwO4s6P5CgC1qMNniORvkm4tvm8VTl6xHFD7/6rT5bPkawFTAl9GjYpoooaMoWK1n463WAwYwIa6CQnHWceoB8VTlFJCXFFEhQlB09c2cufX/pJUq1YRLk9izz7; 25:B1WJl7RKvxpSPndbDeA8DZw83dyy0dZi8SaPKS+prXPxXUeMVElz0L0B79kbXfVVxLxaZyZcj/b77Z5ItOWekQOZUUmOTlgtOK4osDCg+ZmGxy6hSOZUVHZ5exeOGmLApyJRJ4fbflHocFDanswrcz8tx/+QVgsfO3KujgiXiwAdGR72jNroafybiCYs2/WyOJ+Hhp34wR9xM79QbCD2JiLJBB4IFEm/OChMbgaYU3maUYqop7iiACsklbkvYG5z35c3KVIguAcRohObQP6RQiVKSp+qhpx0HNmH8k3GXPXa6yrnNgbeuAR5YmxKyte0uylx6kKVkWKJualRhsQiCQ==; 31:iGlvotQtQQH72FdM+D3WiXwLoajq1SzEcA3QYHGa4nO4tXlwGzYNDNOGguRhOxaVyFkcnpVhWM6cw7cIwQpFcMV1tIEX5k36SDYpaQ9HjFtE9J2gQ65kGFh2fpHpFKFR/UVu1XvN0qzOh1ABEwU9b3DP0gVCf/twRhlJHWDKHI2DKbLfAh1CjSOF412M0tfiCJvv4B5mCRY9tjsBSvG4dMXXlgAsIHp/FwejlewWT7E= X-MS-TrafficTypeDiagnostic: SN2PR07MB2526: X-Microsoft-Exchange-Diagnostics: 1; SN2PR07MB2526; 20:cJhxgJvRtejyfDllThUqQ4j2Y+wZxvq1HdLfKd8pF58xFIuPHcxDXx5ZZ8GVRqIWVMvz14yzwcOD12Aj+k+oImauMYEtBp2pcr3RALQmKKyxVdekkGSe2YjjdH4qKjTQw1KIV3LnudVcDgkOQ4Qb/ktQFVb2m/ECgo774/fVoIyinzBb/D/uHGJlcUa9ftc3jrdYoK7vnDW9vdqtIBGIDAqFmQXMnPkRPr5/7N5UjdzJpN+sCPvQ7FL1UyDrivUrsTQqAQcHTO0vJR8vRBrOu3lwl2jv1+AVMVDQeVFf7sTB0ir6GVBm+cMMQH37QtNdSQ19d5Z3dxXCgJWlGq1eMvlXTyL0/biv9edJLngKze6RTlHWGjPsnTyw14YGvs7uMNQmMAmL36Zyq+TT2hF9XLYo47Qwnb4YNV6KaFFNHq05LbK81erJ1gpceWlfCPm9CkJvGSV07WtV4/er+xwdaI9lVtCaIb3wNkY/Xz9kz2GwdjINKZxxK5MukbzvLviyBRtOhsQAcPccT5PZOgwyc7Zusjr6MPpS9BjZ8Oa7YoLlpx4Zz/NM5tg5nlzQf9mdPZdUTsTOWFAhqmRJjDW+5ie8JUbGkLlvFnDQYo+Nl68=; 4:AF/SklV1FUyN4iOoy2bBbcIAobCloc9YHJ+VVRak+0X8/XOkSlN1sjryI2fu/9Djgq2QwZCtaQjlDArGSttN/LfYOFfSlMBH4d6KR5epAL1WVE4eXVLlYiD1vH0IoD3cXeSLixNTLYVjOhWMnLWjPR+dYx53xiCEq7kX4zMxx2lEEhh01QWhT66IiHJH6NeWuHVQ8byjtAeK5hU8zyeW+qLKAgmxnLNR6gPAhHB+9oFAwrwMhMECnPUN7vSfvgC4 X-Exchange-Antispam-Report-Test: UriScan:; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(100000700101)(100105000095)(100000701101)(100105300095)(100000702101)(100105100095)(6040450)(601004)(2401047)(5005006)(8121501046)(93006095)(100000703101)(100105400095)(10201501046)(3002001)(6041248)(201703131423075)(201703061421075)(201703161042150)(20161123558100)(20161123564025)(20161123562025)(20161123560025)(20161123555025)(6042181)(6072148)(201708071742011)(100000704101)(100105200095)(100000705101)(100105500095); SRVR:SN2PR07MB2526; BCL:0; PCL:0; RULEID:(100000800101)(100110000095)(100000801101)(100110300095)(100000802101)(100110100095)(100000803101)(100110400095)(100000804101)(100110200095)(100000805101)(100110500095); SRVR:SN2PR07MB2526; X-Forefront-PRVS: 04163EF38A X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(6009001)(199003)(189002)(25786009)(1076002)(53936002)(3846002)(6116002)(498600001)(110136004)(72206003)(7736002)(6666003)(107886003)(6512007)(305945005)(6506006)(36756003)(6486002)(68736007)(5003940100001)(189998001)(50986999)(42882006)(106356001)(101416001)(76176999)(2950100002)(6916009)(5660300001)(2361001)(33646002)(2351001)(2906002)(4326008)(97736004)(105586002)(48376002)(50466002)(81166006)(66066001)(69596002)(8936002)(47776003)(53416004)(8676002)(50226002)(81156014)(42186005); DIR:OUT; SFP:1101; SCL:1; SRVR:SN2PR07MB2526; H:jerin.domain.name; FPR:; SPF:None; PTR:InfoNoRecords; A:1; MX:1; LANG:en; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; SN2PR07MB2526; 23:tTwaNO1tdUc7QGTFGQJIBPuoZE0Bg3OLMXzsaqP1A?= =?us-ascii?Q?0WsLJ1xhtRVDGAjNEaWzQiJ26AXWzRtCIYgwefXrIosncIqjoKwVspBN2NK7?= =?us-ascii?Q?DXRvBuDJ2OCI/5qvc6vfacPgWhcK3llOD1R3tZiXMB7xc1/UCDJ8mYlHmbOj?= =?us-ascii?Q?eHawiwaDPZFEakQGWhpQ/S2x13/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orOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 31 Aug 2017 14:55:50.9116 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN2PR07MB2526 Subject: [dpdk-dev] [PATCH 14/26] net/octeontx: add device info 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: Thu, 31 Aug 2017 14:55:54 -0000 Mark Speed capabilities, Lock-free Tx queue in features. Signed-off-by: Jerin Jacob Co-authored-by: Santosh Shukla --- doc/guides/nics/features/octeontx.ini | 2 ++ drivers/net/octeontx/octeontx_ethdev.c | 37 ++++++++++++++++++++++++++++++++++ 2 files changed, 39 insertions(+) diff --git a/doc/guides/nics/features/octeontx.ini b/doc/guides/nics/features/octeontx.ini index 6e397c9b1..259daccb8 100644 --- a/doc/guides/nics/features/octeontx.ini +++ b/doc/guides/nics/features/octeontx.ini @@ -4,6 +4,8 @@ ; Refer to default.ini for the full list of available PMD features. ; [Features] +Speed capabilities = Y +Lock-free Tx queue = Y Jumbo frame = Y CRC offload = Y Linux VFIO = Y diff --git a/drivers/net/octeontx/octeontx_ethdev.c b/drivers/net/octeontx/octeontx_ethdev.c index 10796f3df..fde52b444 100644 --- a/drivers/net/octeontx/octeontx_ethdev.c +++ b/drivers/net/octeontx/octeontx_ethdev.c @@ -262,9 +262,46 @@ octeontx_dev_configure(struct rte_eth_dev *dev) return 0; } +static void +octeontx_dev_info(struct rte_eth_dev *dev, + struct rte_eth_dev_info *dev_info) +{ + RTE_SET_USED(dev); + + /* Autonegotiation may be disabled */ + dev_info->speed_capa = ETH_LINK_SPEED_FIXED; + dev_info->speed_capa |= ETH_LINK_SPEED_10M | ETH_LINK_SPEED_100M | + ETH_LINK_SPEED_1G | ETH_LINK_SPEED_10G | + ETH_LINK_SPEED_40G; + + dev_info->driver_name = RTE_STR(rte_octeontx_pmd); + dev_info->max_mac_addrs = 1; + dev_info->max_rx_pktlen = PKI_MAX_PKTLEN; + dev_info->max_rx_queues = 1; + dev_info->max_tx_queues = PKO_MAX_NUM_DQ; + dev_info->min_rx_bufsize = 0; + dev_info->pci_dev = NULL; + + dev_info->default_rxconf = (struct rte_eth_rxconf) { + .rx_free_thresh = 0, + .rx_drop_en = 0, + }; + + dev_info->default_txconf = (struct rte_eth_txconf) { + .tx_free_thresh = 0, + .txq_flags = + ETH_TXQ_FLAGS_NOMULTSEGS | + ETH_TXQ_FLAGS_NOOFFLOADS | + ETH_TXQ_FLAGS_NOXSUMS, + }; + + dev_info->tx_offload_capa = DEV_TX_OFFLOAD_MT_LOCKFREE; +} + /* Initialize and register driver with DPDK Application */ static const struct eth_dev_ops octeontx_dev_ops = { .dev_configure = octeontx_dev_configure, + .dev_infos_get = octeontx_dev_info, }; /* Create Ethdev interface per BGX LMAC ports */ -- 2.14.1