]> err.no Git - linux-2.6/blobdiff - drivers/scsi/qla2xxx/qla_mid.c
[SCSI] qla2xxx: Update version number to 8.02.01-k5.
[linux-2.6] / drivers / scsi / qla2xxx / qla_mid.c
index e7565765fa14dd558064467f83900d5820560864..9a850a24b38a9b2189a5918e5aa33c2bc156cac1 100644 (file)
@@ -277,7 +277,8 @@ qla2x00_do_dpc_vp(scsi_qla_host_t *vha)
                clear_bit(RESET_ACTIVE, &vha->dpc_flags);
        }
 
-       if (test_and_clear_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags)) {
+       if (atomic_read(&vha->vp_state) == VP_ACTIVE &&
+           test_and_clear_bit(LOOP_RESYNC_NEEDED, &vha->dpc_flags)) {
                if (!(test_and_set_bit(LOOP_RESYNC_ACTIVE, &vha->dpc_flags))) {
                        qla2x00_loop_resync(vha);
                        clear_bit(LOOP_RESYNC_ACTIVE, &vha->dpc_flags);