Skip to content

Commit

Permalink
Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/g…
Browse files Browse the repository at this point in the history
…it/jejb/scsi

Pull SCSI fixes from James Bottomley:
 "This is two patches both fixing bugs in drivers (virtio-scsi and
  mpt2sas) causing an oops in certain circumstances"

* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
  [SCSI] virtio-scsi: Skip setting affinity on uninitialized vq
  [SCSI] mpt2sas: Don't disable device twice at suspend.
  • Loading branch information
Linus Torvalds committed May 4, 2014
2 parents 0384dca + 0c8482a commit e3fb7d4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 0 additions & 1 deletion drivers/scsi/mpt2sas/mpt2sas_scsih.c
Original file line number Diff line number Diff line change
Expand Up @@ -8293,7 +8293,6 @@ _scsih_suspend(struct pci_dev *pdev, pm_message_t state)

mpt2sas_base_free_resources(ioc);
pci_save_state(pdev);
pci_disable_device(pdev);
pci_set_power_state(pdev, device_state);
return 0;
}
Expand Down
6 changes: 5 additions & 1 deletion drivers/scsi/virtio_scsi.c
Original file line number Diff line number Diff line change
Expand Up @@ -750,8 +750,12 @@ static void __virtscsi_set_affinity(struct virtio_scsi *vscsi, bool affinity)

vscsi->affinity_hint_set = true;
} else {
for (i = 0; i < vscsi->num_queues; i++)
for (i = 0; i < vscsi->num_queues; i++) {
if (!vscsi->req_vqs[i].vq)
continue;

virtqueue_set_affinity(vscsi->req_vqs[i].vq, -1);
}

vscsi->affinity_hint_set = false;
}
Expand Down

0 comments on commit e3fb7d4

Please sign in to comment.