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 EF41FA00BE; Fri, 8 Apr 2022 09:56:55 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id DFC9F40E5A; Fri, 8 Apr 2022 09:56:55 +0200 (CEST) Received: from NAM12-DM6-obe.outbound.protection.outlook.com (mail-dm6nam12on2059.outbound.protection.outlook.com [40.107.243.59]) by mails.dpdk.org (Postfix) with ESMTP id 659804003F; Fri, 8 Apr 2022 09:56:54 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RKhfjFQqs/jm0/krBWDaTAnTb1xahYoRReAkF33i6k84tq5zRZ47FXillx8w1vgHZlvPCohzy+VX2ulV51fpUaE0G6ItMZO5EMzBy7Mcfo5498RQAvBC7sh16moD5+howOXv2Qxq8XzEnh3v4x5a+FpgIN69gIZOT5SRA9gWjqLNZqOK40zXfmEYQLBDHMTvrnacomPDVRO1Icbz0FaHvyn1cGrYNP3KaqkzY8L5ISuw2inrh7HpCnuBNW+rcXLqKR2XGw/k5Z3wOaM+xVRbFfri+1JATPE6dZ3us3FoNuxdlJgKZplxcdoZQpBJbz0BkmWIZlmBuyEyImFpYzTssA== 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=R7+AjK9N9iqmqWBsQsB7oJe+E+uUxMe2MTOfHNCr7ZM=; b=JbCEUv//mrGQc6DKcPVYi8UO5Ez69vWPNrTT9nsJR/YeN0/6VWA9VjGpG6Et+WPA1sruaw5cw+dgvKyFVkgYKbRAnV8lMaoENeiS+/VPpgLQOzG7wrt9AJ/iIKDPoSYishJPd1nag8ePe2U0q/YE9prAuoBDayq6B5ksvgVcx/pag3e/Un1RJTRgStOoyyXjAyH1M8WP76tsHz0XuzPmBja2gPlCkN/zhH78krXOXt4WEYw8Tkz5Jy25eMKdR011g4iiZYzwwbe3c7JC9N48Yk7iE9UvPmqH1q+Wv8fU6auqdljtQNao+v2vbgyyi8RKzjWejul3UKtumLh1aaiWBA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 12.22.5.236) smtp.rcpttodomain=intel.com 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=R7+AjK9N9iqmqWBsQsB7oJe+E+uUxMe2MTOfHNCr7ZM=; b=FNVIyd3d7aTPZqDySUlwKXBE1I5pPE/NYZ2nNmbaPMmheBB0QSP76pEuZvJIkgeFzDMbTSr7MBU1A8CoRHRuPXYEPj/IWlVh6gu/6JwnpTqHWz2RBT4/pFpOjl4owtfFoQU2C9wDjAK+TAJ+4iUL3nvThgutwSm3YOAhjlwGOKSd0Lv/G6ac+xDXG1zfxfVYgegvUJb3a9stvEIed9wZfJRnjUar7WM8sf5+h/HvXygSQyiC7RQKAQRCYA3Bju5WjZMVx2zL7ilSyJsG3m1QKXH8ZCyES52d5yMrVYwT+TP7corhabd92dOc452dPPaqVGqY8x9oGT2Ct8oDOswO8g== Received: from BN0PR04CA0133.namprd04.prod.outlook.com (2603:10b6:408:ed::18) by DS7PR12MB5768.namprd12.prod.outlook.com (2603:10b6:8:77::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5144.22; Fri, 8 Apr 2022 07:56:53 +0000 Received: from BN8NAM11FT005.eop-nam11.prod.protection.outlook.com (2603:10b6:408:ed:cafe::e2) by BN0PR04CA0133.outlook.office365.com (2603:10b6:408:ed::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5144.21 via Frontend Transport; Fri, 8 Apr 2022 07:56:52 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 12.22.5.236) 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.236 as permitted sender) receiver=protection.outlook.com; client-ip=12.22.5.236; helo=mail.nvidia.com; Received: from mail.nvidia.com (12.22.5.236) by BN8NAM11FT005.mail.protection.outlook.com (10.13.176.69) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.20.5144.20 via Frontend Transport; Fri, 8 Apr 2022 07:56:52 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by DRHQMAIL109.nvidia.com (10.27.9.19) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Fri, 8 Apr 2022 07:56:50 +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; Fri, 8 Apr 2022 00:56:47 -0700 From: Li Zhang To: , , , , Maxime Coquelin , "Chenbo Xia" , Xiaolong Ye , Xiao Wang CC: , , Yajun Wu , Subject: [RFC 01/15] examples/vdpa: fix vDPA device remove Date: Fri, 8 Apr 2022 10:55:51 +0300 Message-ID: <20220408075606.33056-2-lizh@nvidia.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20220408075606.33056-1-lizh@nvidia.com> References: <20220408075606.33056-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: rnnvmail203.nvidia.com (10.129.68.9) To rnnvmail201.nvidia.com (10.129.68.8) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: a83a2df4-e6d5-4c0f-2c8e-08da193557f8 X-MS-TrafficTypeDiagnostic: DS7PR12MB5768: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: 5DYzfa/8+9Bl6jt7FWxDG0l+uOrRM8AZwDKsO43FMCRXoLEi0fQLn+Ete13JF2UgvAyFlT8J2gd0yXmRLZXmbl6mgYWSXNedvF02YIOMp5qsvyPMsV6mpzqpoOxewLkhAfd6b3GYxU7Qz7IoI76kXg1eCJP3CecoT4sJWJmVAxCdULinhQgCwVSRbv7WW2INiVU30Hc3gOl6uLJ5wKU0XfUUemUKn7RBGP6vMeZ70+oGadH2VXwdwBrsJRGLrjCxL/VC6V6qWICWA5p8SJVxmzqQTK7XLtr/I5uTZjbqJ07TXj++Zyi6Ao2HBWaZJabjerC43Ek9bE1NC6ktXTG5xNXn9Kqj4HkDX5dAb73h96U8hsJE2ch+lhKALElX5rPIR+vUZ8vZOA5GMvYngIXLKiNYJEhoMnQB6y7NGBbE6SKdTX8WrZoI4mqJmJdK6dWUErRbu+PMsiX3pVQHnq6FYMIaQqsQE81Ee2XUv6KvYtz6ogWTzoY/LNvfv0nHJ/3RU0VaEyiqr3pvy2dYarzWJ1gvsIAMHFN+T45t1TcqIyCXF1CBlJOULIE6s7Y5fbwEfwmE5AEceNnKROxIIU3/z1WqWnkVn+1cSnyOdtPBHeHDgbt0shfubgZbav+Llk1sdJVDtlQNdXII56nbfy6qQg/byM2cDwe8R9R0GZdjyIjIjKbFu3iQlNmsMvfJbA1PmgkJ1LNcAMFfDqmIRuhPIg== X-Forefront-Antispam-Report: CIP:12.22.5.236; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:mail.nvidia.com; PTR:InfoNoRecords; CAT:NONE; SFS:(13230001)(4636009)(46966006)(40470700004)(36840700001)(336012)(86362001)(47076005)(4744005)(16526019)(186003)(426003)(26005)(36860700001)(70206006)(36756003)(70586007)(82310400005)(2906002)(8936002)(4326008)(5660300002)(8676002)(1076003)(110136005)(2616005)(54906003)(316002)(81166007)(356005)(40460700003)(55016003)(7696005)(6666004)(6286002)(508600001)(36900700001); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Apr 2022 07:56:52.4627 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: a83a2df4-e6d5-4c0f-2c8e-08da193557f8 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.236]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: BN8NAM11FT005.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: DS7PR12MB5768 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 bd66deca85..19753f6e09 100644 --- a/examples/vdpa/main.c +++ b/examples/vdpa/main.c @@ -593,6 +593,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.27.0