From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 88EF9531603; Wed, 30 Sep 2026 17:40:16 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790790017; cv=none; b=FouwBa07T4gWlrnkgV+CDqCYfYjS/cThOrhJuiZHqFWRLdTCklWTJD+OcatB3xpySQl2RubBDJqanZSBU3HHshEGuGQtbPmU6EFCEfecJXNaDE64SIX8QZQPAPr/EauzdcskZo0G7/YqG/zxsQ33H0M8qZwAW3CrQw6LldgsqmA= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1790790017; c=relaxed/simple; bh=3yXNLFktrGnMGW3Df8sF76Gs6qMfrKnxF5sFG9WeFS4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Fj4toCs9HY90xALIWtYfsOZtz48NzhmtROmGFTM9VDBSl29sYGNmuGS+6WAWrQI7AAVG76lTCnVYxhw+pde+luSGvkOLa3nCQBp4gd63PwDtK/uLReJEsCvx8HpDqhI+TV7PP6BDC4sdvKNCNu1Wu9wPvG5epFJvh2p7edtoYFI= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b=U+Ki/+rh; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="U+Ki/+rh" Received: by smtp.kernel.org (Postfix) with ESMTPSA id E56971F000FF; Wed, 30 Sep 2026 17:40:15 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linuxfoundation.org; s=korg; t=1790790016; bh=igew2ucAZBkqfWyhdNdmP0vOE29TXkWiFQ8W1GL4Hl0=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=U+Ki/+rh8pI3SyDKEl51i/flJA/3kOCQS9HmAm5SMsUW59Cz7ekkQ32BvWXwoHprT B1j8c9JigiONvPeW9f7/wjmIsGzVbOWMpuOQ0mVHW5fVHCEqHC7zJPA8EUhrn5Fv+z vghpX/EosjJ+wGolWj5Z3O4qywLcOI9Mki8w5VAs= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Nilesh Javali , Hannes Reinecke , "Martin K. Petersen (Oracle)" , Sasha Levin Subject: [PATCH 6.12 679/877] scsi: qla2xxx: Fix 64G link speed reporting in get_data_rate Date: Wed, 30 Sep 2026 17:26:30 +0200 Message-ID: <20260930152429.327966382@linuxfoundation.org> X-Mailer: git-send-email 2.55.0 In-Reply-To: <20260930152414.738996857@linuxfoundation.org> References: <20260930152414.738996857@linuxfoundation.org> User-Agent: quilt/0.69 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 6.12-stable review patch. If anyone has any objections, please let me know. ------------------ From: Nilesh Javali [ Upstream commit 52fba32317ee631faa878725b2f7cd5c08acacd3 ] qla2x00_get_data_rate() skips updating ha->link_data_rate when the firmware returns mcp->mb[1] == 0x7. That value was a legacy sentinel from before 64G hardware existed, but PORT_SPEED_64GB is now defined as 0x07 and ha->link_data_rate is decoded with the PORT_SPEED_* encoding. On a 64G-capable adapter a genuine 64G link is therefore dropped, and the port speed is misreported (port_speed sysfs, fc_host speed, FDMI). Only 28xx and 29xx support 64G, so accept 0x07 on those adapters while keeping the legacy filter for older ones. Also drop the duplicate copy of the check at the end of the success branch; it repeated the first assignment with no intervening change. Fixes: ecc89f25e225 ("scsi: qla2xxx: Add Device ID for ISP28XX") Cc: stable@vger.kernel.org Signed-off-by: Nilesh Javali Reviewed-by: Hannes Reinecke Link: https://patch.msgid.link/20260723050413.3897522-46-njavali@marvell.com Signed-off-by: Martin K. Petersen (Oracle) [ Omitted IS_QLA29XX() checks because this branch lacks 29xx adapter support. ] Signed-off-by: Sasha Levin Signed-off-by: Greg Kroah-Hartman --- drivers/scsi/qla2xxx/qla_mbx.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) --- a/drivers/scsi/qla2xxx/qla_mbx.c +++ b/drivers/scsi/qla2xxx/qla_mbx.c @@ -5658,7 +5658,7 @@ qla2x00_get_data_rate(scsi_qla_host_t *v ql_dbg(ql_dbg_mbx, vha, 0x1107, "Failed=%x mb[0]=%x.\n", rval, mcp->mb[0]); } else { - if (mcp->mb[1] != 0x7) + if (mcp->mb[1] != 0x7 || IS_QLA28XX(ha)) ha->link_data_rate = mcp->mb[1]; if (IS_QLA83XX(ha) || IS_QLA27XX(ha) || IS_QLA28XX(ha)) { @@ -5669,8 +5669,6 @@ qla2x00_get_data_rate(scsi_qla_host_t *v ql_dbg(ql_dbg_mbx + ql_dbg_verbose, vha, 0x1108, "Done %s.\n", __func__); - if (mcp->mb[1] != 0x7) - ha->link_data_rate = mcp->mb[1]; } return rval;