From mboxrd@z Thu Jan 1 00:00:00 1970 From: Matan Azrad Subject: [PATCH v2 0/4] Fail-safe fix removal handling lack Date: Wed, 13 Dec 2017 14:29:26 +0000 Message-ID: <1513175370-16583-1-git-send-email-matan@mellanox.com> References: <1509637324-13525-1-git-send-email-matan@mellanox.com> Mime-Version: 1.0 Content-Type: text/plain Cc: dev@dpdk.org To: Adrien Mazarguil , Thomas Monjalon , Gaetan Rivet Return-path: Received: from EUR02-VE1-obe.outbound.protection.outlook.com (mail-eopbgr20059.outbound.protection.outlook.com [40.107.2.59]) by dpdk.org (Postfix) with ESMTP id 479F4107A for ; Wed, 13 Dec 2017 15:29:44 +0100 (CET) In-Reply-To: <1509637324-13525-1-git-send-email-matan@mellanox.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" There is time between the physical removal of the device until sub-device PMDs get a RMV interrupt. At this time DPDK PMDs and applications still don't know about the removal and may call sub-device control operation which should return an error. This series adds new ethdev operation to check device removal, adds support for it in mlx PMDs and fixes the fail-safe bug of removal error report. V2: Remove ENODEV definition. Remove checks from all mlx control commands. Add new devop - "is_removed". Implement it in mlx4 and mlx5. Fix failsafe bug by the new devop. Matan Azrad (4): ethdev: add devop to check removal status net/mlx4: support a device removal check operation net/mlx5: support a device removal check operation net/failsafe: fix removed device handling drivers/net/failsafe/failsafe_flow.c | 18 ++++++++++------- drivers/net/failsafe/failsafe_ops.c | 34 ++++++++++++++++++++++----------- drivers/net/failsafe/failsafe_private.h | 10 ++++++++++ drivers/net/mlx4/mlx4.c | 1 + drivers/net/mlx4/mlx4.h | 1 + drivers/net/mlx4/mlx4_ethdev.c | 20 +++++++++++++++++++ drivers/net/mlx5/mlx5.c | 2 ++ drivers/net/mlx5/mlx5.h | 1 + drivers/net/mlx5/mlx5_ethdev.c | 20 +++++++++++++++++++ lib/librte_ether/rte_ethdev.c | 28 ++++++++++++++++++++++++--- lib/librte_ether/rte_ethdev.h | 17 +++++++++++++++++ lib/librte_ether/rte_ethdev_version.map | 7 +++++++ 12 files changed, 138 insertions(+), 21 deletions(-) -- 1.8.3.1