diff options
author | Darrick J. Wong <djwong@us.ibm.com> | 2007-01-11 17:15:03 -0500 |
---|---|---|
committer | James Bottomley <jejb@mulgrave.il.steeleye.com> | 2007-01-13 17:15:27 -0500 |
commit | cde3f74bac3e4a6bcdc3a6370af38179fd8ef1f2 (patch) | |
tree | bf98c68eb08edaa45320dbf3154b22830898a6a2 /drivers/scsi/libsas | |
parent | 6d4dcd4dae25c48e8932326aaedfe560d7f2c7bb (diff) |
[SCSI] libsas: Destroy the task collector thread after releasing ports
If we use task collector mode, we can end up destroying the task collector
thread before we release the ports, which is bad if a port release causes
a disk I/O (such as cache flushing).
Signed-off-by: Darrick J. Wong <djwong@us.ibm.com>
Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi/libsas')
-rw-r--r-- | drivers/scsi/libsas/sas_init.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/scsi/libsas/sas_init.c b/drivers/scsi/libsas/sas_init.c index 90cce34cb6f5..4df73d69bb3c 100644 --- a/drivers/scsi/libsas/sas_init.c +++ b/drivers/scsi/libsas/sas_init.c | |||
@@ -127,12 +127,13 @@ Undo_phys: | |||
127 | 127 | ||
128 | int sas_unregister_ha(struct sas_ha_struct *sas_ha) | 128 | int sas_unregister_ha(struct sas_ha_struct *sas_ha) |
129 | { | 129 | { |
130 | sas_unregister_ports(sas_ha); | ||
131 | |||
130 | if (sas_ha->lldd_max_execute_num > 1) { | 132 | if (sas_ha->lldd_max_execute_num > 1) { |
131 | sas_shutdown_queue(sas_ha); | 133 | sas_shutdown_queue(sas_ha); |
134 | sas_ha->lldd_max_execute_num = 1; | ||
132 | } | 135 | } |
133 | 136 | ||
134 | sas_unregister_ports(sas_ha); | ||
135 | |||
136 | return 0; | 137 | return 0; |
137 | } | 138 | } |
138 | 139 | ||