qla1280 bandaid
Hi Jes,
The problem is that bus_reset drops the HOST_LOCK when it callsschedule_timeout, but when it's called from the initialisation code, HOST_LOCK isn't actually held.
The appended patch fixes this; however, I'm not sure that it's correct, because I couldn't work out easily whether the HOST_LOCK is held or not on all paths to qla1280_bus_reset().
With the patch in place, I can once again boot SMP I2000 and rx4610.
=== drivers/scsi/qla1280.c 1.44 vs edited ==--- 1.44/drivers/scsi/qla1280.c Fri Aug 15 09:08:54 2003
+++ edited/drivers/scsi/qla1280.c Tue Sep 2 14:53:32 2003
@@ -3346,9 +3346,9 @@
ha->bus_settings[bus].scsi_bus_dead = 1;
ha->bus_settings[bus].failed_reset_count++;
} else {
- spin_unlock_irq(HOST_LOCK);
+/* spin_unlock_irq(HOST_LOCK);*/
schedule_timeout(reset_delay * HZ);
- spin_lock_irq(HOST_LOCK);
+/* spin_lock_irq(HOST_LOCK);*/
ha->bus_settings[bus].scsi_bus_dead = 0; ha->bus_settings[bus].failed_reset_count = 0;
Quoted 9 lines · Peter Chubb
Hi Jes,
The problem is thatbus_resetdrops theHOST_LOCKwhen it callsschedule_timeout, but when it's called from the initialisation code,HOST_LOCKisn't actually held.The appended patch fixes this; however, I'm not sure that it's correct, because I couldn't work out easily whether the
HOST_LOCKis held or not on all paths toqla1280_bus_reset().
Right fix would probably be to take the lock always before calling..
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Christoph" = Christoph Hellwig <[email protected]> writes:
Christoph> On Tue, Sep 02, 2003 at 02:57:15PM +1000, Peter Chubb
Quoted 7 lines · Christoph> wrote:
Quoted 7 lines
Hi Jes, The problem is that
bus_resetdrops theHOST_LOCKwhen it
callsschedule_timeout, but when it's called from the initialisation code,HOST_LOCKisn't actually held.The appended patch fixes this; however, I'm not sure that it's correct, because I couldn't work out easily whether the
HOST_LOCKis held or not on all paths toqla1280_bus_reset().
Christoph> Right fix would probably be to take the lock always before Christoph> calling..
Peter and Christoph,
Thanks for the info, I'll take a look at integrating this into the next version.
Cheers,
Jes