From: linux@treblig.org
To: njavali@marvell.com, GR-QLogic-Storage-Upstream@marvell.com,
James.Bottomley@HansenPartnership.com,
martin.petersen@oracle.com
Cc: linux-scsi@vger.kernel.org, linux-kernel@vger.kernel.org,
"Dr. David Alan Gilbert" <linux@treblig.org>
Subject: [PATCH 2/8] scsi: qla2xxx: Remove unused qlt_fc_port_deleted
Date: Tue, 15 Apr 2025 01:27:57 +0100 [thread overview]
Message-ID: <20250415002803.135909-3-linux@treblig.org> (raw)
In-Reply-To: <20250415002803.135909-1-linux@treblig.org>
From: "Dr. David Alan Gilbert" <linux@treblig.org>
qlt_fc_port_deleted() has been unused since the last use was removed
by 2017's
commit 726b85487067 ("qla2xxx: Add framework for async fabric discovery")
Remove it.
Signed-off-by: Dr. David Alan Gilbert <linux@treblig.org>
---
drivers/scsi/qla2xxx/qla_target.c | 44 -------------------------------
drivers/scsi/qla2xxx/qla_target.h | 1 -
2 files changed, 45 deletions(-)
diff --git a/drivers/scsi/qla2xxx/qla_target.c b/drivers/scsi/qla2xxx/qla_target.c
index 8a892ac95417..15c6d95cc4f2 100644
--- a/drivers/scsi/qla2xxx/qla_target.c
+++ b/drivers/scsi/qla2xxx/qla_target.c
@@ -1454,50 +1454,6 @@ static struct fc_port *qlt_create_sess(
return sess;
}
-/*
- * max_gen - specifies maximum session generation
- * at which this deletion requestion is still valid
- */
-void
-qlt_fc_port_deleted(struct scsi_qla_host *vha, fc_port_t *fcport, int max_gen)
-{
- struct qla_tgt *tgt = vha->vha_tgt.qla_tgt;
- struct fc_port *sess = fcport;
- unsigned long flags;
-
- if (!vha->hw->tgt.tgt_ops)
- return;
-
- if (!tgt)
- return;
-
- spin_lock_irqsave(&vha->hw->tgt.sess_lock, flags);
- if (tgt->tgt_stop) {
- spin_unlock_irqrestore(&vha->hw->tgt.sess_lock, flags);
- return;
- }
- if (!sess->se_sess) {
- spin_unlock_irqrestore(&vha->hw->tgt.sess_lock, flags);
- return;
- }
-
- if (max_gen - sess->generation < 0) {
- spin_unlock_irqrestore(&vha->hw->tgt.sess_lock, flags);
- ql_dbg(ql_dbg_tgt_mgt, vha, 0xf092,
- "Ignoring stale deletion request for se_sess %p / sess %p"
- " for port %8phC, req_gen %d, sess_gen %d\n",
- sess->se_sess, sess, sess->port_name, max_gen,
- sess->generation);
- return;
- }
-
- ql_dbg(ql_dbg_tgt_mgt, vha, 0xf008, "qla_tgt_fc_port_deleted %p", sess);
-
- sess->local = 1;
- spin_unlock_irqrestore(&vha->hw->tgt.sess_lock, flags);
- qlt_schedule_sess_for_deletion(sess);
-}
-
static inline int test_tgt_sess_count(struct qla_tgt *tgt)
{
struct qla_hw_data *ha = tgt->ha;
diff --git a/drivers/scsi/qla2xxx/qla_target.h b/drivers/scsi/qla2xxx/qla_target.h
index 71cf0236ea7d..453eb2f6a7c9 100644
--- a/drivers/scsi/qla2xxx/qla_target.h
+++ b/drivers/scsi/qla2xxx/qla_target.h
@@ -1014,7 +1014,6 @@ extern int qlt_lport_register(void *, u64, u64, u64,
extern void qlt_lport_deregister(struct scsi_qla_host *);
extern void qlt_unreg_sess(struct fc_port *);
extern void qlt_fc_port_added(struct scsi_qla_host *, fc_port_t *);
-extern void qlt_fc_port_deleted(struct scsi_qla_host *, fc_port_t *, int);
extern int __init qlt_init(void);
extern void qlt_exit(void);
extern void qlt_free_session_done(struct work_struct *);
--
2.49.0
next prev parent reply other threads:[~2025-04-15 0:28 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-15 0:27 [PATCH 0/8] scsi: qla2xxx deadcoding linux
2025-04-15 0:27 ` [PATCH 1/8] scsi: qla2xxx: Remove unused qlt_free_qfull_cmds linux
2025-04-15 0:27 ` linux [this message]
2025-04-15 0:27 ` [PATCH 3/8] scsi: qla2xxx: Remove unused qlt_83xx_iospace_config linux
2025-04-15 0:27 ` [PATCH 4/8] scsi: qla2xxx: Remove unused qla82xx_pci_region_offset linux
2025-04-15 0:28 ` [PATCH 5/8] scsi: qla2xxx: Remove unused qla82xx_wait_for_state_change linux
2025-04-15 0:28 ` [PATCH 6/8] scsi: qla2xxx: Remove unused ql_log_qp linux
2025-04-15 0:28 ` [PATCH 7/8] scsi: qla2xxx: Remove unused qla2x00_gpsc linux
2025-04-15 0:28 ` [PATCH 8/8] scsi: qla2xxx: Remove unused module parameters linux
2025-04-22 1:53 ` [PATCH 0/8] scsi: qla2xxx deadcoding Martin K. Petersen
2025-04-29 2:08 ` Martin K. Petersen
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=20250415002803.135909-3-linux@treblig.org \
--to=linux@treblig.org \
--cc=GR-QLogic-Storage-Upstream@marvell.com \
--cc=James.Bottomley@HansenPartnership.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-scsi@vger.kernel.org \
--cc=martin.petersen@oracle.com \
--cc=njavali@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