From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from EUR02-AM5-obe.outbound.protection.outlook.com (mail-eopbgr00044.outbound.protection.outlook.com [40.107.0.44]) by dpdk.org (Postfix) with ESMTP id 117A21B114 for ; Fri, 28 Sep 2018 07:17:45 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nxp.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=LfVhMh0TR1QSnEwfJsfEQEKnCOs6DDEUg+SPz/1dhjg=; b=tXqqm8b30R2Op0dURGycflO1DJQFBxtgZdBKVkM2bCioGYYo8aC/DwlOIbYphd2z224js3xa3Yi1ID+XKVlc+oF25RuOhtZfDhLb3xSs4NntOzTeJPGDSMvncZYxLOxU+DPtpDKsst6HbnaosB3HcklBVQ24ZazjUNvqMyHCe1I= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=G.Singh@nxp.com; Received: from Tophie.ap.freescale.net (14.142.187.166) by DB5PR04MB1527.eurprd04.prod.outlook.com (2a01:111:e400:5993::21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1185.20; Fri, 28 Sep 2018 05:17:42 +0000 From: Gagandeep Singh To: dev@dpdk.org, ferruh.yigit@intel.com Cc: pankaj.chauhan@nxp.com, Gagandeep Singh Date: Fri, 28 Sep 2018 10:46:46 +0530 Message-Id: <20180928051647.32341-3-g.singh@nxp.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20180928051647.32341-1-g.singh@nxp.com> References: <20180913094201.17098-1-g.singh@nxp.com> <20180928051647.32341-1-g.singh@nxp.com> MIME-Version: 1.0 Content-Type: text/plain X-Originating-IP: [14.142.187.166] X-ClientProxiedBy: MAXPR0101CA0035.INDPRD01.PROD.OUTLOOK.COM (2603:1096:a00:d::21) To DB5PR04MB1527.eurprd04.prod.outlook.com (2a01:111:e400:5993::21) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 2f1a0a26-5b71-40de-c8fc-08d62501b85d X-MS-Office365-Filtering-HT: Tenant X-Microsoft-Antispam: BCL:0; PCL:0; RULEID:(7020095)(4652040)(8989299)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(8990200)(5600074)(711020)(4618075)(2017052603328)(7153060)(7193020); SRVR:DB5PR04MB1527; X-Microsoft-Exchange-Diagnostics: 1; DB5PR04MB1527; 3:F4JBgAha4li6lLm2BGUddJ/o7v93pkiL0qMtdAVqwYlBMRyQTReYbKJiC3pI7qcBm/mhUj3uemP2F23pBj115jnvjyZuQ0EddHNQXO8obe/lHjx+RoMZFQcpEKjpLZiRRsZuaqdZhci52qg17t07EchvJ/iG475aqCJX+738jMh8CnxZXoPAMau9eNhyeaZFVtUju9c/FvccmvtmgpOGbPVqjevQ++pV8Bz8x/Vok/1/utRJAahaFKD0DIBbVCwQ; 25:nqHVIaYELiOzzncxa1kmR7K+edHYcaj6/6y9yEaqGhuHqHx3TC/Nb9Agkhz7phO9iT/SWf0GBvDXv2hiTtXooOWC9vwXSJNNRP3Cfwk2EpjmS8W5QbQvuUbxQb58dAvZ19JLgsaQRbQtYyGD+0UIfUhZT9fs2uxI/P2LbdXRHlLgyTRRh+eZuVPdoPFMY1i1xCxOUjdH4/RdnfCNJ0g+E3YLezD5sjT+TR690/ujLBPAbWbCsHThSzd0iNu8U2PTmVTayFp0ttyBXxw46s3jS82d0cJg3bU8LcCLmTzbmhYoxyH05mvrCAq/L7Qrovj/K90W/45oGMzeGEEk94TvoQ==; 31:BAtwLnVH/u/4zK6KlV2QMN39osXF8gd5kLQ+pGTEkNmnfaqym0EsZL3YxU15+SipbDI2/A/6X93OR2ozLmsM04eZsv1b7E6xve3KhLVkT2LEOUg5CaD8RmXjU7yDn5EEMOEdsp7VfZ6zz2nJHSDnr/NPDCdwnJ60tovnrKg7ZC1zdBqeVfZTzABxzNu9CBPGRDeSEn3dnJItG2h9CNpu93JZE12pSF/M1fkEddTqC94= X-MS-TrafficTypeDiagnostic: DB5PR04MB1527: X-Microsoft-Exchange-Diagnostics: 1; DB5PR04MB1527; 20:m9IdthWf9Ijy9CEDx6MjgDKEaC7YEyWVCQJO5ToU4xUSr+ZWuQPQEToehluAM6dRYxCuOwZfaK4n+ZZNPD6+GG18fzHd3OOTkWTFPRWnz7yEZBx5ThhNz+hoCtWqiCVkn0nNtJlb/b+aeqMvZpnWypVa4ITLGKE3qcw+ztwIQOvtfr8I8jWQO2F7UcDYmZUX///dFrrS++DSAfQzgTgXOX+yE6ss7SHUmMKO3DIuPZt73uEqDFZTkBqKsmmZ5IglA+PVD7WMBVZAS/A6gtdFYrDEJDSZhtijOssaS8cnr4CYcgxD1Ouloch1U7pfhBNVCXTCEsghIZcCRoT3iJ8EbglJaX7bLhh3B8Q7bSKzBHtOw3q89eFJYRqGiKSt7j4Rq9oehqFZf2KndjWX75Js+8BpKJ5qJsMeqW12YMJD9FhWLMT483nlqLH7v48b5GX1eUicrU0qTAcYs9SaumaCUdK9fIm9EgcqDbNNyX/AZe/TdeNmJBhCSzc13DqBPJuj; 4:EXQqHOEPv6psW7rVMpboUs3rNr98LLw3WPesm+cDL/ua4nxkVGk5L0UwA2XLk8cWoZ1pnj30ZDSOx5RC5bzoWVeefk1SpjUF6g45fAqE4oey3Vl6k1JCXM+fBzj29a4khn1H5+FOE8m8Aj0x95cd4PMxcghN/whgMB7EPeIwd+h5r9rYE2YsWyR4Ee3HAZIRFDF535FW3bTjUQCvxj5tjhZ6P/wVs8BYlNr2bvysRMwJLd7DyVA5uM96Tl3Juu48ksxKAu++hyBCUUtjx/P7UaFPqpJEPYZ9Jfc7H7bOC7/Bxlgt9exS6pU7m6pdzwl7 X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(93006095)(93001095)(3002001)(3231355)(944501410)(52105095)(10201501046)(6055026)(149066)(150057)(6041310)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123562045)(20161123564045)(20161123560045)(201708071742011)(7699051); SRVR:DB5PR04MB1527; BCL:0; PCL:0; RULEID:; SRVR:DB5PR04MB1527; X-Forefront-PRVS: 0809C12563 X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(136003)(346002)(366004)(39860400002)(376002)(396003)(189003)(199004)(105586002)(4326008)(53936002)(16586007)(50226002)(47776003)(6512007)(81156014)(486006)(66066001)(81166006)(8676002)(106356001)(478600001)(446003)(316002)(8936002)(476003)(97736004)(11346002)(2616005)(72206003)(6486002)(956004)(26005)(16526019)(186003)(5660300001)(14444005)(5009440100003)(1076002)(48376002)(7736002)(34290500001)(305945005)(68736007)(50466002)(36756003)(52116002)(2906002)(76176011)(51416003)(55236004)(3846002)(6116002)(86362001)(6506007)(386003)(25786009)(110426005); DIR:OUT; SFP:1101; SCL:1; SRVR:DB5PR04MB1527; H:Tophie.ap.freescale.net; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: nxp.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1; DB5PR04MB1527; 23:nIbTvtz149dQlKBaEGX6/nEGuAbXRDyrJCHQtO8kt?= =?us-ascii?Q?NKBkvdTuGi6upGKfqruP+gwU9rS80kq2uYHTdzxuyccLmZNb3HglDj+oEbwS?= =?us-ascii?Q?bi6q6FaWjcXycUScBzCOcIXqzFWI5UysZyafW20aQ8wEpZnIwc+aI8nAGJ2W?= =?us-ascii?Q?j0Ts6XcnAyLaZ5kaufSGuj5WeZWcne7Cq+FNGMSxp88auGnDsEZgZtAvB6Fj?= =?us-ascii?Q?wQjLLWLkcmA4xNwyV/ebEQemr8ZxGJz/PUlFfveVq2O9pLzPch+h22rRFyn9?= =?us-ascii?Q?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T0L0Djjo3PC7A==; 5:VqLlCINkEf7rrSRB+zpQ5jpYKZGgJ2fXtQEjbxIgtP7/jgsCqY9JkPOxzl4XcqEdbRi8qYa5KhQ2zWbFGDKOsxpWvIp5HvyYTB/XlREZmy3LpN9DZ0BtMYps4pdowHuOGg2a2jYqXogAyYYyF6U8tp2sHGdvj0n3HtAkp5BV0Wk=; 7:W6P0kCZvjuAJj3mRz42Ffd10B6wznArFtuh19lBTMymxAXNFE/md1rIAvldQQN9Sx31fHGgP8OVG3opaHC1a+NBR33PkkDXQWW6MoyzhISg/Beynakzk3UXiEJ4KWvwH2jC0WU38dz1a/vbK8LlxqeRJYx47+1Mr6V/21rV2BbGXhbauERXAuBT+aiieX2jmmiqjGtKj9JH2YkdPIArNA6vVS/ndKNctkY3FQsHspcenp+5e5BRlo8pda3WBCEhd SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: nxp.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 28 Sep 2018 05:17:42.0689 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 2f1a0a26-5b71-40de-c8fc-08d62501b85d X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-Transport-CrossTenantHeadersStamped: DB5PR04MB1527 Subject: [dpdk-dev] [PATCH v3 2/3] net/enetc: support packet parse type 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, 28 Sep 2018 05:17:45 -0000 Signed-off-by: Gagandeep Singh --- drivers/net/enetc/enetc_ethdev.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/drivers/net/enetc/enetc_ethdev.c b/drivers/net/enetc/enetc_ethdev.c index 2d90d8fd5..3e1c934cb 100644 --- a/drivers/net/enetc/enetc_ethdev.c +++ b/drivers/net/enetc/enetc_ethdev.c @@ -28,6 +28,7 @@ static int enetc_tx_queue_setup(struct rte_eth_dev *dev, uint16_t tx_queue_id, uint16_t nb_tx_desc, unsigned int socket_id, const struct rte_eth_txconf *tx_conf); static void enetc_tx_queue_release(void *txq); +static const uint32_t *enetc_supported_ptypes_get(struct rte_eth_dev *dev); /* * The set of PCI devices this driver supports @@ -50,6 +51,7 @@ static const struct eth_dev_ops enetc_ops = { .rx_queue_release = enetc_rx_queue_release, .tx_queue_setup = enetc_tx_queue_setup, .tx_queue_release = enetc_tx_queue_release, + .dev_supported_ptypes_get = enetc_supported_ptypes_get, }; /** @@ -165,6 +167,23 @@ enetc_dev_close(struct rte_eth_dev *dev __rte_unused) PMD_INIT_FUNC_TRACE(); } +static const uint32_t * +enetc_supported_ptypes_get(struct rte_eth_dev *dev __rte_unused) +{ + static const uint32_t ptypes[] = { + RTE_PTYPE_L2_ETHER, + RTE_PTYPE_L3_IPV4, + RTE_PTYPE_L3_IPV6, + RTE_PTYPE_L4_TCP, + RTE_PTYPE_L4_UDP, + RTE_PTYPE_L4_SCTP, + RTE_PTYPE_L4_ICMP, + RTE_PTYPE_UNKNOWN + }; + + return ptypes; +} + /* return 0 means link status changed, -1 means not changed */ static int enetc_link_update(struct rte_eth_dev *dev, int wait_to_complete __rte_unused) -- 2.17.1