]> bbs.cooldavid.org Git - net-next-2.6.git/blobdiff - drivers/scsi/qla2xxx/qla_os.c
[SCSI] qla2xxx: Fix ISP restart bug in multiq code
[net-next-2.6.git] / drivers / scsi / qla2xxx / qla_os.c
index 4a71f522f9259308a9d3d08f3d9f54ac9fada1be..cf32653fe01a2317aee14dae3856c2aee8017953 100644 (file)
@@ -1158,8 +1158,8 @@ qla2x00_abort_all_cmds(scsi_qla_host_t *vha, int res)
        struct req_que *req;
 
        spin_lock_irqsave(&ha->hardware_lock, flags);
-       for (que = 0; que < QLA_MAX_HOST_QUES; que++) {
-               req = ha->req_q_map[vha->req_ques[que]];
+       for (que = 0; que < ha->max_queues; que++) {
+               req = ha->req_q_map[que];
                if (!req)
                        continue;
                for (cnt = 1; cnt < MAX_OUTSTANDING_COMMANDS; cnt++) {
@@ -1193,7 +1193,7 @@ qla2xxx_slave_configure(struct scsi_device *sdev)
        scsi_qla_host_t *vha = shost_priv(sdev->host);
        struct qla_hw_data *ha = vha->hw;
        struct fc_rport *rport = starget_to_rport(sdev->sdev_target);
-       struct req_que *req = ha->req_q_map[0];
+       struct req_que *req = ha->req_q_map[vha->req_ques[0]];
 
        if (sdev->tagged_supported)
                scsi_activate_tcq(sdev, req->max_q_depth);
@@ -1998,7 +1998,6 @@ qla2x00_probe_one(struct pci_dev *pdev, const struct pci_device_id *id)
        return 0;
 
 probe_failed:
-       qla2x00_free_que(ha, req, rsp);
        qla2x00_free_device(base_vha);
 
        scsi_host_put(base_vha->host);