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 8551044155; Tue, 4 Jun 2024 14:12:57 +0200 (CEST) Received: from mails.dpdk.org (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 389754369F; Tue, 4 Jun 2024 14:12:39 +0200 (CEST) Received: from NAM02-BN1-obe.outbound.protection.outlook.com (mail-bn1nam02on2060.outbound.protection.outlook.com [40.107.212.60]) by mails.dpdk.org (Postfix) with ESMTP id 363BC4369B; Tue, 4 Jun 2024 14:12:38 +0200 (CEST) ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=RuRPOr/0iBKRTWRyUxmRd5BeHizUyNLN/pzudftT8Kzj08lfpFEqj24ieEH3VEwXkfOA0rHHJIZX7WSdMX+ZUCVgHOgklnEjhf7Kcayq6d4/2nf8Aqi47iZdGEflxpbxOctgFh5HvNfT4hEOGHpY4hNYXXpYaq1XGKjNjW4UzfwBTY/6Ffr40hG9X0elA2uzuKdrK5Tcd+Okod7aVozTxXJ8FOxcJ2k2PmLAF7+Q6ciIySJvC6pFpyzTXqso0yJ0Sz3aXCyykwFeXqAYB3gtK8AtciSVJBr9hLKHojMdVTAnvrHFuqcACbVMK+z99XbCvxUtdm35rP7CoqPH6rgQ6Q== 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=Gc3fxfs8PynGr6viJ3O2gwYhXePpk5/KXwFQNgVxLOM=; b=nzstE0p1Yqgk3P1Diptsda60+mZ8XGY2KKjr/vwmgVsBH2V2I47CJsC2/RUnd7ivL/Li4PKMOeMtEwf6ri1lkfya2FHYcTKQJ02aXQXQ+QvOIjOpVFgiW9Ekm25vgpGvwTP2LU33Z8lFEPens0D8ti26eQ6/cJlL9C1p72Bzm0DT9pDYDR00w+MmNPb98ihQ7GtvjWTGpecOAI9rBZ7BC88RhEW2+1ln13A62jB5t9S4q6uv5rgqzSM0SxhyRmsSnJxMS4rjCQ9SwU14y+OvEffQ2igIyGuMKGBctqCVypy8I/uhMdU7AxXAEyMfCPN+UQtL2XjPxyJAEuOixZOulQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=dpdk.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none (0) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=Gc3fxfs8PynGr6viJ3O2gwYhXePpk5/KXwFQNgVxLOM=; b=5bTV7e+038CNsZ0rVm7e1ToOXVLlppgpTZOyR5lA0IUAdHEfzv2s+lJFpVAqXxKW25vOXW+/8cMSh6/oGt1xaKlzTFS3yZxXpljU5EQQM3s2QhIhEhIAIYaofAnicwtzsiyBPd+4P+suEGeQYh3Px/EarneoECM4b0yFr7P5tfw= Received: from BL1PR13CA0387.namprd13.prod.outlook.com (2603:10b6:208:2c0::32) by MN2PR12MB4061.namprd12.prod.outlook.com (2603:10b6:208:19a::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7633.31; Tue, 4 Jun 2024 12:12:34 +0000 Received: from BN3PEPF0000B371.namprd21.prod.outlook.com (2603:10b6:208:2c0:cafe::91) by BL1PR13CA0387.outlook.office365.com (2603:10b6:208:2c0::32) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7656.14 via Frontend Transport; Tue, 4 Jun 2024 12:12:34 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by BN3PEPF0000B371.mail.protection.outlook.com (10.167.243.168) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.7677.0 via Frontend Transport; Tue, 4 Jun 2024 12:12:34 +0000 Received: from cae-Lilac-RMB.amd.com (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.35; Tue, 4 Jun 2024 07:12:32 -0500 From: Venkat Kumar Ande To: CC: , Venkat Kumar Ande , , Selwin Sebastian Subject: [PATCH v3 05/25] net/axgbe: disable interrupts during device removal Date: Tue, 4 Jun 2024 17:41:37 +0530 Message-ID: <20240604121157.3052-5-venkatkumar.ande@amd.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20240604121157.3052-1-venkatkumar.ande@amd.com> References: <20240507124305.2318-1-VenkatKumar.Ande@amd.com> <20240604121157.3052-1-venkatkumar.ande@amd.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN3PEPF0000B371:EE_|MN2PR12MB4061:EE_ X-MS-Office365-Filtering-Correlation-Id: 0884004c-55e3-4be2-3112-08dc848f9dd6 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230031|82310400017|1800799015|36860700004|376005; X-Microsoft-Antispam-Message-Info: =?us-ascii?Q?ZyQriINoIs0cvMMK5mgi593etwJKcsNj/7CVn5TfUhXFDyQWUjCGtL0twlpy?= =?us-ascii?Q?v+FlFu1kqNwQRNTZythV6f2Owh7t3C6Gig9EgWDXu3dFuLk5AxEoSICDbSr8?= =?us-ascii?Q?RQIJYFELbVtw2E3WuQCD9boZ+pNYJWhUk/Ve4E4e0Yy43vk10fuI8md2o5xS?= =?us-ascii?Q?m3clcdBIBvyfNi4Nin6etTfXSfxwcOMwILkezL+8U/J44Hgr94xB/kruLT5D?= =?us-ascii?Q?I+t01yEeNI1Fc4IcsEMO5rN9eiXL3BxwpfSUfTDymOmQvt+2tUksZc4NOw7Z?= =?us-ascii?Q?OziyYlG3Da+HnCrd6H0GHX6YN8hFE03ywztkoExIuori8UX8CMyWwT/6hOjG?= =?us-ascii?Q?dRrPuEgIDgdJzlaTPddVXgH2PAaj5IKBT/O5v0rNdLN7dDbb+xkb5WEeklK1?= =?us-ascii?Q?lMU9IsJxVN35L7LvrIud+t/oAOdaJ+WJjPwXZzL+hFoJQ1OYrbvVXo5sn1j/?= =?us-ascii?Q?i/hTriit2o2Tg3aP3TfX68hZB85r04Jw3/7OxW1QDNXEZn17FiRA9PxmV5No?= =?us-ascii?Q?4IB17usu/Xp9PRcXs5zlR8UvN9jhuBOZkCXSg55wJOl3uwmJaf/yagdsyhfM?= =?us-ascii?Q?zW9zVOlY5iy0+fEiYccVFgzQInCMBLjQrw6DNtpvR6AVjsCkVy1x0+pcoDg1?= =?us-ascii?Q?1nV0jgy+yKnhMU9S5AN8qfobz1fUyj/xFWQ+lbnuZ283WaWuU6ijYl6TLQbk?= =?us-ascii?Q?HkkE1BLkIhlGZDAmpnniAyCg3tZYw2LmmN1c6RwNBejMwLfU8It4+1BWB+9y?= =?us-ascii?Q?PSqbWeNa6zx8mSmDNzzJxLHoBNx1TOGKj9N4Z/TJmEiHVpBqdX9atYBjBY8/?= =?us-ascii?Q?iKpB8exKF2bZ9A+s5a2bLRv7JE2wvhpvj/zghSvL6I76nPA0BRIcmG390Xm4?= =?us-ascii?Q?xY5ebLBsH5qFU6c40yiyNAokpoVF2ZJbntM8F53jFFdavzF6dLfvmD58UW3R?= =?us-ascii?Q?Tzj4xhLksBHUtZJOqqnooMKHGnvJyBo962XrzqIR5MrhkEoRvUGrMHJxvlk5?= =?us-ascii?Q?Oov9ADzQfpl1rmEQ2x27iMhBrG8VrGih/qQyTEhVXuvM9e33VaK5II9WFx8r?= =?us-ascii?Q?+Qck5w+7/QwMfZR9ozURmCkc6/BK0lxPj1Lr/jw+P032VvKQ5sGge3qTijuX?= =?us-ascii?Q?Pb5wjoBhpslgvjgBpQKUgrVvsYttDF7NieHUd8VkXDin2dS7YCdtNpeMmwIL?= =?us-ascii?Q?2g4kcp6a/noRD1HtB8JuDkiCRfRtM32eV1PJcdWsycIKgFabnk3FoTEz9frU?= =?us-ascii?Q?EZ2eHf/RoaSjNVsF+s4eSNEmfjFLYfBDiaPTK6XNARDWZXW/7vt5ZJtgQbav?= =?us-ascii?Q?t14SF1fvfZFPVFCsinZBw2uAf7XXJhaFmmS1YwxpgyyBb8tOtamxYO2yi1i8?= =?us-ascii?Q?xBXeExY/ogSIcA/yQ3VuT6RWuWcl?= X-Forefront-Antispam-Report: CIP:165.204.84.17; CTRY:US; LANG:en; SCL:1; SRV:; IPV:CAL; SFV:NSPM; H:SATLEXMB04.amd.com; PTR:InfoDomainNonexistent; CAT:NONE; SFS:(13230031)(82310400017)(1800799015)(36860700004)(376005); DIR:OUT; SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 04 Jun 2024 12:12:34.2549 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 0884004c-55e3-4be2-3112-08dc848f9dd6 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d; Ip=[165.204.84.17]; Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: BN3PEPF0000B371.namprd21.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: MN2PR12MB4061 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: Venkat Kumar Ande Hardware interrupts are enabled during the init, however, they are not disabled during close. Disable all hardware interrupts during close operation to avoid any issues. Fixes: 9e890103267e ("net/axgbe: add Rx/Tx setup") Cc: stable@dpdk.org Signed-off-by: Venkat Kumar Ande Acked-by: Selwin Sebastian --- drivers/net/axgbe/axgbe_ethdev.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/net/axgbe/axgbe_ethdev.c b/drivers/net/axgbe/axgbe_ethdev.c index dd681f15a0..e5d8f7db02 100644 --- a/drivers/net/axgbe/axgbe_ethdev.c +++ b/drivers/net/axgbe/axgbe_ethdev.c @@ -2411,12 +2411,14 @@ static int axgbe_dev_close(struct rte_eth_dev *eth_dev) { struct rte_pci_device *pci_dev; + struct axgbe_port *pdata; PMD_INIT_FUNC_TRACE(); if (rte_eal_process_type() != RTE_PROC_PRIMARY) return 0; + pdata = eth_dev->data->dev_private; pci_dev = RTE_DEV_TO_PCI(eth_dev->device); axgbe_dev_clear_queues(eth_dev); @@ -2426,6 +2428,9 @@ axgbe_dev_close(struct rte_eth_dev *eth_dev) axgbe_dev_interrupt_handler, (void *)eth_dev); + /* Disable all interrupts in the hardware */ + XP_IOWRITE(pdata, XP_INT_EN, 0x0); + return 0; } -- 2.34.1