From patchwork Tue May 14 17:59:57 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Asmaa Mnebhi X-Patchwork-Id: 1935122 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@legolas.ozlabs.org Authentication-Results: legolas.ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=185.125.189.65; helo=lists.ubuntu.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=patchwork.ozlabs.org) Received: from lists.ubuntu.com (lists.ubuntu.com [185.125.189.65]) (using TLSv1.2 with cipher ECDHE-ECDSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by legolas.ozlabs.org (Postfix) with ESMTPS id 4Vf40839fhz20dM for ; Wed, 15 May 2024 04:00:39 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=lists.ubuntu.com) by lists.ubuntu.com with esmtp (Exim 4.86_2) (envelope-from ) id 1s6wS0-00064y-BO; Tue, 14 May 2024 18:00:32 +0000 Received: from mail-co1nam11on2078.outbound.protection.outlook.com ([40.107.220.78] helo=NAM11-CO1-obe.outbound.protection.outlook.com) by lists.ubuntu.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from ) id 1s6wRx-00063S-Tf for kernel-team@lists.ubuntu.com; Tue, 14 May 2024 18:00:30 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=Mx/yyYJowZtz+BPrgiMUkxkBA9QxCSEoyZFFyIx5zJoFzkR4Y+yyGhea/cyO7HV2UrCOiIzpFioEMydV3bhVnllMjNftdtmQW37wSf/4mhbbS12PAQQWbHVNr0s37BjkWdNA77bP08ENKHFQoPGrFrCKLCW3EUwmREdOZCnV78Qgu9WcRpcH6hZ37VSfPjzVzQblBUE5l7SHYUro5h837XXuhWXL4a5kGaWQCZpnkwlrfSQg9oiWpr0ggeKN+c1NTpHJlvXd5+60lcO2HIt7xV2c11ZJZ9hZbqwUbQ2IFwnwAJ+hUU04nHPrnvC3FjymlHs5xr2j7PW2Gd6qsXHu2g== 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=+Q/rgeG0D/QX68ScKb/U84D+ON72zpfQ//8zwYacYzs=; b=TW7vxptxfFgEXUqETCynAJZoR++NFG2lGXsU/PWYiakD0eVFPQFQn7Py5vFSocFk6kdGk0Yc7FgILr7rOAKJPHYclz1NtmGLRQMI05p4sNc/lirSCOc+PPQcvdP3QWVoKaX6mC3pwWC2vBpcD1EQ7YRwjBxxIQ0YfP2FyBXCl50AfjxnybEhcDsb+mudh4jIfu/DymF0q5e0dAaiKqsDWnkKCdMLeJkWRUSEk3BGBEnJzfeu+ypLNVdn/fquUmPoEUt6sF/OZCnwVP/sL91ReAaSHeqnxS1FgQm2ACJjtyHcesUO8BvGSWIs/nWQhDE67ri1GUmztapqG/XRFMRa6A== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 216.228.117.161) smtp.rcpttodomain=lists.ubuntu.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 (0) Received: from CH5P223CA0007.NAMP223.PROD.OUTLOOK.COM (2603:10b6:610:1f3::18) by SA3PR12MB9107.namprd12.prod.outlook.com (2603:10b6:806:381::7) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7544.55; Tue, 14 May 2024 18:00:19 +0000 Received: from CH1PEPF0000AD76.namprd04.prod.outlook.com (2603:10b6:610:1f3:cafe::55) by CH5P223CA0007.outlook.office365.com (2603:10b6:610:1f3::18) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7587.26 via Frontend Transport; Tue, 14 May 2024 18:00:19 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 216.228.117.161) 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 216.228.117.161 as permitted sender) receiver=protection.outlook.com; client-ip=216.228.117.161; helo=mail.nvidia.com; pr=C Received: from mail.nvidia.com (216.228.117.161) by CH1PEPF0000AD76.mail.protection.outlook.com (10.167.244.53) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7587.21 via Frontend Transport; Tue, 14 May 2024 18:00:18 +0000 Received: from rnnvmail201.nvidia.com (10.129.68.8) by mail.nvidia.com (10.129.200.67) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.2.1544.4; Tue, 14 May 2024 11:00:02 -0700 Received: from rnnvmail205.nvidia.com (10.129.68.10) 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.1544.4; Tue, 14 May 2024 11:00:02 -0700 Received: from vdi.nvidia.com (10.127.8.14) by mail.nvidia.com (10.129.68.10) with Microsoft SMTP Server id 15.2.1544.4 via Frontend Transport; Tue, 14 May 2024 11:00:01 -0700 From: Asmaa Mnebhi To: Subject: [SRU][J:linux-bluefield][PATCH v2 1/1] UBUNTU: SAUCE: mlxbf-gige: Vitesse PHY stuck in a bad state during reboot test Date: Tue, 14 May 2024 13:59:57 -0400 Message-ID: <20240514175957.2390-2-asmaa@nvidia.com> X-Mailer: git-send-email 2.30.1 In-Reply-To: <20240514175957.2390-1-asmaa@nvidia.com> References: <20240514175957.2390-1-asmaa@nvidia.com> MIME-Version: 1.0 X-NV-OnPremToCloud: ExternallySecured X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CH1PEPF0000AD76:EE_|SA3PR12MB9107:EE_ X-MS-Office365-Filtering-Correlation-Id: 6f6a71c5-26f1-473d-b6d3-08dc743fb78e X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; ARA:13230031|36860700004|376005|82310400017|1800799015; X-Microsoft-Antispam-Message-Info: mojbaujlFxOnCtKCr/ILoxRySNt9ZjT8h3ZJiElDr5JK9D3qh7+dVxhmjLE6/LDAm3Rv2asBc+QbfTnKjgKcVuU7RcBOElo/z2aoia2uGwXTmjYGzfMhqucOAemwHsqTpIlJKQEpebZXDg5bSapbw9UbvjGQxN/FSav1A5B8xQEuK9b+xRx9rk+gaGFx170ty7J3AhGHg5Meg509nfD6H7yCCmSwm/pLr12+KgrJQAREAdfOfKyDTl+EQI0i6y7uDdF8syCi+ykHaesMvDXsi/qXqpW2d6hxQgTfZ6Jm7TGD5FfHn7k7vlG9z56gY8EPBbYKTe2dRd/BK5TUhaYufU6GC5EmAjJdQ9ywuZCnUDWGQC0HAY1JzNyWQZIc8PPTZzqCavrj7sgyqzfVv4r10X6tFRCHBfNCbx+lgbZj/AXe+qOXPRI0kR8tTgjOW1xWFiZ0W3jUTiQztGZXNd3JcEzFDvSfvOJfdkfk00LqcitAep7gpqm+td1dhubmT+/moDJUeaVaVYF1vYeszyQpQFYsGs+7YIfrxLkiAdzQ22DXmAT8ahU4Q9iggvyXGBQqYtB/Efd6NmLXlIbLKbnZfOVLAtLvy+4WD7HnnCUJj0sDSfvQm6yL8V4qAzsZ4Qk5RivVBIlVl6S/gq+e+MXsHNR4Ef3pNtVimx7kN+8EN5GAAKZwEHuKf563UOMLQyVdGfgVy2H1ZyqDxBqSi+keVHr+L9H6HCir7V70dPPQXuS9YtE22J0GVlCvP89wPBm5eFzjb3CKACogSb4sDMm3/FnINEStVk1AADt+gsE3ufQvJjcLXaJCctH35XcE+GrURZ7Za6gabV6/xh98dLdQkmc/UFCqoScl7KTYdoJaJ1zBF0zb0lgaKyYu//QSKixBwCEJQoycj0Ty2heMOzcyWR29YGusT3e2tgQBA6l1mBD9X3yzIJSaxvNEZJmcd1qyverjmiFI+DDCgHNJ58VDj8G7ChdNnnugw1KY3ZHBzZAq+qEWJUQTibjRoSwN3WntxkmLPwzfzzE35u68zaNm8aTMCO/M0yE6G5TBXWlLKEjX3QuX2CfoncWADj89f+B/lIgvRUwlAW2rjnV5PswhROK8R1qpyA8AeUSWwZ0gXe/G/nQvQz5M5/Q2RfNf+cCUDCrJXlTH9WVr1Z5zvkVQhLBjola7xCtM3yTh7Rn6n6Xhy4EMJz/QmCwfFVjzdddNMyR69CVVMbbZE8RORn5tU5m7wBiHGNp4m0L++Q0VMKaQLIPhdBqFXGSo+RWGENE6Zbts3x6lhTlpJSfDLiZZQmcdTQh8CrC0NEgnl+fPEUadjOgDp2kU9PH1jFF1U4jMBrPC+PVG9pVSyYAvmDliPStW7+YMP3Sp+FCi9/Ytre4= X-Forefront-Antispam-Report: CIP:216.228.117.161; CTRY:US; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:mail.nvidia.com; PTR:dc6edge2.nvidia.com; CAT:NONE; SFS:(13230031)(36860700004)(376005)(82310400017)(1800799015); DIR:OUT; SFP:1101; X-OriginatorOrg: Nvidia.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 14 May 2024 18:00:18.9550 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 6f6a71c5-26f1-473d-b6d3-08dc743fb78e X-MS-Exchange-CrossTenant-Id: 43083d15-7273-40c1-b7db-39efd9ccc17a X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=43083d15-7273-40c1-b7db-39efd9ccc17a; Ip=[216.228.117.161]; Helo=[mail.nvidia.com] X-MS-Exchange-CrossTenant-AuthSource: CH1PEPF0000AD76.namprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SA3PR12MB9107 Received-SPF: softfail client-ip=40.107.220.78; envelope-from=asmaa@nvidia.com; helo=NAM11-CO1-obe.outbound.protection.outlook.com X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Asmaa Mnebhi , David Thompson Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" BugLink: https://bugs.launchpad.net/bugs/2064163 During the reboot test, the OOB doesn't get an ip. The root cause is the PHY getting stuck in a bad state that's only recoverable by a PHY hard reset so a powercycle. Warm boot doesn't support this capability. We can avoid this bug by preventing the PHY from entering this bad state in the first place. Disabling the OOB port avoids the issue. Signed-off-by: Asmaa Mnebhi Reviewed-by: David Thompson --- drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c b/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c index 56235cef5cd6..006c2b4eee70 100644 --- a/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c +++ b/drivers/net/ethernet/mellanox/mlxbf_gige/mlxbf_gige_main.c @@ -202,8 +202,14 @@ static int mlxbf_gige_open(struct net_device *netdev) static int mlxbf_gige_stop(struct net_device *netdev) { struct mlxbf_gige *priv = netdev_priv(netdev); + u64 control; + + control = readq(priv->base + MLXBF_GIGE_CONTROL); + control &= ~MLXBF_GIGE_CONTROL_PORT_EN; + writeq(control, priv->base + MLXBF_GIGE_CONTROL); writeq(0, priv->base + MLXBF_GIGE_INT_EN); + mb(); netif_stop_queue(netdev); napi_disable(&priv->napi); netif_napi_del(&priv->napi);