Skip to contentSkip to conversation

Call release on scsi legacy LLDD

PATCH New Mike Anderson 1 participant 1 message May 16, 2003 SCSI

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Call release on scsi legacy LLDD

-andmike
--
Michael Anderson
[email protected]

DESC
In the sysfs scsi host reference counting merge the call to a legacy hosts release function was removed.

This patch adds the call back in.

This patch was tested with insmod / rmmod on LLDDs using the legacy interface and LLDDs using the new interface:

Legacy Interface:
qla2xxx-v8.00.00b1
qlogicisp
aic7xxx_old (Does not call scsi_unregister in release, but unloaded)

New Interface:
scsi_debug
aic7xxx (Many illegal context warnings caused by mid vs LLDD primitive
mixing, but appears to unload clean).

EDESC

 drivers/scsi/hosts.c |    4 ++++
 1 files changed, 4 insertions(+)
drivers/scsi/hosts.c renamed from drivers/scsi/hosts.c~scsi-legacy-release-call +4 -0
diff -puN drivers/scsi/hosts.c~scsi-legacy-release-call drivers/scsi/hosts.c
@@ -215,6 +215,10 @@ int scsi_remove_host(struct Scsi_Host *s
 	scsi_proc_host_rm(shost);
 	scsi_forget_host(shost);
 	scsi_sysfs_remove_host(shost);
+
+	if (shost->hostt->release)
+		(*shost->hostt->release)(shost);
+
 	return 0;
 }
 

_