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 9DB8CA00BE; Tue, 19 Apr 2022 18:19:09 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 7BBCB4068E; Tue, 19 Apr 2022 18:19:09 +0200 (CEST) Received: from mga02.intel.com (mga02.intel.com [134.134.136.20]) by mails.dpdk.org (Postfix) with ESMTP id 3FCA540687 for ; Tue, 19 Apr 2022 18:19:08 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1650385148; x=1681921148; h=message-id:date:subject:to:cc:references:from: in-reply-to:content-transfer-encoding:mime-version; bh=ft92OwPk3mWgJVV9JIR1FtcgB96hEr/nak+RrSZ/2E8=; b=I6EFvT9bJMKM8bAc5pioh0IRkLyCWBh3I0cM7/sWaThwvGxOWMzBhAuw LcdL3yQB8XRMPewGYIoG7SEEYapB7JzNUITmvvmCawN+5S9mtk+ZgHKLy ZS2IiqrkMWHWitUab7skzNNftzz+6Bcq7NHS1xbZjmn9XPBZEF90yt8ka TBxxDkVITWkbY7/BTNapTuQfQe6V/Ml0FYJJL3+zquoeh/M3tHALoIQsi jtrt6TV50htH+M2yldOineNhgtvIA4QHqwhkS1qn/FMHaj6la55n7P4+W EdndDL/okiLUoUm7zLFBduFiEdYxjdpEQoZVJKv+wwXzzdv2kQepqEK0f g==; X-IronPort-AV: E=McAfee;i="6400,9594,10322"; a="251111797" X-IronPort-AV: E=Sophos;i="5.90,273,1643702400"; d="scan'208";a="251111797" Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga101.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 19 Apr 2022 09:19:07 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.90,273,1643702400"; d="scan'208";a="727127329" Received: from fmsmsx601.amr.corp.intel.com ([10.18.126.81]) by orsmga005.jf.intel.com with ESMTP; 19 Apr 2022 09:19:07 -0700 Received: from fmsmsx609.amr.corp.intel.com (10.18.126.89) by fmsmsx601.amr.corp.intel.com (10.18.126.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Tue, 19 Apr 2022 09:19:06 -0700 Received: from fmsmsx607.amr.corp.intel.com (10.18.126.87) by fmsmsx609.amr.corp.intel.com (10.18.126.89) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27; Tue, 19 Apr 2022 09:19:06 -0700 Received: from fmsedg602.ED.cps.intel.com (10.1.192.136) by fmsmsx607.amr.corp.intel.com (10.18.126.87) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2308.27 via Frontend Transport; Tue, 19 Apr 2022 09:19:06 -0700 Received: from NAM11-CO1-obe.outbound.protection.outlook.com (104.47.56.169) by edgegateway.intel.com (192.55.55.71) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2308.27; Tue, 19 Apr 2022 09:19:06 -0700 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=iqaMu7oJuuHDze12FCevl6IedM3dwDL6N3ABe0LXvqlj+jB1RJrZ76I/oYHCeL05YPx5jCLf1X1YlZVQT+zvHsuIvkL+GiG7/iPs1Qj1KoWaECnkWOiRaTyVBh4uygz3MWVCiI3qXyL/uQR74B9vBYGTNyKXLnY4/4gamhZ05Gh92ZAlHZksiat0MwLINeDc9x07NLr2BqlA4gtw4+1zbAIxsa9NYTMvDLD0cUO3b7cmI2WcRWwp3sr9s8f7VDmkVSmvQIt9MMfI3wxGCblnCaGzrM8t+yDC2aqB/0uqErCo5l4v41xK/LxBmBJok1zLz1KEpzbmrTjd906c01VjjQ== 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=ut7a5ssU+28gPjqiqXgFQ0bsU6zC/hBuG9EUBxvLG1A=; b=aD4yuQ+U6JaGHAXKwYJJwKD8ZRsCmb6R/mybnDB5eQEcscb8zojG+dCKiPH07fcqmQY8EPLxsyiHqSV9x2v3xA3ldJccNCId9lg1VikXEnXI64iAm6q9OyCDcE0Z7im7bZ6M9AoeO2pnjsqf3kNOe2/W1w9mz1uhfKQ5CEgbvXCi7H+XdX/Xps8wHH79nQODnDHfGXed29e0fvgZv4vzs2nDYH2Gbf4FKCYx8R/IquLPto1ndHTQI+WB+FOTQoOyv6LegUjyJnTlIxLzYXGSGS6vfhXsxnuT13jMukE+mUTYkPVCzW94v/zU7YPVQKipbbcPwFcuFgXdunFPuJztjw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=intel.com; dmarc=pass action=none header.from=intel.com; dkim=pass header.d=intel.com; arc=none Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=intel.com; Received: from MW4PR11MB5872.namprd11.prod.outlook.com (2603:10b6:303:169::14) by BN6PR11MB1938.namprd11.prod.outlook.com (2603:10b6:404:105::11) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5164.25; Tue, 19 Apr 2022 16:19:04 +0000 Received: from MW4PR11MB5872.namprd11.prod.outlook.com ([fe80::d55d:28c1:bfab:3dd]) by MW4PR11MB5872.namprd11.prod.outlook.com ([fe80::d55d:28c1:bfab:3dd%5]) with mapi id 15.20.5186.013; Tue, 19 Apr 2022 16:19:04 +0000 Message-ID: <23dce916-d7fd-7554-41d0-624a9bbb0980@intel.com> Date: Tue, 19 Apr 2022 17:18:58 +0100 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:91.0) Gecko/20100101 Thunderbird/91.8.0 Subject: Re: [PATCH 3/5] app/test: close dma devices during cleanup To: Bruce Richardson CC: References: <20220408141504.1319913-1-kevin.laatz@intel.com> <20220408141504.1319913-4-kevin.laatz@intel.com> From: Kevin Laatz In-Reply-To: Content-Type: text/plain; charset="UTF-8"; format=flowed Content-Transfer-Encoding: 7bit X-ClientProxiedBy: LO2P265CA0354.GBRP265.PROD.OUTLOOK.COM (2603:10a6:600:d::30) To MW4PR11MB5872.namprd11.prod.outlook.com (2603:10b6:303:169::14) MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 5ae2890d-09cc-4fea-ad5a-08da22205215 X-MS-TrafficTypeDiagnostic: BN6PR11MB1938:EE_ X-LD-Processed: 46c98d88-e344-4ed4-8496-4ed7712e255d,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: qKHfb6yDADA6Ze9nklg/S0btX3qEPTs6GFcObhVGYNCG0sMe8uPxSluOZYQeNKWcvCjZLE3T99u0lqdOyxvoMRZmZFMzpciGA36ftXnjBRUcaQ7fNBzalrtlkLCs0zHZoi+TbrIjVLp7RgzG0+i6t20JgT1enOFJl2VXR4BwoHvcmmCG1GlgFbyAXSTzdYd0RK3AfqM9r4cDTNOhmh1o8omtZNhVxZAviQ57CLaHSKnMnz2JVsS2HxZ4pkYz1v6/PhH+rC/pfn8NOhHMzWlHTfXi7b/oV2VsUDCmP8YSWrLwlXjyDqyYKVgIjBgCVq5MjwShjdPBf/wKzQTDZ7rqGSTeh/tebjaljeyMjvuCmFtShjRNvwttqkKBOfkCeO/GB/odAfKk4dknbjtwqdrlMa5Fof6S0pRQhLU8favzp88zkyINDKY2qaE+bkSJfbUf7Cqx1+Q26RDH63r9v9i6OxDn/9jLCuqz8hooNellNVZN6MrjzCPA3R6Kfn/ewEucU9iqlSSQ3VGCvWqAmmxzr74hjgZ03D7fGDjsZ8h+KMF7O3Mb6XWvv5yQGoWaGPt5lzn/fFIkdUzq+NZhVxflkjZyDMhSAQkFeqnjYtdZDanfKuxnMMF3RKa3bhrNiX3ntIkboBF8Eb5Gag4fdZkl/unshaNo7pAUEae+jEsKWd619pMv85vYtaHG9dYz6d+Xzrx5EpcJc7wugG9+oBDZSI+4gKQhQDLOXpBEcFXRrWlUgv0NQxWoc+VQvHU5mq4w3Cq86R8S9n5h700xUrZ6dB3ehPQj/u19INpv2pflkhHvBUISLs9Xh9mvIHcTHZ4E66YehVQHXXMWPIXtVkDJhA== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:MW4PR11MB5872.namprd11.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230001)(366004)(2616005)(83380400001)(6636002)(31686004)(37006003)(316002)(36756003)(5660300002)(66476007)(186003)(66946007)(6862004)(6486002)(38100700002)(86362001)(6506007)(26005)(8676002)(66556008)(508600001)(6512007)(44832011)(966005)(4326008)(53546011)(6666004)(82960400001)(8936002)(31696002)(2906002)(45980500001)(43740500002); DIR:OUT; SFP:1102; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?cVE0a2tzcGNpR0dWV3NZR2FLZEZSZnBlTnQ3WXpYbi9lQVV4ZTN2ZURLQzhm?= =?utf-8?B?bzJPWEVDNHUvODhoTjJsT3VWVWZrVVNZMjI0U3ptdFI5L2VyMzlZamJpeXpP?= =?utf-8?B?UlNRbXFYa1NoSUIyc2hKMjVUanVTcTZGdEVTN09iR3F6THNMWlF1Q1lmbi9B?= =?utf-8?B?YXFnYmRaSXlqSVl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UEl2UWk2?= =?utf-8?B?SXNvS2UxYlM4cmg2bEJLaGx4N3I0RjRBQ21qczRUMEpUTkdMN3lndHhucXVh?= =?utf-8?B?U0w1cDZCMW9WcThkT29MK2QrZmJuZ0doR2IzejZRQnJxV0xDV3AybUR4N2NU?= =?utf-8?B?eVB5QWFqc3JDVmhoUC93enozbzk5RUVwWkYvUUZFK0NlUlZsbGcxdW1rckk3?= =?utf-8?B?c1I1MDZoRnVWRW9tekhITkxPL3Yxdkw2Q1cweWZyOFhXWGNlb1FPMXZETFdX?= =?utf-8?B?M3IzZ3FHVitkY0wyUDYzd1BaQUt2aFdDZFZKREVtVnBQQldSb2xUUlM3ZEsx?= =?utf-8?B?Q2FtcjExeFVVWkhoazkwOW1CaXNkZHlHdDNDNUs3ckRWck92RmkzYUNpRlNX?= =?utf-8?Q?ocvCsG62bmHlMbD4=3D?= X-MS-Exchange-CrossTenant-Network-Message-Id: 5ae2890d-09cc-4fea-ad5a-08da22205215 X-MS-Exchange-CrossTenant-AuthSource: MW4PR11MB5872.namprd11.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 19 Apr 2022 16:19:04.3420 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 46c98d88-e344-4ed4-8496-4ed7712e255d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: ugP1CvgZL4ZsyKHcRiP01hNrEZ7fGFagne16TlVqT1/nPqiSLFS/q+k/FU/aCQoDW+DFpPfVail3cP4myDt7oQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BN6PR11MB1938 X-OriginatorOrg: intel.com 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 On 08/04/2022 15:55, Bruce Richardson wrote: > On Fri, Apr 08, 2022 at 03:15:02PM +0100, Kevin Laatz wrote: >> DMA devices are created during PCI probe of EAL init. These devices need >> to be closed in order to perform necessary cleanup for those devices. >> This patch adds the call to close() for all DMA devices. >> >> Signed-off-by: Kevin Laatz --- app/test/test.c | >> 6 ++++++ 1 file changed, 6 insertions(+) >> > Just to clarify the situation here - on EAL init, all buses are probed and > all devices initialized. On eal_cleanup/rte_exit the inverse does not > happen, then, i.e. all probed devices on all buses are not closed, right? > This would seem a better option than requiring each application to manually > close all devices even if it never used them. However, it is probably a > bigger and more complex change. +1, precisely. I've prepared an RFC to explore option of adding bus cleanup to eal_cleanup() to start a discussion on that option. https://patches.dpdk.org/project/dpdk/patch/20220419161438.1837860-1-kevin.laatz@intel.com/ BR, Kevin