From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from NAM03-BY2-obe.outbound.protection.outlook.com (mail-by2nam03on0067.outbound.protection.outlook.com [104.47.42.67]) by dpdk.org (Postfix) with ESMTP id 2E3121D7 for ; Mon, 7 May 2018 12:08:55 +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=Ji/wstjXigccLpbdGNKOoUfeAy0jG9WiH9soIxbufAs=; b=JPQzOY51cYLujCZW8wTRHauan9qTqOj176VBnYMH6sgS/E48Of0TkCAipIQGZEKC0VQpeYODLEdRKNIfx7v+IHA1lvdb4HpWICCg88/4iTHBQaApObfO8lQ2Hcz7b4rnkQx/2nmFiUnQ+eRcimUapV6OPM9qNBcOMAoPzb9RCik= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Jerin.JacobKollanukkaran@cavium.com; Received: from jerin (115.113.156.3) by BN3PR07MB2513.namprd07.prod.outlook.com (2a01:111:e400:7bbf::10) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.735.17; Mon, 7 May 2018 10:08:50 +0000 Date: Mon, 7 May 2018 15:38:34 +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: <20180507100833.GA7848@jerin> References: <1525546030-11204-1-git-send-email-abhinandan.gujjar@intel.com> <1525546030-11204-5-git-send-email-abhinandan.gujjar@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1525546030-11204-5-git-send-email-abhinandan.gujjar@intel.com> User-Agent: Mutt/1.9.4 (2018-02-28) X-Originating-IP: [115.113.156.3] X-ClientProxiedBy: PN1PR01CA0101.INDPRD01.PROD.OUTLOOK.COM (2603:1096:c00::17) To BN3PR07MB2513.namprd07.prod.outlook.com (2a01:111:e400:7bbf::10) X-MS-PublicTrafficType: Email X-Microsoft-Antispam: UriScan:; BCL:0; PCL:0; RULEID:(7020095)(4652020)(5600026)(4534165)(7168020)(4627221)(201703031133081)(201702281549075)(2017052603328)(7153060)(7193020); SRVR:BN3PR07MB2513; X-Microsoft-Exchange-Diagnostics: 1; BN3PR07MB2513; 3:63cTKIYF7WVI+bHsT/qbWwR1u+VXIBb0EW1SDYXre260Zejs9k3uk0r1BikH2ohv9uSIghfsf55vj6L5+lMFd112m7g0H/f9xkGU18P6aOelexGKVoVSSk2NSqfZMbVbhlnT2DPmy1nWEODKHIp6Tey7a1+h6SQ3pG/A29jXnQVUomQDSuwW4U9xqrGYz7IawEb2lT1RW6zht8NLS+RFzhIPl1FXxaKb/pbq/JTwam0SOEL+p9Hrlx0kzKV3ikZn; 25:osM6CxMTANv+SmPTAWEsF8JktUFwgMOoG1deK1ZJHbhmPSpCPVaUh7zt9UQWS4IBZTQIOEp66L+T7le0p1gsCOvs/strvsFX/mTb4gB8RSUFDyVcUbEJ44hX1OCjuGt6HFVkk4a1XNPaUYHILForH8Zb1YpxuZMJVuXJOh8Yg/4yzUI3IuS34lgtsGEvRnKYrSDGloVq3yIwJGZGXWgx4FI961sFAHIOCqKNcU3XfvnFcnhtftRmDt3czXPxJ+JWgRQfet10k8KU0GebYz31DO/eTlxFv/I0+RZmcwY38fNVePK4yNQV2OG1/5JW3SQ5kl752r37acjarjBpxlYOkw==; 31:rMrixIrKCdoXO/MIb7FSNyXgQzrjsV/gygOWQEHvFWK/EBzl1zUPLeGijONd5n3RSSpFKGMQeLgq1k9Hmm2X4AJ8AdSQRziH7CL/+CHOO7jE5qy61Qfav5uacsvNwo6R+5ravkTrFjs6WrHy/VacJETLw2u6IrEBDtae/FKp/zCiRyacn29HRZturgI4TwIN51OpsGhfAoRN1iVAWU0q/8qukcRmExC5wYVmosLiT4A= X-MS-TrafficTypeDiagnostic: BN3PR07MB2513: X-Microsoft-Exchange-Diagnostics: 1; BN3PR07MB2513; 20:qtT5UP8eSNy9LSpDy0KBsQBrjIa7dV/O2NLcWCDeqgdDb7pFWTpgNP7h4njKS9bfRbKWbbnuJ7i+W2eARnV4q4Inn+IhzwY91ssR6LUdqP7oyYQGwM55yeZHwqmK1geqApJOuW6t+vnAHxLHu+DHKaii9VAHz1HzTNOjMzIJSbrpY1UxvliclCYn+cwwg0FOHxMDWQoRv25U4WfRTqBX3tTPigVhL6DUD6M5lksKeneXMvub07pWkkwGQ016A3xkIwWzeGis2fzjEAu1n1msBFwK5VXPecuVhrtuGeQaHHL+vWZWTRCvqr9i9z4Xyf18acuMKvuOgH7hUNH2TMdzngDzlnSF10TLkXW+4DZ/yol0DniTE+kPkzF8gcMt1G55mpjxZLZPy5ZI5VM4YYQtmhNiuCSvD1etfKch3DjJrqvZt0gn+68sjLuvSnGvpj6QGaCwZyeC1Agi7qajcrce0NTzvZ6OxMnBX969QVzCQbdGiY/ePR3Kv1Idy1MHLroEsPxxiXPuI7ZCsfmJR9TDBfVq0lCa3fNEsbFZ/MvgxiqjP9AKnlXcFeSMtNh5wpjNRk1GmRV610VdC5CcaL2zCT/iohGphEiVQpWIKMiRsyU= 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)(3231254)(944501410)(52105095)(3002001)(10201501046)(93006095)(149027)(150027)(6041310)(20161123564045)(20161123562045)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(20161123560045)(20161123558120)(6072148)(201708071742011); SRVR:BN3PR07MB2513; BCL:0; PCL:0; RULEID:; SRVR:BN3PR07MB2513; X-Microsoft-Exchange-Diagnostics: 1; BN3PR07MB2513; 4:lvos2piKz36IZBKrLCgLSZdrFwRu/fX9TCFFR6ioWy8eucBn/2Q8W460+69Jj2o12FzEoEc5Wm1JO69CNdM6iiNJxPHSlqGwVb9SMXWODmCagHf/ES+Rw64mz12hvdDl8mh2045hBqFsnZNUCGpPe94mlDs4tiZGR6H/R4lP0oCxOsYkghMFZK9WwnJd/cPGCMejrLrY7rm7J0BEEiKikxqd4JiSiBe/cEzJWo7DATEN0Zb6fxgBXK0dj6ySO8X9daBsmwJYiAvCcFxUxDdGgAjQgZTZW8XavogIQns5bfjbcu4UuyvomsXi3LD3jIEf8NNmfqi5J9dRG/ESFzlcxVrpSlSWvmQkV2TLHNnwkMc= X-Forefront-PRVS: 066517B35B X-Forefront-Antispam-Report: SFV:NSPM; SFS:(10009020)(39850400004)(346002)(376002)(366004)(396003)(39380400002)(189003)(199004)(13464003)(6916009)(53376002)(6306002)(9686003)(4326008)(476003)(2906002)(23726003)(8936002)(8676002)(72206003)(966005)(8656006)(6246003)(25786009)(53936002)(55016002)(478600001)(6666003)(33716001)(486006)(47776003)(81166006)(55236004)(386003)(1076002)(33896004)(76176011)(81156014)(66066001)(52116002)(6496006)(44832011)(16526019)(5660300001)(305945005)(50466002)(186003)(7736002)(26005)(16586007)(229853002)(58126008)(97736004)(446003)(316002)(11346002)(956004)(3846002)(6116002)(106356001)(42882007)(33656002)(68736007)(59450400001)(105586002)(18370500001); DIR:OUT; SFP:1101; SCL:1; SRVR:BN3PR07MB2513; 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: =?us-ascii?Q?1; BN3PR07MB2513; 23:nK4nZsfiStwiumhaWFNDuohNbbVhVMzIgahwrXP69?= =?us-ascii?Q?AYFwctsh5Aaea/2fQ/YatsTS40JcXfh2Nmc2Sm/kquCCvFyI/CMH4Gy+FB33?= =?us-ascii?Q?Htv0TD7GZx6QJKYSA7W789seIQzIZMW5w9kyO0VDj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tyWByHi9hufsNgpXy/wlc2agafNPim0FIGlsLhKLjIWvj8w2vlCDo4tc60CrZ4nUwQ0Phdv5JuXWnsNpd1RCUUaJT8gp2uwpDyLXGUGxHVTMy0yxavzWtUZli0OBMCVAHWWnBcmb7bB5WzYWEFExHkfvbp92ZYkT24ucOR8TEBOa6T7qCeD3HsgRGVQFF/wS7osKkKdOvOyMzE81jkJln0Q==; 5:b5EvtPXITN939PYkKrFfHIIPVxj3J99uCUpePiiOhdb20BI9Xj7OoDFvPpTpgwyiV77JzhB86i+hOwTSSGG+sP+PIXmkIzBLp1YzmUtXxTTt18hraeEJZGQmbCO5hD1MgSxdpSYMoYY2fIyeQfu7AxlIPh3PyoyA1bPf/NF7Ab4=; 24:r602ovFQeDiHJ8YONhXWR7M2gVuOPf3X7r6NXgA+6lK/TCopevaERZLlGqzA11PvOutYuC4WenRwKtTlPY7pl1MgamTZrsJd41Xq+e4LAok= SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-Microsoft-Exchange-Diagnostics: 1; BN3PR07MB2513; 7:5mM4doDgnRGoHxDbHvSONdNRWpDhoK4sndtyAbB91PMN69SeV7B88E+W8IRo3UHRIY6m/ESStjjU+eT/WI9jDRyv4fuUrT5RkgK8doiwfREJtQwPOQAV4iY0pvv8RvkwrNiZJIZuj/PpZENdBnnNt8vmwSRB7Ew3HaQHeqCErPT9CMBQEMADiJnd3S6EGEr63YU0n3uhTicZwLh4eyrrHWEs/yFTyqn4Hb/8L1WxDM4hN/iPhG17IjIRedvg40lZ X-MS-Office365-Filtering-Correlation-Id: c3ad6f96-9410-4285-22ea-08d5b402890a X-OriginatorOrg: caviumnetworks.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 07 May 2018 10:08:50.1615 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: c3ad6f96-9410-4285-22ea-08d5b402890a X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 711e4ccf-2e9b-4bcf-a551-4094005b6194 X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN3PR07MB2513 Subject: Re: [dpdk-dev] [v3,4/5] test: add event crypto adapter auto-test 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 10:08:55 -0000 -----Original Message----- > Date: Sun, 6 May 2018 00:17:09 +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,4/5] test: add event crypto adapter auto-test > X-Mailer: git-send-email 1.9.1 > > Signed-off-by: Abhinandan Gujjar > --- > +struct event_crypto_adapter_test_params { > + struct rte_mempool *mbuf_pool; > + struct rte_mempool *op_mpool; > + struct rte_mempool *session_mpool; > + struct rte_cryptodev_config *config; > + uint8_t crypto_event_port_id; > +}; > + > +struct rte_event response_info = { > + .queue_id = TEST_APP_EV_QUEUE_ID, > + .sched_type = RTE_SCHED_TYPE_ATOMIC, > + .flow_id = 0xAABB, > + .sub_event_type = 0, > + .event_type = 0, > + .priority = 0, > + .impl_opaque = 0 > +}; This may break old compiler. see http://dpdk.org/dev/patchwork/patch/39398/ > + > +struct rte_event_crypto_request request_info = { > + .cdev_id = TEST_CDEV_ID, > + .queue_pair_id = TEST_CDEV_QP_ID > +}; > + > +static int > +test_crypto_adapter_stats(void) > +{ > + struct rte_event_crypto_adapter_stats stats; > + > + rte_event_crypto_adapter_stats_get(TEST_ADAPTER_ID, &stats); > + printf(" +------------------------------------------------------+\n"); > + printf(" + Crypto adapter stats for instance %u:\n", TEST_ADAPTER_ID); > + printf(" + Event port poll count %lu\n", > + stats.event_poll_count); > + printf(" + Event dequeue count %lu\n", > + stats.event_deq_count); > + printf(" + Cryptodev enqueue count %lu\n", > + stats.crypto_enq_count); > + printf(" + Cryptodev enqueue failed count %lu\n", > + stats.crypto_enq_fail); > + printf(" + Cryptodev dequeue count %lu\n", > + stats.crypto_deq_count); > + printf(" + Event enqueue count %lu\n", > + stats.event_enq_count); > + printf(" + Event enqueue retry count %lu\n", > + stats.event_enq_retry_count); > + printf(" + Event enqueue fail count %lu\n", Use PRIx64 to fix issue with 32b build target. > + stats.event_enq_fail_count); > + printf(" +------------------------------------------------------+\n"); > + > + rte_event_crypto_adapter_stats_reset(TEST_ADAPTER_ID); > + return TEST_SUCCESS; > +} > + > +static int > +configure_eventdev(void) > +{ > + const char *eventdev_name = "event_sw0"; > + struct rte_event_queue_conf queue_conf; > + struct rte_event_dev_config devconf; > + struct rte_event_dev_info info; > + uint32_t queue_count; > + uint32_t port_count; > + int ret; > + uint8_t qid; > + > + evdev = rte_event_dev_get_dev_id(eventdev_name); No need to assume it is "event_sw0" driver. You can select 0th event device for testing. If none of the event device is available then you can create "event_sw0" with vdev. > + if (evdev < 0) { > + if (rte_vdev_init(eventdev_name, NULL) < 0) { > + RTE_LOG(DEBUG, USER1, "Error creating eventdev\n"); > + return TEST_FAILED; > + } > + evdev = rte_event_dev_get_dev_id(eventdev_name); > + if (evdev < 0) { > + RTE_LOG(DEBUG, USER1, "Error finding eventdev!\n"); > + return TEST_FAILED; > + } > + } > + > + ret = rte_event_dev_info_get(evdev, &info); > + TEST_ASSERT_SUCCESS(ret, "Failed to get event dev info\n"); > + > +static struct unit_test_suite service_tests = { It is not "service_tests". Choose an appropriate name.