From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id CF95BA2EEB for ; Tue, 10 Sep 2019 07:16:44 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 32E961EB94; Tue, 10 Sep 2019 07:16:44 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by dpdk.org (Postfix) with ESMTP id 3D5221EB92 for ; Tue, 10 Sep 2019 07:16:43 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.0.42/8.16.0.42) with SMTP id x8A5EqoT028350; Mon, 9 Sep 2019 22:16:42 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : subject : date : message-id : content-type : content-transfer-encoding : mime-version; s=pfpt0818; bh=iScEFdjlCOzEMnsQmI/h6WCTrBjmRH4MxK53RD/ZQe0=; b=SmLeBx64LzabPBJoL2jlL5AVZuYTwPUT+X4lLvUynACpERGAbRa/vlivcUWABDkIb68X NJzuK43dAoxuwQh1w2zumMSeWslJqdMgfr4UdLOg/ilaW2hKIih06wbpALtZzM8qajZu fCoQULzfum31mUUXJcy9zFkdP9wyu0S3L7XxEmVQY2BM4Anj50zNluITt1kN2BVio8Jd MQrdzXj9tGiiVoi92A4jo87loJbrXIUWevRnXjiy5EkBFviZBCbDCEvn1Ke2kWTMIT/W NEUZnm53AGCI3CVksSkGEoN6sPnx9PIbIdKBaFDK2DoQwqQ2KhDu+B3j98H4MnE7Uqa6 xQ== Received: from sc-exch03.marvell.com ([199.233.58.183]) by mx0b-0016f401.pphosted.com with ESMTP id 2uvc2jj4a2-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT); Mon, 09 Sep 2019 22:16:42 -0700 Received: from SC-EXCH01.marvell.com (10.93.176.81) by SC-EXCH03.marvell.com (10.93.176.83) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Mon, 9 Sep 2019 22:16:40 -0700 Received: from NAM02-BL2-obe.outbound.protection.outlook.com (104.47.38.57) by SC-EXCH01.marvell.com (10.93.176.81) with Microsoft SMTP Server (TLS) id 15.0.1367.3 via Frontend Transport; Mon, 9 Sep 2019 22:16:40 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=j69mOnOJruJqHcFGfWAc2Yqd/EZtENNaq+GkyxPyQi+7AINus3CoegpF6pqEU1YSRmOSv/9rOZmuWXI59EjbIC1Fgqa8FqAfYWImvO3pewUiOrJXuC6JUe/0CVsy36Yw6Lp2h6vY+km47dpoqCTbCun9/bwzaOVQ7XXeq5UXyTRBMMdE+DEIcnUCy9+LjJbOVy2pt7xukZLb4jR2krttnc1zW1y6gGH4aIw2cjvWjgu0BzSiD8wvPSepdgCAETynRn19bKtYEq+/qgfJoz1wS3kW1hNOgOYhSuYOxbfsxaRCfAOlO02V+OovM4TVQ+1wkS/FLgJ/GBcEXznrXlX06A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=iScEFdjlCOzEMnsQmI/h6WCTrBjmRH4MxK53RD/ZQe0=; b=Z9VuSJkorae+VJezlBqXaMXF5PzYK9aWpWpZf20FAGVfoz7+VsjEQm9CD/8k/6lWp/h7UbD7ZB/ypVHDTLxD6/o6G3+ax1+J5ipnB6oSN4XXkz/pACulnEj3xiWhiCGXMcXvBckQb4BcUJP/y7IQV9pVJZdOFvLtrm+XeZZgvNvyHskWjj5UhbodZHPAbVzhLX9gpNP+4klaEM5FYUUM5WCghlMNy/Fq+m/Yk/IL3BZink9kyVjPnYFvlSF/GvTQBp+eknwc7ginvUOeWT2UHVjams7pvsW2o798zW3GV/HjgIhokjejeamngsp9d9jyRXTn9j7yzhKXsCeWodDvkg== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=marvell.com; dmarc=pass action=none header.from=marvell.com; dkim=pass header.d=marvell.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.onmicrosoft.com; s=selector2-marvell-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=iScEFdjlCOzEMnsQmI/h6WCTrBjmRH4MxK53RD/ZQe0=; b=R2D+t2j2zKEaca2YrLEC4fcT/iQci15slSxWyCtCfs6kJUPk4CVxly9jEMID1BhUSFthahaVWilH/+WCaQYS9La50nJupc5GUMHN+pgUHyLlMIC29/s0iPKJyLDjW5wBrIb5mZZDYGllSs2jBsCnR5sXWt70SBCO+3UdrSKFN/I= Received: from BYAPR18MB2424.namprd18.prod.outlook.com (20.179.91.149) by BYAPR18MB2663.namprd18.prod.outlook.com (20.179.94.86) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.2241.19; Tue, 10 Sep 2019 05:16:38 +0000 Received: from BYAPR18MB2424.namprd18.prod.outlook.com ([fe80::1d8b:430f:c74a:33]) by BYAPR18MB2424.namprd18.prod.outlook.com ([fe80::1d8b:430f:c74a:33%6]) with mapi id 15.20.2241.018; Tue, 10 Sep 2019 05:16:38 +0000 From: Jerin Jacob Kollanukkaran To: Hemant Agrawal , "dev@dpdk.org" Thread-Topic: [PATCH v2 3/5] event/dpaa2: add destroy support Thread-Index: AdVnlt6ZTwlXPpqJRn+02UqWuF0eCQ== Date: Tue, 10 Sep 2019 05:16:38 +0000 Message-ID: Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [14.140.231.66] x-ms-publictraffictype: Email x-ms-office365-filtering-correlation-id: 34cca9b1-e65c-4d1d-ca1f-08d735ae0ede x-microsoft-antispam: BCL:0; PCL:0; RULEID:(2390118)(7020095)(4652040)(8989299)(4534185)(7168020)(4627221)(201703031133081)(201702281549075)(8990200)(5600166)(711020)(4605104)(1401327)(2017052603328)(7193020); SRVR:BYAPR18MB2663; x-ms-traffictypediagnostic: BYAPR18MB2663: x-ms-exchange-purlcount: 1 x-microsoft-antispam-prvs: x-ms-oob-tlc-oobclassifiers: OLM:98; x-forefront-prvs: 01565FED4C x-forefront-antispam-report: SFV:NSPM; SFS:(10009020)(4636009)(136003)(39860400002)(346002)(396003)(376002)(366004)(199004)(189003)(13464003)(81166006)(71190400001)(74316002)(26005)(2501003)(478600001)(7696005)(55016002)(6306002)(33656002)(8936002)(9686003)(102836004)(6506007)(186003)(55236004)(53546011)(53936002)(7736002)(81156014)(256004)(966005)(305945005)(8676002)(86362001)(66556008)(64756008)(66446008)(66946007)(66476007)(486006)(2906002)(6436002)(229853002)(6116002)(6246003)(99286004)(3846002)(14454004)(110136005)(25786009)(76116006)(316002)(476003)(66066001)(5660300002)(71200400001)(52536014); DIR:OUT; SFP:1101; SCL:1; SRVR:BYAPR18MB2663; H:BYAPR18MB2424.namprd18.prod.outlook.com; FPR:; SPF:None; LANG:en; PTR:InfoNoRecords; A:1; MX:1; received-spf: None (protection.outlook.com: marvell.com does not designate permitted sender hosts) x-ms-exchange-senderadcheck: 1 x-microsoft-antispam-message-info: HSD8Uz5S+WUW0COU44kYxSdVUTQSkHeHJWz+w4aNChBFDtferOaBNQmwe6ogewVakgKd9uGtU7oGgqgpbZ8NvZDzcWE0DgZLXF5El5n2CR7rynOjdzEbH9kQpZz6iyTNAnmwjjdWbav7IJc4mlO/H+LW6FfR5ub+P0c3bfPKWM/ftFJecOG0kLXrrVd0eDGyo3cqWCJRdG4/LSOcKv9eHdGUB2l8JN5JTvQQVVeq4giRiZRmw7U8kI4QMZQg77WFtzJDHrE9RYfJYXXqPP0yh0ucbCcF1tgLpWPLOpV3SGiSbuHLdILPxpjPbLYGF/iHAs0dUWPzzaSgPB66DksX7gVNgMpRyTM5TBIJSyvPBVGT81lQcJb7zBA0rbJ2el8N+QjcMFWKhao/CS1+fnSjNkdUv0o/lhynqkLs+SbDmGc= x-ms-exchange-transport-forked: True Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-MS-Exchange-CrossTenant-Network-Message-Id: 34cca9b1-e65c-4d1d-ca1f-08d735ae0ede X-MS-Exchange-CrossTenant-originalarrivaltime: 10 Sep 2019 05:16:38.4978 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 70e1fb47-1155-421d-87fc-2e58f638b6e0 X-MS-Exchange-CrossTenant-mailboxtype: HOSTED X-MS-Exchange-CrossTenant-userprincipalname: SWPq2V6x9OiLEyOdEPv0oeX3XTz3auhLJltHa4nrr6C9CvbsRyfAV3YmGuSVDR+Bgx+ZRAu/vykHBEuZT3iIMQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BYAPR18MB2663 X-OriginatorOrg: marvell.com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.70,1.0.8 definitions=2019-09-10_05:2019-09-09,2019-09-10 signatures=0 Subject: Re: [dpdk-dev] [PATCH v2 3/5] event/dpaa2: add destroy support 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: , Errors-To: dev-bounces@dpdk.org Sender: "dev" > -----Original Message----- > From: Hemant Agrawal > Sent: Saturday, September 7, 2019 12:12 PM > To: dev@dpdk.org > Cc: Jerin Jacob Kollanukkaran ; Hemant Agrawal > > Subject: [EXT] [PATCH v2 3/5] event/dpaa2: add destroy support >=20 > Signed-off-by: Hemant Agrawal Please fix http://mails.dpdk.org/archives/test-report/2019-September/096506= .html > --- > drivers/event/dpaa2/dpaa2_eventdev.c | 35 > ++++++++++++++++++++++++++++ > 1 file changed, 35 insertions(+) >=20 > diff --git a/drivers/event/dpaa2/dpaa2_eventdev.c > b/drivers/event/dpaa2/dpaa2_eventdev.c > index 98b487603..9255de16f 100644 > --- a/drivers/event/dpaa2/dpaa2_eventdev.c > +++ b/drivers/event/dpaa2/dpaa2_eventdev.c > @@ -1059,6 +1059,39 @@ dpaa2_eventdev_create(const char *name) > return -EFAULT; > } >=20 > +static int > +dpaa2_eventdev_destroy(const char *name) { > + struct rte_eventdev *eventdev; > + struct dpaa2_eventdev *priv; > + int i; > + > + eventdev =3D rte_event_pmd_get_named_dev(name); > + if (eventdev =3D=3D NULL) { > + RTE_EDEV_LOG_ERR("eventdev with name %s not > allocated", name); > + return -1; > + } > + > + /* For secondary processes, the primary has done all the work */ > + if (rte_eal_process_type() !=3D RTE_PROC_PRIMARY) > + return 0; > + > + priv =3D eventdev->data->dev_private; > + for (i =3D 0; i < priv->max_event_queues; i++) { > + if (priv->evq_info[i].dpcon) > + rte_dpaa2_free_dpcon_dev(priv- > >evq_info[i].dpcon); > + > + if (priv->evq_info[i].dpci) > + rte_dpaa2_free_dpci_dev(priv->evq_info[i].dpci); > + > + } > + priv->max_event_queues =3D 0; > + > + RTE_LOG(INFO, PMD, "%s eventdev cleaned\n", name); > + return 0; > +} > + > + > static int > dpaa2_eventdev_probe(struct rte_vdev_device *vdev) { @@ -1077,6 > +1110,8 @@ dpaa2_eventdev_remove(struct rte_vdev_device *vdev) > name =3D rte_vdev_device_name(vdev); > DPAA2_EVENTDEV_INFO("Closing %s", name); >=20 > + dpaa2_eventdev_destroy(name); > + > return rte_event_pmd_vdev_uninit(name); } >=20 > -- > 2.17.1