[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250816112417.3581253-15-jiangjianjun3@huawei.com>
Date: Sat, 16 Aug 2025 19:24:17 +0800
From: JiangJianJun <jiangjianjun3@...wei.com>
To: <James.Bottomley@...senPartnership.com>, <martin.petersen@...cle.com>,
<linux-scsi@...r.kernel.org>
CC: <linux-kernel@...r.kernel.org>, <hare@...e.de>, <bvanassche@....org>,
<michael.christie@...cle.com>, <hch@...radead.org>, <haowenchao22@...il.com>,
<john.g.garry@...cle.com>, <hewenliang4@...wei.com>, <yangyun50@...wei.com>,
<wuyifeng10@...wei.com>, <wubo40@...wei.com>, <yangxingui@...artners.com>
Subject: [PATCH 14/14] scsi: iscsi_tcp: enable LUN-based and target-based error handlers
From: JiangJianJun <jiangjianjun3@...artners.com>
The iSCSI TCP driver now supports resetting LUNs or targets,
allowing us to enable LUN-based error handlers and enable them
to fall back to target-based error handlers.
Signed-off-by: JiangJianJun <jiangjianjun3@...artners.com>
---
drivers/scsi/iscsi_tcp.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/scsi/iscsi_tcp.c b/drivers/scsi/iscsi_tcp.c
index 7b4fe0e6afb2..328e76219b1c 100644
--- a/drivers/scsi/iscsi_tcp.c
+++ b/drivers/scsi/iscsi_tcp.c
@@ -33,6 +33,7 @@
#include <scsi/scsi_device.h>
#include <scsi/scsi_host.h>
#include <scsi/scsi.h>
+#include <scsi/scsi_eh.h>
#include <scsi/scsi_transport_iscsi.h>
#include <trace/events/iscsi.h>
#include <trace/events/sock.h>
@@ -1040,6 +1041,9 @@ static const struct scsi_host_template iscsi_sw_tcp_sht = {
.eh_target_reset_handler = iscsi_eh_recover_target,
.dma_boundary = PAGE_SIZE - 1,
.sdev_configure = iscsi_sw_tcp_sdev_configure,
+ .sdev_setup_eh = scsi_device_setup_eh,
+ .sdev_clear_eh = scsi_device_clear_eh,
+ .sdev_eh_fallback = 1,
.proc_name = "iscsi_tcp",
.this_id = -1,
.track_queue_depth = 1,
--
2.33.0
Powered by blists - more mailing lists