From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM02-BL2-obe.outbound.protection.outlook.com (mail-bl2nam02on0057.outbound.protection.outlook.com [104.47.38.57]) by dpdk.org (Postfix) with ESMTP id F08AE160 for ; Mon, 7 May 2018 08:51:15 +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=8/tFvhaNBIrCa91YCKl86biic2nPYZuZ9PjTbeoXibg=; b=ESLdcvn5sErhZllehWNRyx/WhDy816DW2e2wd3gM5Jb6hEM1yvgkL6D/GG3ytX3hhUHDo4gvyGwk5/SfUOXuvSdRMVR7B7wM6zWb1FmGobRgmEdErZGxUToTsdhcowHWGrpf+zAV3jM+SUM7kvb0+O4iBhxG4IfSmeS/q6wxnsw= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Jerin.JacobKollanukkaran@cavium.com; Received: from jerin (122.178.239.6) by CO2PR07MB2520.namprd07.prod.outlook.com (2603:10b6:102:13::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.20.735.16; Mon, 7 May 2018 06:51:08 +0000 Date: Mon, 7 May 2018 12:20:53 +0530 From: Jerin Jacob To: Abhinandan Gujjar Cc: hemant.agrawal@nxp.com, akhil.goyal@nxp.com, dev@dpdk.org, narender.vangati@intel.com, nikhil.rao@intel.com, gage.eads@intel.com Message-ID: <20180507065051.GA7696@jerin> References: <1525546030-11204-1-git-send-email-abhinandan.gujjar@intel.com> <1525546030-11204-4-git-send-email-abhinandan.gujjar@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <1525546030-11204-4-git-send-email-abhinandan.gujjar@intel.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-Originating-IP: [122.178.239.6] X-ClientProxiedBy: BM1PR0101CA0013.INDPRD01.PROD.OUTLOOK.COM (2603:1096:b00:18::23) To CO2PR07MB2520.namprd07.prod.outlook.com (2603:10b6:102:13::7) X-MS-PublicTrafficType: Email X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4534165)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:CO2PR07MB2520; X-Microsoft-Exchange-Diagnostics: 1; CO2PR07MB2520; 3:/lW2Z55/4EugCyyv91TI5CFdDIa4fytNCUbdwH2r2iLLH0ib/wkr4GZyXXD0okpIsdndSqothxqL12d01ekS//IdLK4xt9mHmARCOWaFpvG/oqzYahCTqi2BKU1VRRyyETMrBm+s6HFRChuS0T+8WGfW9lchmpxNGwWp/ThofsErBtF3nFYwS3FVf8riemc743xyXDdMIUsjOfJvUAYzAMZmi7/50I2Pj9PDVNwtn0gK6FN72YyBrNr/1OHh0IZY; 25:BPicFSa8pm+OtcF4G/EL1tf2tPTZ2vRTkqMU+YFSDzC2v527b0zQrcwXY/NstRGWnF7GW/VvAVGv+oWhJypt8y+kOYxnyk5zbnwMpCqZwzQRPZVYhXAxZHIRIDw4qcKnESIkGZI7aBoEk/kquN3JxXpSqC7UJMdkILGoiJhoBUX5bIGUlwsXeung5x7kxQtKegJBxxZ8FYQ2nn/CtDeRSBtNTuMeBUlGA7GVj9qdyqcenJ1uuHEBfHt+Nh618i40Qkok9qgkGiRLGV5v5iupobRM/vGxHiSmDcVqFcQ6SQ8dSO/ohInCX4Mk7sHrkr10SYgO18deQm3isRRs1k4EJw==; 31:o8JPLjZ0x2VQ2PlfTmG4GUmPa0Fi77et1Ao11PHdV//2CcTzp09K+DOzRcE67e4IvSKAKDWESDXiauqAel9p7TBNHAlMiZTiwlv33VL3rOmV4QDm+qndhyCI0YB/RKue/ejJDXUSFobBhLaGOpTbVMq/Lc7G72r1JRGjEt+oyLoW7o2EoMXAI9XO/0Vc+7k+9VBUp+WFuwoclfTndjiGpbMxrx5GmCckR03GrZqcy1A= X-MS-TrafficTypeDiagnostic: CO2PR07MB2520: X-Microsoft-Exchange-Diagnostics: 1; CO2PR07MB2520; 20:1l8hzUmaqD9GTH501Fvf+WJEdljjPPLyLzV0JRQnmHndoBIwFQSJ2aCRWoymVXUMwqvm2v3ypT0iUl9wgRSoeW7ttBJtcgkW6CM1aB/IRVKVHqAjMVQWNSSvNQEfBazFoUCMS60SXrlOcRZ6H+Hs6Yc/5wDDKqnosz6gxw/PciAWEEuWDTHiGNE6T/I0Hn945eF03TjbIOdIMoz9q8d8Yi4Fs+rasL/cnOEbkGxNg+5+uePhJ934QGG4QBNiv3NV6spNXqlEWTf7hqncCHD94FtD+3yYRS/RYXDfGPaAc8BsTTERMnWFVaKgv67gQOLgelOkRz9JmVHusu0Xc+QqZsUE0TS/1d+lW4/f9yHABGswtPQcOLYSasTk3p4dLqTMC+MJot0pu30HTj6KifefWz8bWkessKHJEg0ALr1fKJH0mW9mJSwSU0lu0bTY3NXfT45SSnlwg2XeAYm3Xf5eDQaBaCF8ZEj3prGFuwOWGFMCvpehoU6JUDqu53kc3KBHLFu1BQ7k2cQWRUyCbWhAuA+833ok2PLVvxcVgnyXOXwLYHRLmmQQSGL0Sx2wXhcWbaU++Y5HqPhTkK4Rpz/tzcPhgdNFlQVd9cAVoF1j/wM= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(185117386973197)(228905959029699); X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0; PCL:0; RULEID:(8211001083)(6040522)(2401047)(5005006)(8121501046)(10201501046)(3002001)(3231254)(944501410)(52105095)(93006095)(149027)(150023)(6041310)(20161123562045)(20161123564045)(20161123560045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123558120)(6072148)(201708071742011); SRVR:CO2PR07MB2520; BCL:0; PCL:0; RULEID:; SRVR:CO2PR07MB2520; X-Microsoft-Exchange-Diagnostics: 1; CO2PR07MB2520; 4:zKdzZwUjAEb56Pp2O3t/ZTdxQIJ1SWv1vPhiKudLVDloDl2Pduz8hunplkW2Gp4KDv+KRYDbNBEJHfZsAaMjJ0ftq8FsEZpLQtMlkIgRD5+oA3zUXdeYZ+Vg90uG3aI/TKRCLSScJ3xhjmEMHs6nceH5c+SfOeLNSsWPWgVvueWBw5f+jb4P7V/WefTtq2rmnsUkkadX/xN8sDlHpG3Tqlil6JnW1kuhwHqXT/IGSNQiwcpX0M0dQ6j3X4dcCn/qz5KkkLXAKD/kbkPY8USY7JcBIO+jOITY/9MdYss0x7tHnnrBL5VkcSOqL+g/CjwSi5fpJDOg18rVBf+fbGDm+ornh6I7fGxkVexVdQbimsI= X-Forefront-PRVS: 066517B35B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(396003)(366004)(346002)(376002)(39850400004)(39380400002)(13464003)(189003)(199004)(105586002)(106356001)(486006)(42882007)(6246003)(7736002)(305945005)(47776003)(66066001)(2906002)(8676002)(9686003)(97736004)(81156014)(55016002)(81166006)(4326008)(8936002)(2870700001)(53936002)(58126008)(52116002)(68736007)(2486003)(23676004)(6916009)(6496006)(52146003)(59450400001)(1076002)(8656006)(44832011)(316002)(6666003)(76176011)(33896004)(5660300001)(11346002)(956004)(446003)(476003)(3846002)(25786009)(33656002)(72206003)(33716001)(229853002)(26005)(386003)(478600001)(6116002)(186003)(16526019)(50466002)(18370500001); DIR:OUT; SFP:1101; SCL:1; SRVR:CO2PR07MB2520; H:jerin; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; MX:1; A:1; Received-SPF: None (protection.outlook.com: cavium.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtDTzJQUjA3TUIyNTIwOzIzOlZjR09ZY1FiaHFsaE1BaFd0cG8waXNkZmxh?= =?utf-8?B?a2NtWExxbTFDUXFaVTFuNjkycEhpbXVHL0pGZ2RsRDAxSDJqY3E3bnJLSGts?= =?utf-8?B?T1N5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: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; CO2PR07MB2520; 7:0OgwovoNSIF3t23cp8fJn+/XRXpNjhaaqrHkAJCGIdUWFCIQTTROHOiTdPN36gnIDuKSj2j86ifjiH/OG4u6wWV38D46AHSmtG+alYxWjewLrgnXKyrtIun9f2XCkAZoeNgdTcobmP93/g/YrLjqhpXU177QGO1VaiuczWKmr68lzrgA9swFAW+WzRS5hzAotDCS8oI8BmWdwF+txGIHPh2wURezurjbGdM5J6JxUiN2xUYdgFLFOCDg9ihC64hN X-MS-Office365-Filtering-Correlation-Id: c9e48056-6dea-4139-092f-08d5b3e6eb62 X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 May 2018 06:51:08.6807 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c9e48056-6dea-4139-092f-08d5b3e6eb62 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: CO2PR07MB2520 Subject: Re: [dpdk-dev] [v3, 3/5] eventdev: add crypto adapter implementation 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, 07 May 2018 06:51:16 -0000 -----Original Message----- > Date: Sun, 6 May 2018 00:17:08 +0530 > From: Abhinandan Gujjar > To: jerin.jacob@caviumnetworks.com, hemant.agrawal@nxp.com, > akhil.goyal@nxp.com, dev@dpdk.org > CC: narender.vangati@intel.com, abhinandan.gujjar@intel.com, > nikhil.rao@intel.com, gage.eads@intel.com > Subject: [v3,3/5] eventdev: add crypto adapter implementation > X-Mailer: git-send-email 1.9.1 > > Event crypto adapter is added to the meson build system > > Signed-off-by: Abhinandan Gujjar > Signed-off-by: Nikhil Rao > Signed-off-by: Gage Eads > --- > config/common_base | 1 + > lib/Makefile | 3 +- > lib/librte_eventdev/Makefile | 3 + > lib/librte_eventdev/meson.build | 8 +- > lib/librte_eventdev/rte_event_crypto_adapter.c | 1127 ++++++++++++++++++++++++ > lib/librte_eventdev/rte_eventdev_version.map | 12 + > 6 files changed, 1150 insertions(+), 4 deletions(-) > create mode 100644 lib/librte_eventdev/rte_event_crypto_adapter.c > > diff --git a/config/common_base b/config/common_base > index 03a8688..8420d29 100644 > --- a/config/common_base > +++ b/config/common_base > @@ -577,6 +577,7 @@ CONFIG_RTE_LIBRTE_EVENTDEV_DEBUG=n > CONFIG_RTE_EVENT_MAX_DEVS=16 > CONFIG_RTE_EVENT_MAX_QUEUES_PER_DEV=64 > CONFIG_RTE_EVENT_TIMER_ADAPTER_NUM_MAX=32 > +CONFIG_RTE_EVENT_CRYPTO_ADAPTER_MAX_INSTANCE=32 add EVENT_CRYPTO_ADAPTER_MAX_INSTANCE=32 in config/rte_config.h, otherwise meson build will fail. Check the meson build in next revision. FAILED: lib/rte_eventdev@sta/librte_eventdev_rte_event_crypto_adapter.c.o ccache gcc -Ilib/rte_eventdev@sta -Ilib -I../lib -Ilib/librte_eventdev -I../lib/librte_eventdev -Iconfig -I../config -I. -I../ -Ilib/librte_eal/common/include/arch/x86 -I../lib/librte_eal/common/include/arch/x86 -Ilib/librte_eal/common/include -I../lib/librte_eal/common/include -Ilib/librte_eal/common -I../lib/librte_eal/common -Ilib/librte_eal/linuxapp/eal/../../../librte_compat -I../lib/librte_eal/linuxapp/eal/../../../librte_compat -I../lib/librte_eal/linuxapp/eal/include -Ilib/librte_eal -I../lib/librte_eal -Ilib/librte_compat -I../lib/librte_compat -Ilib/librte_ring -I../lib/librte_ring -Ilib/librte_ethdev -I../lib/librte_ethdev -Ilib/librte_net -I../lib/librte_net -Ilib/librte_mbuf -I../lib/librte_mbuf -Ilib/librte_mempool -I../lib/librte_mempool -Ilib/librte_kvargs -I../lib/librte_kvargs -Ilib/librte_hash -I../lib/librte_hash -Ilib/librte_timer -I../lib/librte_timer -Ilib/librte_cryptodev -I../lib/librte_cryptodev -fdiagnostics-color=always -pipe -D_FILE_OFFSET_BITS=64 -Wall -Winvalid-pch -O3 -include rte_config.h -Wsign-compare -Wcast-qual -Wno-address-of-packed-member -Wno-format-truncation -fPIC -march=native -DALLOW_EXPERIMENTAL_API -MD -MQ 'lib/rte_eventdev@sta/librte_eventdev_rte_event_crypto_adapter.c.o' -MF 'lib/rte_eventdev@sta/librte_eventdev_rte_event_crypto_adapter.c.o.d' -o 'lib/rte_eventdev@sta/librte_eventdev_rte_event_crypto_adapter.c.o' -c ../lib/librte_eventdev/rte_event_crypto_adapter.c ../lib/librte_eventdev/rte_event_crypto_adapter.c: In function ‘eca_valid_id’: ../lib/librte_eventdev/rte_event_crypto_adapter.c:113:14: error: ‘RTE_EVENT_CRYPTO_ADAPTER_MAX_INSTANCE’ undeclared (first use in this function); did you mean ‘RTE_EVENT_CRYPTO_ADAPTER_OP_FORWARD’? return id < RTE_EVENT_CRYPTO_ADAPTER_MAX_INSTANCE; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ RTE_EVENT_CRYPTO_ADAPTER_OP_FORWARD ../lib/librte_eventdev/rte_event_crypto_adapter.c:113:14: note: each undeclared identifier is reported only once for each function it appears in ../lib/librte_eventdev/rte_event_crypto_adapter.c: In function ‘eca_init’: ../lib/librte_eventdev/rte_event_crypto_adapter.c:124:6: error: ‘RTE_EVENT_CRYPTO_ADAPTER_MAX_INSTANCE’ undeclared (first use in this function); did you mean ‘RTE_EVENT_CRYPTO_ADAPTER_OP_FORWARD’? RTE_EVENT_CRYPTO_ADAPTER_MAX_INSTANCE; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ RTE_EVENT_CRYPTO_ADAPTER_OP_FORWARD ../lib/librte_eventdev/rte_event_crypto_adapter.c: In function ‘eca_valid_id’: ../lib/librte_eventdev/rte_event_crypto_adapter.c:114:1: warning: control reaches end of non-void function [-Wreturn-type] } ^