public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Nilesh Javali <njavali@marvell.com>
To: <martin.petersen@oracle.com>
Cc: <linux-scsi@vger.kernel.org>,
	<GR-QLogic-Storage-Upstream@marvell.com>,
	<agurumurthy@marvell.com>, <sdeodhar@marvell.com>,
	<emilne@redhat.com>, <jmeneghi@redhat.com>
Subject: [PATCH v2 01/12] qla2xxx: Add Speed in SFP print information
Date: Thu, 4 Dec 2025 20:47:40 +0530	[thread overview]
Message-ID: <20251204151751.2321801-2-njavali@marvell.com> (raw)
In-Reply-To: <20251204151751.2321801-1-njavali@marvell.com>

From: Himanshu Madhani <hmadhani@marvell.com>

Print additional information about the speed
while displaying SFP information.

Signed-off-by: Himanshu Madhani <hmadhani@marvell.com>
Signed-off-by: Nilesh Javali <njavali@marvell.com>
Reviewed-by: Himanshu Madhani <hmadhani2024@gmail.com>
---
 drivers/scsi/qla2xxx/qla_init.c | 14 ++++++++++++++
 1 file changed, 14 insertions(+)

diff --git a/drivers/scsi/qla2xxx/qla_init.c b/drivers/scsi/qla2xxx/qla_init.c
index 6a2e1c7fd125..66eeee84be05 100644
--- a/drivers/scsi/qla2xxx/qla_init.c
+++ b/drivers/scsi/qla2xxx/qla_init.c
@@ -4074,6 +4074,20 @@ static void qla2xxx_print_sfp_info(struct scsi_qla_host *vha)
 	u8 str[STR_LEN], *ptr, p;
 	int leftover, len;
 
+	ql_dbg(ql_dbg_init, vha, 0x015a,
+	    "SFP: %.*s -> %.*s ->%s%s%s%s%s%s\n",
+	    (int)sizeof(a0->vendor_name), a0->vendor_name,
+	    (int)sizeof(a0->vendor_pn), a0->vendor_pn,
+	    a0->fc_sp_cc10 & FC_SP_32 ? " 32G" : "",
+	    a0->fc_sp_cc10 & FC_SP_16 ? " 16G" : "",
+	    a0->fc_sp_cc10 & FC_SP_8  ?  " 8G" : "",
+	    a0->fc_sp_cc10 & FC_SP_4  ?  " 4G" : "",
+	    a0->fc_sp_cc10 & FC_SP_2  ?  " 2G" : "",
+	    a0->fc_sp_cc10 & FC_SP_1  ?  " 1G" : "");
+
+	if (!(ql2xextended_error_logging & ql_dbg_verbose))
+		return;
+
 	memset(str, 0, STR_LEN);
 	snprintf(str, SFF_VEN_NAME_LEN+1, a0->vendor_name);
 	ql_dbg(ql_dbg_init, vha, 0x015a,
-- 
2.23.1


  reply	other threads:[~2025-12-04 15:18 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-12-04 15:17 [PATCH v2 00/12] qla2xxx: Misc feature and bug fixes Nilesh Javali
2025-12-04 15:17 ` Nilesh Javali [this message]
2025-12-04 15:17 ` [PATCH v2 02/12] qla2xxx: Add support for 64G SFP speed Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 03/12] qla2xxx: Add load flash firmware mailbox support for 28xxx Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 04/12] qla2xxx: Validate MCU signature before executing MBC 03h Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 05/12] qla2xxx: Add bsg interface to support firmware img validation Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 06/12] qla2xxx: Allow recovery for tape devices Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 07/12] qla2xxx: Delay module unload while fabric scan in progress Nilesh Javali
2025-12-09  8:14   ` Dan Carpenter
2025-12-04 15:17 ` [PATCH v2 08/12] qla2xxx: free sp in error path to fix system crash Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 09/12] qla2xxx: validate sp before freeing associated memory Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 10/12] qla2xxx: Query FW again before proceeding with login Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 11/12] qla2xxx: fix bsg_done causing double free Nilesh Javali
2025-12-04 15:17 ` [PATCH v2 12/12] qla2xxx: Update version to 10.02.10.100-k Nilesh Javali

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20251204151751.2321801-2-njavali@marvell.com \
    --to=njavali@marvell.com \
    --cc=GR-QLogic-Storage-Upstream@marvell.com \
    --cc=agurumurthy@marvell.com \
    --cc=emilne@redhat.com \
    --cc=jmeneghi@redhat.com \
    --cc=linux-scsi@vger.kernel.org \
    --cc=martin.petersen@oracle.com \
    --cc=sdeodhar@marvell.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox