From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 0B74BA0543; Mon, 6 Jun 2022 13:21:58 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 3FAFD427F6; Mon, 6 Jun 2022 13:21:49 +0200 (CEST) Received: from NAM04-BN8-obe.outbound.protection.outlook.com (mail-bn8nam04on2048.outbound.protection.outlook.com [40.107.100.48]) by mails.dpdk.org (Postfix) with ESMTP id 6A705415D7; Mon, 6 Jun 2022 13:21:48 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=LADH1g9GXwIYfpjtlTLAgQ1DstD98HCtB8G/Bvaszgc33Mn6tUdEQLmnTC/59mO1R2GFrMe+FUPHgdhyeQehe6mJcwpM2I/xj/NKLkknLdO/w7nh8Y6NwPzdvxmg5yGOydZwxupQzd9FDx4uM0zZ1xsN6WZ/Irkacst+wOvJVu4qRB5VDXzYgUsiVfnUeuJwurhwXufh6NKdAxInO/EgIMvYpX+Rnc6psvGXeD5Ugsv1FRMqfdSDyG/pDJyOaIRG1ANzuizn0zINn85r1LPRtMkBTFPbw9dUrgM6GJJWk3Ah690BT4rsGV9nHZbtYPYlsMAqhCmRQeSdIqLnDZbiZg== 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-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=ku5enp3M7+FFPZGu5+36dOOtXzINvNqVxQhBBD2BkkY=; b=EsyTlzEjjSMribHNPAeRH2KL8rYa1SvuSO9/6Q07pudQuJPhx1+qI4S4EeTaZVVav7rQyQzBBPKsowJNeGb0kz/YLFPyM6tkHNMkJsZ0mU4EU6EpY6SCR574YT175yJvC5Hb0OnCtoDGofUPF+7XFXvLC1lPMpImhRrW3pDQ31vfrduXJoYMoIQnb7C/7Z5g4Hkez/3Jbenvnn8odT4zpjfL/F0jj8R3F+MShxIIPVliOatq/JMrLkbFUd1wnr+CYjPEKBDo+0fsVdOqLmAtyyYXi3IYg2IWkWvLh1V/MDjqDARC2opHKIIG2eom7O/dweP2BVefaiACTRyBVzDCVQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.238) smtp.rcpttodomain=dpdk.org smtp.mailfrom=nvidia.com; dmarc=pass (p=reject sp=reject pct=100) action=none header.from=nvidia.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Nvidia.com; s=selector2; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=ku5enp3M7+FFPZGu5+36dOOtXzINvNqVxQhBBD2BkkY=; b=Tb4xzBTStu53UBhZ37U4F4bUovwE1Xvl6NrEU1eToGBwXrNX6R9KUPrKX9sAsMrZYiGJpVgOsH39QtFRlanPenDPdO7NV2OTF5PkieG42N0Kg6sNoQ5OofMPJP0aRhVWql0xEcZpQ0uyHZHlfcbMLWHaGy4RN8hJDgKK6EOIwLV3AxnGg8vfZYK3XIIWF7pWKmEWBZYdH1gPqUG/NLUXXuURwcSgOTFwtUgjCOJGpiO8OlKHaDM+vOPES6AGMWHnu8yOjNYtg/+tEbOFp++YlGdPPnrB6yiZS/FPFdqmidXSZnhW+bZivz2uIHIJ+0qXheDq9D4qwVTZxQZo0tFTyA== Received: from DM5PR20CA0006.namprd20.prod.outlook.com (2603:10b6:3:93::16) by IA1PR12MB6044.namprd12.prod.outlook.com (2603:10b6:208:3d4::20) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.17; Mon, 6 Jun 2022 11:21:45 +0000 Received: from DM6NAM11FT012.eop-nam11.prod.protection.outlook.com (2603:10b6:3:93:cafe::3c) by DM5PR20CA0006.outlook.office365.com (2603:10b6:3:93::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5314.19 via Frontend Transport; Mon, 6 Jun 2022 11:21:45 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.238) smtp.mailfrom=nvidia.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=nvidia.com; Received-SPF: Pass (protection.outlook.com: domain of nvidia.com designates 12.22.5.238 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.238; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (12.22.5.238) by DM6NAM11FT012.mail.protection.outlook.com (10.13.173.109) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5314.12 via Frontend Transport; Mon, 6 Jun 2022 11:21:45 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL105.nvidia.com (10.27.9.14) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Mon, 6 Jun 2022 11:21:44 +0000 Received: from nvidia.com (10.126.231.35) by rnnvmail201.nvidia.com (10.129.68.8) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.986.22; Mon, 6 Jun 2022 04:21:40 -0700 From: Li Zhang To: , , , , Maxime Coquelin , "Chenbo Xia" , Xiaolong Ye , Xiao Wang CC: , , , , Yajun Wu , Subject: [PATCH 02/16] examples/vdpa: fix vDPA device remove Date: Mon, 6 Jun 2022 14:20:40 +0300 Message-ID: <20220606112109.208873-4-lizh@nvidia.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20220606112109.208873-1-lizh@nvidia.com> References: <20220408075606.33056-1-lizh@nvidia.com> <20220606112109.208873-1-lizh@nvidia.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.126.231.35] X-ClientProxiedBy: rnnvmail202.nvidia.com (10.129.68.7) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: b2ed3d65-636a-41c7-8d61-08da47aebd4c X-MS-TrafficTypeDiagnostic: IA1PR12MB6044:EE_ X-LD-Processed: 43083d15-7273-40c1-b7db-39efd9ccc17a,ExtAddr X-Microsoft-Antispam-PRVS: X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: yezzAGoYj8gN/khoEeLaC5dLYQ+EKb/GtPm71V3209A9OUE+udQBZSu2zYu9Fp0UYqbzvu1W+s38d8c+5GzlhVvOg7l0r5YC90Je01vzg7gqAAqygRDa8gqYuTpxGsFC0KM6azqkSkESqBVEf5cuE1OXfNJmSa/CTvvTdA7mEC1Ooft9A2O9dGW19Nb2cOwoKUHkRkP4LgE6KLs22zE7SBjK7y+zxFruZmAVIidEHcoAda54i2s9O/k55e0vCCMkpHRyzEexkkbLViaMEIvmb2otwQmXk0UYtXxkzQhhgk1GznBv6bBzeoCeU5sbME3mexuMQOq0LTmy9LC4j0wVqfL3t5p05KySTJbPoL/tcvw45nsADHAe/wwGhfGzSK3u6Dgd5A5b4dSX01Dsojo5nZQqiP3tyE6df8xNiH+ozNTbaGQBxHPL/o+ud/9uGqgn36xxWjXGVj/d1EhKn+F8XCwqqJ32hB3Hz7v/xVgv8gm+5Wi2PFc/Tqr9QYwiEJcLqZxoWE4VhWpF2XKrBLg2K17cE4GQa5CT30LJjQD3nK3MrAGF78tJo9SHrOQcwNhNauqfQRDkiVG4R789B2+vhIM2uv+nQNeDEnHQXcUTS/Uw73fxWkGGaHyXQVA4zOr1K+UsWZsyHfm6Z+1xU91zWihsZ9zMm1ad6EEBoXly+yQ6VMQpt+3scc/VgYo3PRGkFzRcBsXSOljCNftf9LE5cw== X-Forefront-Antispam-Report: CIP:12.22.5.238; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE; SFS:(13230001)(4636009)(36840700001)(40470700004)(46966006)(7696005)(316002)(86362001)(81166007)(508600001)(82310400005)(36756003)(2616005)(356005)(36860700001)(186003)(70586007)(4744005)(1076003)(70206006)(336012)(426003)(54906003)(110136005)(4326008)(8936002)(55016003)(40460700003)(8676002)(5660300002)(2906002)(47076005)(26005)(6286002)(16526019)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Jun 2022 11:21:45.1045 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: b2ed3d65-636a-41c7-8d61-08da47aebd4c X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[12.22.5.238]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: DM6NAM11FT012.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: IA1PR12MB6044 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org From: Yajun Wu Add calling rte_dev_remove in vDPA example application exit. Otherwise rte_dev_remove never get called. Fixes: edbed86d1cc ("examples/vdpa: introduce a new sample for vDPA") Cc: stable@dpdk.org Signed-off-by: Yajun Wu --- examples/vdpa/main.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/examples/vdpa/main.c b/examples/vdpa/main.c index 7e11ef4e26..534f1e9715 100644 --- a/examples/vdpa/main.c +++ b/examples/vdpa/main.c @@ -632,6 +632,10 @@ main(int argc, char *argv[]) vdpa_sample_quit(); } + RTE_DEV_FOREACH(dev, "class=vdpa", &dev_iter) { + rte_dev_remove(dev); + } + /* clean up the EAL */ rte_eal_cleanup(); -- 2.31.1