From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-CO1-obe.outbound.protection.outlook.com (mail-co1nam03on0126.outbound.protection.outlook.com [104.47.40.126]) by dpdk.org (Postfix) with ESMTP id DA4684CC7 for ; Mon, 23 Apr 2018 14:33:51 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freescale.onmicrosoft.com; s=selector1-freescale-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version; bh=ebX2J8YCqOBTcBWlpPv3EHaGyISvpjxOY/lePpTnOFo=; b=Vr9xffYX4YEVFpeRTzw52n0XfXNgOxY1rXAmvsjrJVar30jJB6WLefsK8Nqd0lETSbjtXyJ1ljWN6mHEvlUT0tHSdu236gMCbpiyy9RNXP5VV5P4NdKZXPVLVLNs8yxn2SJB4JL23/eA7h90usq6iaU0nXNLbPYjjrYAg0z0xco= Received: from CY4PR03CA0006.namprd03.prod.outlook.com (2603:10b6:903:33::16) by BN3PR03MB2180.namprd03.prod.outlook.com (2a01:111:e400:7bb9::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.696.12; Mon, 23 Apr 2018 12:33:47 +0000 Received: from BN1AFFO11FD026.protection.gbl (2a01:111:f400:7c10::155) by CY4PR03CA0006.outlook.office365.com (2603:10b6:903:33::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.696.13 via Frontend Transport; Mon, 23 Apr 2018 12:33:47 +0000 Authentication-Results: spf=fail (sender IP is 64.157.242.222) smtp.mailfrom=nxp.com; dpdk.org; dkim=none (message not signed) header.d=none;dpdk.org; dmarc=fail action=none header.from=nxp.com; Received-SPF: Fail (protection.outlook.com: domain of nxp.com does not designate 64.157.242.222 as permitted sender) receiver=protection.outlook.com; client-ip=64.157.242.222; helo=tx30smr01.am.freescale.net; Received: from tx30smr01.am.freescale.net (64.157.242.222) by BN1AFFO11FD026.mail.protection.outlook.com (10.58.52.86) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.20.653.14 via Frontend Transport; Mon, 23 Apr 2018 12:33:46 +0000 Received: from az84smr01.freescale.net (az84smr01.freescale.net [10.64.34.197]) by tx30smr01.am.freescale.net (8.14.3/8.14.3) with ESMTP id w3NCXjXW026403; Mon, 23 Apr 2018 05:33:45 -0700 Received: from sunil-OptiPlex-790.ap.freescale.net (sunil-OptiPlex-790.ap.freescale.net [10.232.132.53]) by az84smr01.freescale.net (8.14.3/8.14.0) with ESMTP id w3NCXfYh016265; Mon, 23 Apr 2018 05:33:43 -0700 From: Sunil Kumar Kori To: CC: , , Date: Mon, 23 Apr 2018 18:03:36 +0530 Message-ID: <20180423123337.5653-2-sunil.kori@nxp.com> X-Mailer: git-send-email 2.9.3 In-Reply-To: <20180423123337.5653-1-sunil.kori@nxp.com> References: <20180420104541.21987-1-sunil.kori@nxp.com> <20180423123337.5653-1-sunil.kori@nxp.com> X-EOPAttributedMessage: 0 X-MS-Office365-Filtering-HT: Tenant X-Forefront-Antispam-Report: CIP:64.157.242.222; IPV:NLI; CTRY:US; EFV:NLI; SFV:NSPM; SFS:(10019020)(396003)(346002)(39860400002)(39380400002)(376002)(2980300002)(1109001)(1110001)(339900001)(189003)(199004)(9170700003)(2351001)(8656006)(53936002)(47776003)(356003)(8936002)(8676002)(50226002)(81166006)(36756003)(26005)(86362001)(50466002)(48376002)(85426001)(336012)(4326008)(106466001)(446003)(11346002)(6666003)(2906002)(16586007)(6916009)(54906003)(77096007)(1076002)(498600001)(51416003)(76176011)(105606002)(59450400001)(486006)(2616005)(126002)(5660300001)(476003)(305945005)(316002); DIR:OUT; SFP:1102; SCL:1; SRVR:BN3PR03MB2180; H:tx30smr01.am.freescale.net; FPR:; SPF:Fail; LANG:en; MLV:ovrnspm; MX:1; A:1; PTR:ErrorRetry; X-Microsoft-Exchange-Diagnostics: 1; BN1AFFO11FD026; 1:ucc1FRqi0C82RxfseZJj6dynpqzoA4FqPKR8edKc4PStz1M5RBAA05zF3t9K4C6PjMTwzkp3ESp5Qt2txyMc6tGPG1IV6CbcACDqAxBORx1yRTGT95Drgo5y8/gkGlM7 MIME-Version: 1.0 Content-Type: text/plain X-MS-PublicTrafficType: Email X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4534165)(4627221)(201703031133081)(2017052603328); SRVR:BN3PR03MB2180; X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2180; 3:Oa2YyOvxCkwsXBRqTPSz3iV/XeuvpGi2dw7A7V0LtpVF4nQVB2TOZ5w0D3/Io0p4la9cfBHHHYv8eQfymH82Ju1ARFy5cnS/MM357ioqkIIlZTtOLcAc1+eFQpChXo7HEFebiOvySpAIoOP+6HrqtNdRFpUlauyEYX5aJofGZKQYOgqfXfW3+8Bd6x1Q3nBN1an7AVTSV/jr39IjWaQYkNa/a/qQxjxG0AR60DVl6llrUCwtyDOhLz3XdF42prjkiTJKh0H8wSAq5aJTKn8GSMBMzq9YyCSIEv6PM3UAEXle2tcMZfLLm4wj2IKc5XkmYYJEZlnhxa/6ZdXm7Ljhx8FIlEe16415l64U/nnvpeM=; 25:Py9O8B7sMm7zRxB3aHJpq08uBnKwm59FUOgXpWyrM7Pmb1TVQIip+g4TWiLTRBJ2Hu4eNL9Bh5btshiVQTiqlc5cUjBlCIChiBsGBuin0UNiNfJG+wHLbvu2hNuRNakpFkVVQkebzidIRXnrhWuu0a57AnP4IiPMTObOQ+b9iYlknEdcXbco2wjgOP3EEEBCCk0xEAzt/SVkbjNZGb4SsqNx67d7g1ZjI2aBFvMIUgwAJfjzxGnP9jQV6Tro7HSMk4ZZ+NhDn1vsj+xelVsd1IoJ8VXQOk7swXVf9Wc7szfsHPuKyDsCnEHrraGpWBXsBFQZzGm2LdMQey2P8ONkcg== X-MS-TrafficTypeDiagnostic: BN3PR03MB2180: X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2180; 31:NeFMfggJxZ/WAFFcO4Kqv+q5SkeSeZPe3x/gfxWV0d1O8B5QGEnlh6AGZi5Fu19rRdtZcdAQx3bWJEvGqzZnK45AAl6M/Xw4sF7qR4eouhYsvVEoHksf5Ll/KrTSRBrqTM17WTNkKP6YQS3z3dLKeiZQdLgVSXCebblfwrcSUXZW33/14z++UL+f0iTCYW3aOUoYvkWOyZQDzPkrhHlVM8oA7AtOsmb4Pl4yc23fCSk=; 20:IwW0lqm1SD2df6X7OGxHVlrf6ozFn3lMwMz8OhCuR9mLY79rPjY5PjTPC68i4OPeE+PQF+F0oZsH6OiWrMGFWgNEr12GxxTs5/eS2Sjv86eNL7f+ypEJF4355fFjogeEIbub22hTkGUC0QHww7AisqNEVG6XT9sQs0HmFgXUAltRe6YuQPgJ9EwBB5/OvDbB0kgNpY21sT3dGQYwPYsdpWdDj80D69jWrjM3MgoOj0UXM8vIK/9k+gwddxSVuo14bQLgCNbHfb2ZSINhVWIbWk1WrhEs7WXfURJ0fSdy25sfCpVE0hf3kfrZpkYyRkODBatyfnWyijQFcQjiEnsVXi03/YsvgyusVMzg3dksVKin1ZVQgcaVYmGyhRbVWJ6dlgD7v1Ukx0Z5dbqivIQb6h7OoFO0cmr1UbkxuDG954TOa97Pddebg3AsK/NVWF4V6Fg1oi9JMeRpHmKnD9MRYZ2GJSYbLbSxFHIoMdqLHlmAn1DuZW3OYR0aOjFQWe+CXpejyUznD8F4sVH1kcoVeu2UG4rxLSHFAdgLIYmnWomcqnes8D7PyP4uTMEGSB6lcGCs0FMHFS2LxOeeCQSU3evAv1xhlXHT7uB+xwzGhr8= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(6040522)(2401047)(5005006)(8121501046)(3231232)(944501410)(52105095)(10201501046)(3002001)(93006095)(93003095)(6055026)(6041310)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061750153)(20161123562045)(20161123560045)(20161123564045)(6072148)(201708071742011); SRVR:BN3PR03MB2180; BCL:0; PCL:0; RULEID:; SRVR:BN3PR03MB2180; X-Microsoft-Exchange-Diagnostics: 1; BN3PR03MB2180; 4:kOOCWFPp2pTR0OvkB48wGPpI0aCKcYUe6KhZt3KqqgPTic6NCgit3x2wC1pfkm/SYOlN+8QzqTR4ynVgJ2DyR6GzojLMYFh0LyL5LtjfVFv4Mkj9+yEa33Mt0JhexdZ4iWpRST+Lut9NTI8KjbiNqC/Yi6at+NN1KXGpG+ZFR/HnZY6dQVy+rz/HPmkPbdE6tuMFA0epfSPma2JgtcidfbIwc8CGB3TMnm8yG767PmdBZL7MhjvBUsnNtULDtJ2J2g6NNp4rVWeonO0RxWiwPmWhXMyXnAES92rpOSiVkqDhUUl3fTqXFQP6s2kwmn1Z X-Forefront-PRVS: 06515DA04B X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; BN3PR03MB2180; 23:M6WogsZa2v5aAWK3B4suHRNSCNNMffQZMaebHIJiq?= =?us-ascii?Q?fF9JGs1U7IZMCPXdl9kfDi12T2XmfweObBUfRWpZJLgOnnast1seMCZmofcU?= =?us-ascii?Q?yU9WO0nohxy3uizkNWu+2Fc/qmXHq31NTYtpf6NXe4mnKw75aCLIZJ+R3GCr?= =?us-ascii?Q?4sTLofcxw0HNGlj5SD/XtB03rA0wfxm1NDxUYAwy3WxwaYFfPjVE1LHMOv0X?= =?us-ascii?Q?RbTuR21OTOWoVjZbo4TrQJZePucH+J4CFLnxY9MszOHtMoTEAbw62anLQDIO?= =?us-ascii?Q?HpDq06L6g8O8Xwz/DaeyWLH3Hfuglsnz7Up6rxRgYdMDdLirf1sfPh8rx0yd?= =?us-ascii?Q?z0Hlxuo7PaQUHVP292/RjXdmqz8hBHcUtS/OctJNPBn+BrFpV41ro0w0vGDR?= =?us-ascii?Q?13HFHIWsz0EXxBlVnWSmuCZQYSa9y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YWCNV46NJQ3kgsbt4frK2qFwsjN+VNyqutPcqAA2neCYbUl00GDpLgZXGDZ/vTBdfFzhBZJcuUXqxlYygEsfbdykl4bUuVpLcc54SWFqaUJpZas187AuxL X-MS-Office365-Filtering-Correlation-Id: 2237c1f4-541d-4062-f872-08d5a916756e X-OriginatorOrg: freescale.onmicrosoft.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Apr 2018 12:33:46.5814 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2237c1f4-541d-4062-f872-08d5a916756e X-MS-Exchange-CrossTenant-Id: 710a03f5-10f6-4d38-9ff4-a80b81da590d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=710a03f5-10f6-4d38-9ff4-a80b81da590d; Ip=[64.157.242.222]; Helo=[tx30smr01.am.freescale.net] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3PR03MB2180 Subject: [dpdk-dev] [PATCH v2 1/2] net/dpaa: non supported offloads are ignored with warning 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: Mon, 23 Apr 2018 12:33:52 -0000 Fixes: 16e2c27f4fc7 ("net/dpaa: support new ethdev offload APIs") Cc: shreyansh.jain@nxp.com Signed-off-by: Sunil Kumar Kori --- drivers/net/dpaa/dpaa_ethdev.c | 34 +++++++++++++++++++++++++++------- 1 file changed, 27 insertions(+), 7 deletions(-) diff --git a/drivers/net/dpaa/dpaa_ethdev.c b/drivers/net/dpaa/dpaa_ethdev.c index b2740b4..81001cb 100644 --- a/drivers/net/dpaa/dpaa_ethdev.c +++ b/drivers/net/dpaa/dpaa_ethdev.c @@ -45,6 +45,25 @@ #include #include +/* Non-Supported Rx offloads */ +static uint64_t dev_rx_offloads_not_supported = + DEV_RX_OFFLOAD_TCP_LRO | + DEV_RX_OFFLOAD_MACSEC_STRIP | + DEV_RX_OFFLOAD_HEADER_SPLIT | + DEV_RX_OFFLOAD_VLAN_EXTEND | + DEV_RX_OFFLOAD_SECURITY; + +/* Non-Supported Tx offloads */ +static uint64_t dev_tx_offloads_not_supported = + DEV_TX_OFFLOAD_TCP_TSO | + DEV_TX_OFFLOAD_UDP_TSO | + DEV_TX_OFFLOAD_VXLAN_TNL_TSO | + DEV_TX_OFFLOAD_GRE_TNL_TSO | + DEV_TX_OFFLOAD_IPIP_TNL_TSO | + DEV_TX_OFFLOAD_GENEVE_TNL_TSO | + DEV_TX_OFFLOAD_MACSEC_INSERT | + DEV_TX_OFFLOAD_SECURITY; + /* Keep track of whether QMAN and BMAN have been globally initialized */ static int is_global_init; /* At present we only allow up to 4 push mode queues - as each of this queue @@ -150,16 +169,17 @@ dpaa_eth_dev_configure(struct rte_eth_dev *dev) PMD_INIT_FUNC_TRACE(); dpaa_eth_dev_info(dev, &dev_info); - if (((~(dev_info.rx_offload_capa) & rx_offloads) != 0)) { - DPAA_PMD_ERR("Some Rx offloads are not supported " - "requested 0x%" PRIx64 " supported 0x%" PRIx64, + /* Rx offloads validation */ + if (dev_rx_offloads_not_supported & rx_offloads) { + DPAA_PMD_ERR( + "Rx offloads not supported - Requested 0x%" PRIx64 " supported 0x%" PRIx64, rx_offloads, dev_info.rx_offload_capa); return -ENOTSUP; } - - if (((~(dev_info.tx_offload_capa) & tx_offloads) != 0)) { - DPAA_PMD_ERR("Some Tx offloads are not supported " - "requested 0x%" PRIx64 " supported 0x%" PRIx64, + /* Tx offloads validation */ + if (dev_tx_offloads_not_supported & tx_offloads) { + DPAA_PMD_ERR( + "Tx offloads not supported - Requested 0x%" PRIx64 " Supported 0x%" PRIx64, tx_offloads, dev_info.tx_offload_capa); return -ENOTSUP; } -- 2.9.3