Commit 0aa78d17 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi

Pull SCSI fixes from James Bottomley:
 "Three minor fixes, all in drivers"

* tag 'scsi-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/jejb/scsi:
  scsi: mpt3sas: Fix incorrectly assigned error return and check
  scsi: storvsc: Log TEST_UNIT_READY errors as warnings
  scsi: lpfc: Move initialization of phba->poll_list earlier to avoid crash
parents 7ba34c0c 40d32727
...@@ -13193,6 +13193,8 @@ lpfc_pci_probe_one_s4(struct pci_dev *pdev, const struct pci_device_id *pid) ...@@ -13193,6 +13193,8 @@ lpfc_pci_probe_one_s4(struct pci_dev *pdev, const struct pci_device_id *pid)
if (!phba) if (!phba)
return -ENOMEM; return -ENOMEM;
INIT_LIST_HEAD(&phba->poll_list);
/* Perform generic PCI device enabling operation */ /* Perform generic PCI device enabling operation */
error = lpfc_enable_pci_dev(phba); error = lpfc_enable_pci_dev(phba);
if (error) if (error)
...@@ -13327,7 +13329,6 @@ lpfc_pci_probe_one_s4(struct pci_dev *pdev, const struct pci_device_id *pid) ...@@ -13327,7 +13329,6 @@ lpfc_pci_probe_one_s4(struct pci_dev *pdev, const struct pci_device_id *pid)
/* Enable RAS FW log support */ /* Enable RAS FW log support */
lpfc_sli4_ras_setup(phba); lpfc_sli4_ras_setup(phba);
INIT_LIST_HEAD(&phba->poll_list);
timer_setup(&phba->cpuhp_poll_timer, lpfc_sli4_poll_hbtimer, 0); timer_setup(&phba->cpuhp_poll_timer, lpfc_sli4_poll_hbtimer, 0);
cpuhp_state_add_instance_nocalls(lpfc_cpuhp_state, &phba->cpuhp); cpuhp_state_add_instance_nocalls(lpfc_cpuhp_state, &phba->cpuhp);
......
...@@ -7851,7 +7851,7 @@ _base_make_ioc_operational(struct MPT3SAS_ADAPTER *ioc) ...@@ -7851,7 +7851,7 @@ _base_make_ioc_operational(struct MPT3SAS_ADAPTER *ioc)
return r; return r;
} }
rc = _base_static_config_pages(ioc); r = _base_static_config_pages(ioc);
if (r) if (r)
return r; return r;
......
...@@ -1199,14 +1199,24 @@ static void storvsc_on_io_completion(struct storvsc_device *stor_device, ...@@ -1199,14 +1199,24 @@ static void storvsc_on_io_completion(struct storvsc_device *stor_device,
vstor_packet->vm_srb.sense_info_length); vstor_packet->vm_srb.sense_info_length);
if (vstor_packet->vm_srb.scsi_status != 0 || if (vstor_packet->vm_srb.scsi_status != 0 ||
vstor_packet->vm_srb.srb_status != SRB_STATUS_SUCCESS) vstor_packet->vm_srb.srb_status != SRB_STATUS_SUCCESS) {
storvsc_log(device, STORVSC_LOGGING_ERROR,
/*
* Log TEST_UNIT_READY errors only as warnings. Hyper-V can
* return errors when detecting devices using TEST_UNIT_READY,
* and logging these as errors produces unhelpful noise.
*/
int loglevel = (stor_pkt->vm_srb.cdb[0] == TEST_UNIT_READY) ?
STORVSC_LOGGING_WARN : STORVSC_LOGGING_ERROR;
storvsc_log(device, loglevel,
"tag#%d cmd 0x%x status: scsi 0x%x srb 0x%x hv 0x%x\n", "tag#%d cmd 0x%x status: scsi 0x%x srb 0x%x hv 0x%x\n",
request->cmd->request->tag, request->cmd->request->tag,
stor_pkt->vm_srb.cdb[0], stor_pkt->vm_srb.cdb[0],
vstor_packet->vm_srb.scsi_status, vstor_packet->vm_srb.scsi_status,
vstor_packet->vm_srb.srb_status, vstor_packet->vm_srb.srb_status,
vstor_packet->status); vstor_packet->status);
}
if (vstor_packet->vm_srb.scsi_status == SAM_STAT_CHECK_CONDITION && if (vstor_packet->vm_srb.scsi_status == SAM_STAT_CHECK_CONDITION &&
(vstor_packet->vm_srb.srb_status & SRB_STATUS_AUTOSENSE_VALID)) (vstor_packet->vm_srb.srb_status & SRB_STATUS_AUTOSENSE_VALID))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment